Backup script sample

From vpsget wiki
Revision as of 16:45, 19 June 2013 by Vq (talk | contribs) (Created page with " #!/bin/bash 1<pre echo "packing files in progress..."</pre> 2<pre>tar -cf /home/backup/root_lib-$(date +%H:%M-%d-%m-%y).tar /root/install.log /lib</pre> dd if=/dev/vg-virt/...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
#!/bin/bash

1

2<pre>tar -cf /home/backup/root_lib-$(date +%H:%M-%d-%m-%y).tar /root/install.log /lib
dd if=/dev/vg-virt/kvm110_img | gzip | dd of=/home/backup/kvm110-$(date +%H:%M-%d-%m-%y).gz bs=4096
find /home/backup/ -type f -mtime +6 -exec rm {} \;
echo "completed"

Strings: 1 Describes the language 2 Shows message "packing files in progress..." on the screen 3 ""