Created
November 20, 2014 20:50
-
-
Save juniovitorino/59f57394609b5d44249a to your computer and use it in GitHub Desktop.
CLONE CLIENTES PARTITION AND SAVE COMPRESSED IMAGE IN AN EXTERNAL HARD DISK (USB)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# AUTHOR: JUNIO VITORINO | [email protected] | |
# DESCRIPTION: DAILY CLONE CLIENTES PARTITION AND SAVE COMPRESSED IMAGE IN AN EXTERNAL HARD DISK (USB) | |
# DATE: NOVEMBER 20, 2014 | |
rm -rf /backup/*.gz | |
now=$(date +"%m_%d_%Y") | |
dd if=/dev/sda5 conv=sync,noerror bs=1K | gzip -c > "/backup/dd_image_clientes_$now.gz" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* 0 * * * /bin/sh /home/manager/backup.sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment