backup.sh
backup.sh · 784 B
From the archive cyhawk_mud.tar.gz
Download the archive « Back to the archive contents
Back_Dir="/home/cyhawk/Admin/backup/" #Replace /User/Backup with your desired
Backup directory.
Mud_Dir="/home/cyhawk/vandagard/" #Replace /User/Mud with your
main Mud
directory.
# *************No More Modifications Required****************
#Get the date for the filename.
shdate=`date +%b%d%y`
#Save our current directory location.
tmp_dir=$PWD
#Change to the Backup file directory.
cd $Back_Dir
#Create a gzip compressed tar file of the Mud Directory.
echo Compressing...
tar -czf ${shdate}.mud.tar.gz $Mud_Dir
#Return to the previous working directory.
cd $tmp_dir
#Print some info on the screen.
echo Your mud has been backed up to file:
echo
echo ${Back_Dir}/${shdate}.mud.tar.gz
echo
echo Backup Complete.
echo Linux Mud Backup Shell Script by: Golorn