Tuesday, November 29, 2005

Dump (backup) filesystem

Set no-dump bit on recordings dir (applies to all files in the dir):

[root@myth mythtv]# lsattr -d /mythtv/recordings/
----------I-- /mythtv/recordings/
[root@myth mythtv]#
[root@myth mythtv]# chattr +d /mythtv/recordings/
[root@myth mythtv]# lsattr -d /mythtv/recordings/
------d---I-- /mythtv/recordings/
[root@myth mythtv]#

Get estimated size of backup (-S option):

[root@myth mythtv]# dump -0uvS -f /mydump_test -h 0 /
DUMP: Excluding inode 8 (journal inode) from dump
DUMP: Excluding inode 7 (resize inode) from dump
5707378688 [approx. 5GB]
[root@myth mythtv]#

-h 0 (means honor the no-dump bit for level0 backups).

DUMP over ssh (Freebsd example):
dump -0uan -f - /usr | gzip | ssh -c blowfish targetuser@targetmachine.example.com dd of=/mybigfiles/dump-usr.gz

0 Comments:

Post a Comment

<< Home