commit - 63d4746f904db1e6032ea19d428116e00f66d587
commit + 885440579879f3d28a990d5bf1eebb427e746cae
blob - /dev/null
blob + a55e3b916a4553a2fbdd7d0ff093d4f89404f0cc (mode 644)
--- /dev/null
+++ wiki.d/Almanack.DumpBackupWithSCP
+version=pmwiki-2.3.20 ordered=1 urlencoded=1
+agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
+author=SplinTer
+charset=UTF-8
+csum=
+ctime=1703975767
+host=138.43.182.133
+name=Almanack.DumpBackupWithSCP
+rev=15
+targets=
+text=this is a custom shell script to run dump command for backup to remote server with the SCP Command with using a private openssh key! please note that you will need to setup private key for your scp to use without using a password%0a%0a%25note%25'''NOTE:''' The above command copies the backup from local host to remote host to store your backup. This requires ssh without password (ssh keys) and doas without password which is a security concern%0a%0a%25note%25'''private.key NOTE:''' The Solution: When you get to the public key screen in creating your key pair in puttygen, copy the public key and paste it into a text file with the extension .pub. You will save you sysadmin hours of frustration reading posts like this%0a%0aBegin of script%0a----%0a%0a[@%0a#!/bin/ksh %0a#Author SplinTer@NaStYcOdE.Com Free Unix Tech Support At support@nastycode.com%0a# Join Us On IRC At IRC.NaStYcOdE.COM Channel #NaStYcOdE%0aSHELL=/bin/sh%0aPATH=/bin:/sbin19:/usr/bin:/usr/sbin19:/sbin/:/usr/sbin%0aHOME=/root%0aMAILTO="splinter@NaStYcOdE.com"%0a%0ahostname=NaStYcOdE.COM%0abackup_destination=SplinTer@host.planetofnix.com%0atimestamp=$(date "+%25Y%25m%25d")%0adest=/home/backup/$timestamp%0a%0aecho%0acd /home/backup/%0aecho%0amkdir $timestamp%0aecho%0acd $dest%0aecho "Curremt Working Backup Directory $dest on $hostname"%0aecho%0aecho "Partition's Needs Backed Up With OpenBSD Dump Command"%0aecho%0adf -h%0aecho%0aecho "Current Backup Location $hostname VPS Folder $dest"%0aecho%0acd $dest%0aecho%0apwd%0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/root.dmp / %0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/tmp.dmp /tmp %0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/usr.dmp /usr %0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/usr-X11R6.dmp /usr/X11R6 %0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/usr-local.dmp /usr/local %0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/var.dmp /var %0adoas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/home.dmp /home%0aecho "Folder Size Of Backup On $hostname VPS"%0acd $dest%0adu -sh%0aecho%0aecho "Uploading to $backup_destination Backup Server! User Account SplinTer!"%0aecho%0aecho "Uploading to $backup_destination Going To Take A Hour! Please Keep Calm And Be Patiently Let it Do Its Thing!"%0acd /home/backup%0aecho%0aecho "Starting Upload to Storage VPS Server host.planetofnix.com In Folder /mnt/sd4/a/vps/SplinTer/backup/nastycode.com/ On Storage VPS"%0aecho%0a/usr/bin/scp -r -i private.key /home/backup/* SplinTer@host.planetofnix.com:/mnt/sd4/a/vps/SplinTer/backup/nastycode.com/%0aecho "Backup Directoy File Size On Backup VPS"%0adu -sh /home/backup/$timestamp%0aecho%0aecho "Uploading to $backup_destination Is Complete! File Path On VPS Server /home/backup/sd4/a/vps/SplinTer/backup/nastycode.com/"%0aecho%0aecho%0aecho "Deleteing $hostname Files From local Backup! Current Directory $dest"%0arm -fr $dest%0aecho%0aecho%0aecho "This Bash Script Can Be Run As Ofen As You Wish! I'd Run At Least Weekly! Made By SplinTer@NaStYcOdE.Com"%0a@]
+time=1703984196
+author:1703984196=SplinTer
+diff:1703984196:1703984132:=1c1%0a%3c this is a custom shell script to run dump command for backup to remote server with the SCP Command with using a private openssh key! please note that you will need to setup private key for your scp to use without using a password%0a---%0a> this is a custom shell script to run dump command for backup to remote server with the SCP Command! please note that you will need to setup private key for your scp to use without using a password%0a
+host:1703984196=138.43.182.133
+author:1703984132=SplinTer
+diff:1703984132:1703980652:=1,5c1,3%0a%3c this is a custom shell script to run dump command for backup to remote server with the SCP Command! please note that you will need to setup private key for your scp to use without using a password%0a%3c %0a%3c %25note%25'''NOTE:''' The above command copies the backup from local host to remote host to store your backup. This requires ssh without password (ssh keys) and doas without password which is a security concern%0a%3c %0a%3c %25note%25'''private.key NOTE:''' The Solution: When you get to the public key screen in creating your key pair in puttygen, copy the public key and paste it into a text file with the extension .pub. You will save you sysadmin hours of frustration reading posts like this%0a---%0a> this is a custom shell script to run dump command for backup to remote server with the SCP Command! please note that you will need to setup private key for your scp to use without using a password:%0a> %0a> %25note%25'''NOTE:''' The above command copies the backup from local host to remote host to backup remote. This requires ssh without password (ssh keys) and doas without password which is a security concern.:%0a
+host:1703984132=138.43.182.133
+author:1703980652=SplinTer
+diff:1703980652:1703977880:=
+host:1703980652=138.43.182.133
+author:1703977880=SplinTer
+diff:1703977880:1703977541:=
+host:1703977880=138.43.182.133
+author:1703977541=SplinTer
+diff:1703977541:1703977462:=15c15%0a%3c MAILTO="splinter@NaStYcOdE.com"%0a---%0a> MAILTO="root@NaStYcOdE.com"%0a
+host:1703977541=138.43.182.133
+author:1703977462=SplinTer
+diff:1703977462:1703977380:=1,2c1,2%0a%3c this is a custom shell script to run dump command for backup to remote server with the SCP Command! please note that you will need to setup private key for your scp to use without using a password:%0a%3c %0a---%0a> this is a custom shell script to run dump command for backup to remote server with the SCP Command! please not that you will need to setup private key for your scp to use with using a password:%0a> %0a5d4%0a%3c Begin of script%0a
+host:1703977462=138.43.182.133
+author:1703977380=SplinTer
+diff:1703977380:1703977328:=7d6%0a%3c [@%0a
+host:1703977380=138.43.182.133
+author:1703977328=SplinTer
+diff:1703977328:1703977309:=5d4%0a%3c ----%0a
+host:1703977328=138.43.182.133
+author:1703977309=SplinTer
+diff:1703977309:1703977193:=3,5c3,7%0a%3c %25note%25'''NOTE:''' The above command copies the backup from local host to remote host to backup remote. This requires ssh without password (ssh keys) and doas without password which is a security concern.:%0a%3c %0a%3c %0a---%0a> %25note%25'''NOTE:''' The above command pulls the backup from a remote host to the backup location. This requires ssh without password (ssh keys) and doas without password which is a security concern.:%0a> %0a> ----%0a> %0a> [@%0a
+host:1703977309=138.43.182.133
+author:1703977193=SplinTer
+diff:1703977193:1703977144:=0a1%0a> [@%0a
+host:1703977193=138.43.182.133
+author:1703977144=SplinTer
+diff:1703977144:1703976940:=1c1%0a%3c [@%0a---%0a> %25note%25[@%0a5a6%0a> %0a7,8d7%0a%3c %0a%3c [@%0a69d67%0a%3c @]%0a\ No newline at end of file%0a
+host:1703977144=138.43.182.133
+author:1703976940=SplinTer
+diff:1703976940:1703976649:=2,5c2,5%0a%3c this is a custom shell script to run dump command for backup to remote server with the SCP Command! please not that you will need to setup private key for your scp to use with using a password:%0a%3c %0a%3c %25note%25'''NOTE:''' The above command pulls the backup from a remote host to the backup location. This requires ssh without password (ssh keys) and doas without password which is a security concern.:%0a%3c %0a---%0a> this is a custom shell script to run dump command for backup to remote server with the SCP Command! please not that you will need to setup private key for your scp to use with using a password%0a> %0a> %25note%25'''NOTE:''' The above command pulls the backup from a remote host to the backup location. This requires ssh without password (ssh keys) and doas without password which is a security concern.%0a> @]%0a
+host:1703976940=138.43.182.133
+author:1703976649=SplinTer
+diff:1703976649:1703975800:=1d0%0a%3c %25note%25[@%0a4,7d2%0a%3c %25note%25'''NOTE:''' The above command pulls the backup from a remote host to the backup location. This requires ssh without password (ssh keys) and doas without password which is a security concern.%0a%3c @]%0a%3c %0a%3c ----%0a
+host:1703976649=138.43.182.133
+author:1703975800=SplinTer
+diff:1703975800:1703975767:=1c1%0a%3c this is a custom shell script to run dump command for backup to remote server with the SCP Command! please not that you will need to setup private key for your scp to use with using a password%0a---%0a> this is a custom shell script to run dump command for backup to remote server! please not that you will need to setup private key for your scp to use with using a password%0a
+host:1703975800=138.43.182.133
+author:1703975767=SplinTer
+diff:1703975767:1703975767:=1,62d0%0a%3c this is a custom shell script to run dump command for backup to remote server! please not that you will need to setup private key for your scp to use with using a password%0a%3c %0a%3c #!/bin/ksh %0a%3c #Author SplinTer@NaStYcOdE.Com Free Unix Tech Support At support@nastycode.com%0a%3c # Join Us On IRC At IRC.NaStYcOdE.COM Channel #NaStYcOdE%0a%3c SHELL=/bin/sh%0a%3c PATH=/bin:/sbin19:/usr/bin:/usr/sbin19:/sbin/:/usr/sbin%0a%3c HOME=/root%0a%3c MAILTO="root@NaStYcOdE.com"%0a%3c %0a%3c hostname=NaStYcOdE.COM%0a%3c backup_destination=SplinTer@host.planetofnix.com%0a%3c timestamp=$(date "+%25Y%25m%25d")%0a%3c dest=/home/backup/$timestamp%0a%3c %0a%3c echo%0a%3c cd /home/backup/%0a%3c echo%0a%3c mkdir $timestamp%0a%3c echo%0a%3c cd $dest%0a%3c echo "Curremt Working Backup Directory $dest on $hostname"%0a%3c echo%0a%3c echo "Partition's Needs Backed Up With OpenBSD Dump Command"%0a%3c echo%0a%3c df -h%0a%3c echo%0a%3c echo "Current Backup Location $hostname VPS Folder $dest"%0a%3c echo%0a%3c cd $dest%0a%3c echo%0a%3c pwd%0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/root.dmp / %0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/tmp.dmp /tmp %0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/usr.dmp /usr %0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/usr-X11R6.dmp /usr/X11R6 %0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/usr-local.dmp /usr/local %0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/var.dmp /var %0a%3c doas /sbin/dump -0 -a -h 0 -f /home/backup/$timestamp/home.dmp /home%0a%3c echo "Folder Size Of Backup On $hostname VPS"%0a%3c cd $dest%0a%3c du -sh%0a%3c echo%0a%3c echo "Uploading to $backup_destination Backup Server! User Account SplinTer!"%0a%3c echo%0a%3c echo "Uploading to $backup_destination Going To Take A Hour! Please Keep Calm And Be Patiently Let it Do Its Thing!"%0a%3c cd /home/backup%0a%3c echo%0a%3c echo "Starting Upload to Storage VPS Server host.planetofnix.com In Folder /mnt/sd4/a/vps/SplinTer/backup/nastycode.com/ On Storage VPS"%0a%3c echo%0a%3c /usr/bin/scp -r -i private.key /home/backup/* SplinTer@host.planetofnix.com:/mnt/sd4/a/vps/SplinTer/backup/nastycode.com/%0a%3c echo "Backup Directoy File Size On Backup VPS"%0a%3c du -sh /home/backup/$timestamp%0a%3c echo%0a%3c echo "Uploading to $backup_destination Is Complete! File Path On VPS Server /home/backup/sd4/a/vps/SplinTer/backup/nastycode.com/"%0a%3c echo%0a%3c echo%0a%3c echo "Deleteing $hostname Files From local Backup! Current Directory $dest"%0a%3c rm -fr $dest%0a%3c echo%0a%3c echo%0a%3c echo "This Bash Script Can Be Run As Ofen As You Wish! I'd Run At Least Weekly! Made By SplinTer@NaStYcOdE.Com"%0a
+host:1703975767=138.43.182.133