Backup home folder

Backup user home director to /tmp folder




This bash script is used to backup a user's home directory to /tmp/.

user=$(whoami) input=/home/$user output=/tmp/${user}home$(date +%Y-%m-%d_%H%M%S).tar.gz tar -czf $output $input echo "Backup of $input completed! Details about the output backup file:" ls -l $output

Vote Here

You must earn at least 1 vote on your snippets to be allowed to vote

Terms Of Use

Privacy Policy

Featured snippets are MIT license

Gears & Masters

Advertise © 2020