増設HDDにバックアップ
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
検索
|
最終更新
|
ヘルプ
|
ログイン
]
開始行:
[[dump&restore]]
http://www.jp.freebsd.org/QandA/HTML/1859.html
http://www.ebisu-it.com/freebsd-tips/ft-8/
/usrは、これでw
#!/bin/sh
#/usr/local/bin/rsync -av --delete / www.smb.net:/usr/Ba...
/usr/local/bin/rsync -av --exclude="*.core" --inplace /u...
----
k222# df
Filesystem 1K-blocks Used Avail Capacity Moun...
/dev/ar0s1a 507630 99930 367090 21% /
devfs 1 1 0 100% /dev
/dev/ar0s1e 507630 412 466608 0% /tmp
/dev/ar0s1f 464941328 52413448 375332574 12% /usr
/dev/ar0s1d 3029646 605288 2181988 22% /var
devfs 1 1 0 100% /var...
devfs 1 1 0 100% /usr...
/dev/ad12s1a 507630 10 467010 0% /bkup
/dev/ad12s1e 507630 4 467016 0% /bku...
/dev/ad12s1f 464926440 4 427732322 0% /bku...
/dev/ad12s1d 3031694 4 2789156 0% /bku...
k222# mount -t ufs /dev/ad12s1a /bkup
k222# mount -t ufs /dev/ad12s1f /bkup/usr
k222# mount -t ufs /dev/ad12s1e /bkup/tmp
k222# mount -t ufs /dev/ad12s1d /bkup/var
/etc/fstab
# Device Mountpoint FStype Options Dump Pass#
/dev/ar0s1b none swap sw 0 0
/dev/ar0s1a / ufs rw 1 1
/dev/ar0s1e /tmp ufs rw 2 2
/dev/ar0s1f /usr ufs rw 2 2
/dev/ar0s1d /var ufs rw 2 2
/dev/acd0 /cdrom cd9660 ro,noauto 0 0
/dev/ad12s1a /bkup ufs rw 2 2
/dev/ad12s1e /bkup/tmp ufs rw 2 2
/dev/ad12s1f /bkup/usr ufs rw 2 2
/dev/ad12s1d /bkup/var ufs rw 2 2
# dump 0af - / | ( cd /bkup && restore rf -)
# dump 0af - /var | ( cd /bkup/var && restore rf -)
# dump 0af - /usr | ( cd /bkup/usr && restore rf -)
# dump 0af - /tmp | ( cd /bkup/tmp && restore rf -)
k222# dump 0af - / | ( cd /bkup && restore rf -)
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 16:45:30 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1a (/) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 99297 tape blocks.
DUMP: dumping (Pass III) [directories]
DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
warning: ./tmp: File exists
warning: ./usr: File exists
warning: ./var: File exists
DUMP: DUMP: 99306 tape blocks
DUMP: finished in 9 seconds, throughput 11034 KBytes/sec
DUMP: DUMP IS DONE
k222# dump 0af - /var | ( cd /bkup/var && restore rf -)
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 16:48:46 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1d (/var) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 606628 tape blocks.
DUMP: dumping (Pass III) [directories]
DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
expected next file 188453, got 188452
expected next file 188464, got 188459
expected next file 188464, got 188460
expected next file 188464, got 188461
expected next file 188464, got 188463
expected next file 188470, got 188468
expected next file 188470, got 188469
DUMP: DUMP: 606191 tape blocks
DUMP: finished in 20 seconds, throughput 30309 KBytes/sec
DUMP: DUMP IS DONE
k222# dump 0af - /usr | ( cd /bkup/usr && restore rf -)
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 16:50:54 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1f (/usr) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 53043317 tape blocks.
DUMP: dumping (Pass III) [directories]
DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
DUMP: 1.05% done, finished in 29:07 at Sat Apr 30 22:17...
unknown tape header type 1196314761
abort? [yn]n
resync restore, skipped 9 blocks
expected next file 4522012, got 0
./share/doc/nl_NL.ISO8859-1/books/handbook/install/examp...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/examp...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/examp...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/addus...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/addus...
unknown tape header type 1593585698
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 4522021, got 0
unknown tape header type -1401555986
abort? [yn] n
resync restore, skipped 2 blocks
expected next file 4522021, got 0
unknown tape header type 510142068
abort? [yn] n
resync restore, skipped 4 blocks
expected next file 4522021, got 0
unknown tape header type 1800916336
abort? [yn] n
resync restore, skipped 9 blocks
expected next file 4522021, got 0
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/diskl...
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 8887682, got 0
./var/db/freebsd-update/files/42ed690e23ee1ec6bcd06d1750...
./var/db/freebsd-update/files/2a1adbe2333827908577f5c6db...
./var/db/freebsd-update/files/de73d94bd9afb35217926c021d...
./var/db/freebsd-update/files/d3b1389ca6e03390d589675763...
./var/db/freebsd-update/files/107f4f8372b7b20630920d6ca4...
./var/db/freebsd-update/files/30b77ea32988d368b3a5a81d22...
./var/db/freebsd-update/files/2bd5339d6c878bfb5f2203f6c0...
unknown tape header type 1288117844
abort? [yn] n
expected next file 8887690, got 0
expected next file 8887690, got 8887683
expected next file 8887690, got 8887684
expected next file 8887690, got 8887685
expected next file 8887690, got 8887686
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 3 blocks
expected next file 8887692, got 0
unknown tape header type 765735214
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 8887692, got 0
./var/db/freebsd-update/files/4bf7830b9e21e400165b9f4207...
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 2 blocks
expected next file 8887694, got 0
./var/db/freebsd-update/files/52be7cac4a17fbbd0e0c75a4ca...
./var/db/freebsd-update/files/4f858d49f915221eae4ebcc900...
./var/db/freebsd-update/files/5f693273806a5f870e8e97f532...
./var/db/freebsd-update/files/be38d930f7f8561a92f142fa62...
./var/db/freebsd-update/files/fbfe9c7aa3b61615983efab6ec...
./var/db/freebsd-update/files/a496259e9f14fd1bebfe15a547...
./var/db/freebsd-update/files/3879565b4d0ef009705aed9ee7...
unknown tape header type -1170130095
abort? [yn] n
expected next file 8887705, got 0
expected next file 8887705, got 8887701
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 8887705, got 0
./var/db/freebsd-update/files/3f02e886739e2295f35d01542c...
./var/db/freebsd-update/files/723ccbf9249f5ff990873f2c78...
./var/db/freebsd-update/files/a29375e8ae5f4a50d709b9889d...
./var/db/freebsd-update/files/4341ef5fe5f41659c1c2e26398...
./var/db/freebsd-update/files/191293c4ff7bec3885be67990a...
./var/db/freebsd- update/files/3311a10d13637a70ff0c47c20...
./var/db/freebsd-update/files/ae8354aadc103b0006345df53c...
expected next file 8887714, got 8887705
expected next file 8887714, got 8887706
expected next file 8887714, got 8887707
expected next file 8887714, got 8887708
expected next file 8887714, got 8887709
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 2 blocks
expected next file 8887714, got 0
./var/db/freebsd-update/files/aaac511eaabd8c62f57daa4127...
unknown tape header type -1808459390
abort? [yn]abort? [yn] y
dump core? [yn] n
DUMP: Broken pipe
DUMP: The ENTIRE dump is aborted.
k222# dump 0af - /usr | ( cd /bkup/usr && restore rf - )
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 17:23:58 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1f (/usr) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 53043317 tape blocks.
DUMP: dumping (Pass III) [directories]
終了行:
[[dump&restore]]
http://www.jp.freebsd.org/QandA/HTML/1859.html
http://www.ebisu-it.com/freebsd-tips/ft-8/
/usrは、これでw
#!/bin/sh
#/usr/local/bin/rsync -av --delete / www.smb.net:/usr/Ba...
/usr/local/bin/rsync -av --exclude="*.core" --inplace /u...
----
k222# df
Filesystem 1K-blocks Used Avail Capacity Moun...
/dev/ar0s1a 507630 99930 367090 21% /
devfs 1 1 0 100% /dev
/dev/ar0s1e 507630 412 466608 0% /tmp
/dev/ar0s1f 464941328 52413448 375332574 12% /usr
/dev/ar0s1d 3029646 605288 2181988 22% /var
devfs 1 1 0 100% /var...
devfs 1 1 0 100% /usr...
/dev/ad12s1a 507630 10 467010 0% /bkup
/dev/ad12s1e 507630 4 467016 0% /bku...
/dev/ad12s1f 464926440 4 427732322 0% /bku...
/dev/ad12s1d 3031694 4 2789156 0% /bku...
k222# mount -t ufs /dev/ad12s1a /bkup
k222# mount -t ufs /dev/ad12s1f /bkup/usr
k222# mount -t ufs /dev/ad12s1e /bkup/tmp
k222# mount -t ufs /dev/ad12s1d /bkup/var
/etc/fstab
# Device Mountpoint FStype Options Dump Pass#
/dev/ar0s1b none swap sw 0 0
/dev/ar0s1a / ufs rw 1 1
/dev/ar0s1e /tmp ufs rw 2 2
/dev/ar0s1f /usr ufs rw 2 2
/dev/ar0s1d /var ufs rw 2 2
/dev/acd0 /cdrom cd9660 ro,noauto 0 0
/dev/ad12s1a /bkup ufs rw 2 2
/dev/ad12s1e /bkup/tmp ufs rw 2 2
/dev/ad12s1f /bkup/usr ufs rw 2 2
/dev/ad12s1d /bkup/var ufs rw 2 2
# dump 0af - / | ( cd /bkup && restore rf -)
# dump 0af - /var | ( cd /bkup/var && restore rf -)
# dump 0af - /usr | ( cd /bkup/usr && restore rf -)
# dump 0af - /tmp | ( cd /bkup/tmp && restore rf -)
k222# dump 0af - / | ( cd /bkup && restore rf -)
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 16:45:30 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1a (/) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 99297 tape blocks.
DUMP: dumping (Pass III) [directories]
DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
warning: ./tmp: File exists
warning: ./usr: File exists
warning: ./var: File exists
DUMP: DUMP: 99306 tape blocks
DUMP: finished in 9 seconds, throughput 11034 KBytes/sec
DUMP: DUMP IS DONE
k222# dump 0af - /var | ( cd /bkup/var && restore rf -)
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 16:48:46 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1d (/var) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 606628 tape blocks.
DUMP: dumping (Pass III) [directories]
DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
expected next file 188453, got 188452
expected next file 188464, got 188459
expected next file 188464, got 188460
expected next file 188464, got 188461
expected next file 188464, got 188463
expected next file 188470, got 188468
expected next file 188470, got 188469
DUMP: DUMP: 606191 tape blocks
DUMP: finished in 20 seconds, throughput 30309 KBytes/sec
DUMP: DUMP IS DONE
k222# dump 0af - /usr | ( cd /bkup/usr && restore rf -)
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 16:50:54 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1f (/usr) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 53043317 tape blocks.
DUMP: dumping (Pass III) [directories]
DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
DUMP: 1.05% done, finished in 29:07 at Sat Apr 30 22:17...
unknown tape header type 1196314761
abort? [yn]n
resync restore, skipped 9 blocks
expected next file 4522012, got 0
./share/doc/nl_NL.ISO8859-1/books/handbook/install/examp...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/examp...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/examp...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/addus...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/addus...
unknown tape header type 1593585698
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 4522021, got 0
unknown tape header type -1401555986
abort? [yn] n
resync restore, skipped 2 blocks
expected next file 4522021, got 0
unknown tape header type 510142068
abort? [yn] n
resync restore, skipped 4 blocks
expected next file 4522021, got 0
unknown tape header type 1800916336
abort? [yn] n
resync restore, skipped 9 blocks
expected next file 4522021, got 0
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/conso...
./share/doc/nl_NL.ISO8859-1/books/handbook/install/diskl...
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 8887682, got 0
./var/db/freebsd-update/files/42ed690e23ee1ec6bcd06d1750...
./var/db/freebsd-update/files/2a1adbe2333827908577f5c6db...
./var/db/freebsd-update/files/de73d94bd9afb35217926c021d...
./var/db/freebsd-update/files/d3b1389ca6e03390d589675763...
./var/db/freebsd-update/files/107f4f8372b7b20630920d6ca4...
./var/db/freebsd-update/files/30b77ea32988d368b3a5a81d22...
./var/db/freebsd-update/files/2bd5339d6c878bfb5f2203f6c0...
unknown tape header type 1288117844
abort? [yn] n
expected next file 8887690, got 0
expected next file 8887690, got 8887683
expected next file 8887690, got 8887684
expected next file 8887690, got 8887685
expected next file 8887690, got 8887686
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 3 blocks
expected next file 8887692, got 0
unknown tape header type 765735214
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 8887692, got 0
./var/db/freebsd-update/files/4bf7830b9e21e400165b9f4207...
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 2 blocks
expected next file 8887694, got 0
./var/db/freebsd-update/files/52be7cac4a17fbbd0e0c75a4ca...
./var/db/freebsd-update/files/4f858d49f915221eae4ebcc900...
./var/db/freebsd-update/files/5f693273806a5f870e8e97f532...
./var/db/freebsd-update/files/be38d930f7f8561a92f142fa62...
./var/db/freebsd-update/files/fbfe9c7aa3b61615983efab6ec...
./var/db/freebsd-update/files/a496259e9f14fd1bebfe15a547...
./var/db/freebsd-update/files/3879565b4d0ef009705aed9ee7...
unknown tape header type -1170130095
abort? [yn] n
expected next file 8887705, got 0
expected next file 8887705, got 8887701
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 1 blocks
expected next file 8887705, got 0
./var/db/freebsd-update/files/3f02e886739e2295f35d01542c...
./var/db/freebsd-update/files/723ccbf9249f5ff990873f2c78...
./var/db/freebsd-update/files/a29375e8ae5f4a50d709b9889d...
./var/db/freebsd-update/files/4341ef5fe5f41659c1c2e26398...
./var/db/freebsd-update/files/191293c4ff7bec3885be67990a...
./var/db/freebsd- update/files/3311a10d13637a70ff0c47c20...
./var/db/freebsd-update/files/ae8354aadc103b0006345df53c...
expected next file 8887714, got 8887705
expected next file 8887714, got 8887706
expected next file 8887714, got 8887707
expected next file 8887714, got 8887708
expected next file 8887714, got 8887709
unknown tape header type 559903
abort? [yn] n
resync restore, skipped 2 blocks
expected next file 8887714, got 0
./var/db/freebsd-update/files/aaac511eaabd8c62f57daa4127...
unknown tape header type -1808459390
abort? [yn]abort? [yn] y
dump core? [yn] n
DUMP: Broken pipe
DUMP: The ENTIRE dump is aborted.
k222# dump 0af - /usr | ( cd /bkup/usr && restore rf - )
DUMP: WARNING: should use -L when dumping live read-wri...
DUMP: Date of this level 0 dump: Fri Apr 29 17:23:58 2011
DUMP: Date of last level 0 dump: the epoch
DUMP: Dumping /dev/ar0s1f (/usr) to standard output
DUMP: mapping (Pass I) [regular files]
DUMP: mapping (Pass II) [directories]
DUMP: estimated 53043317 tape blocks.
DUMP: dumping (Pass III) [directories]
ページ名: