This page is READ-ONLY. It is generated from the old site.
All timestamps are relative to 2013 (when this page is generated).
If you are looking for TeX support, please go to VietTUG.org

freebsd: dump(8) và restore(8)

chuyển một bộ cài đặt qua phân cùng khác
Added by about 4 years ago

Cần chuyển bộ cài đặt FreeBSD từ phân vùng này sang phân vùng kia. Sau khi dump/restore cần chỉnh lại vài tham số. Ví dụ /etc/fstab

$ umount /dev/ad4s2a         # bỏ kết nối hiện có
$ newfs -U /dev/ad4s2a       # cho phép soft update
$ mount /dev/da4s2a /restore # kết nối
$ cd /restore
$ dump -0Lauf - /dev/ad4s3d | restore -rf -
  # -0: dump ở level 0
  # -L: dump live filesystem
  # -f: nơi xuất kết quả (ở đây là stdout)
  # -u: cập nhật /detc/dumpdates sau khi thành công
  # -a: auto-size
$ kill -SIGINFO <pid>        # thông tin về quá trình dump
Tham khảo:
  1. FreeBSD forum (by killasmurl86)
  2. FreeBSD man pages: dump(8), restore(8)
  3. Dump the best

Kết quả xuất:

$ dump -0Lauf - /dev/ad4s4a | restore -rf -
  DUMP: Date of this level 0 dump: Fri Mar 27 16:45:42 2009
  DUMP: Date of last level 0 dump: the epoch
  DUMP: Dumping snapshot of /dev/ad4s4a (/) to standard output
  DUMP: mapping (Pass I) [regular files]
  DUMP: mapping (Pass II) [directories]
  DUMP: estimated 8671938 tape blocks.
  DUMP: dumping (Pass III) [directories]
  DUMP: dumping (Pass IV) [regular files]
warning: ./.snap: File exists
./tmp/rstmode1238147142: (inode 5958883) not found on tape
expected next file 259113, got 10
  DUMP: 4.50% done, finished in 1:46 at Fri Mar 27 18:37:16 2009
  DUMP: 17.81% done, finished in 0:46 at Fri Mar 27 17:42:14 2009
  DUMP: 29.08% done, finished in 0:36 at Fri Mar 27 17:37:39 2009
  DUMP: 32.65% done, finished in 0:41 at Fri Mar 27 17:47:20 2009
  DUMP: 34.85% done, finished in 0:46 at Fri Mar 27 17:57:49 200
  DUMP: 42.15% done, finished in 0:41 at Fri Mar 27 17:57:15 2009
  DUMP: 51.43% done, finished in 0:33 at Fri Mar 27 17:54:08 2009
  DUMP: 59.22% done, finished in 0:27 at Fri Mar 27 17:53:37 2009
  DUMP: 66.54% done, finished in 0:22 at Fri Mar 27 17:53:42 2009
  DUMP: 74.83% done, finished in 0:16 at Fri Mar 27 17:52:53 2009
  DUMP: 91.50% done, finished in 0:05 at Fri Mar 27 17:46:11 2009
  DUMP: DUMP: 8686387 tape blocks
  DUMP: finished in 3409 seconds, throughput 2548 KBytes/sec
  DUMP: level 0 dump on Fri Mar 27 16:45:42 2009
  DUMP: DUMP IS DONE

Comments