Sun Cluster 3.0 12/01 系統管理手冊

8.1.3 如何備份 root (/) 檔案系統

請使用這個程序來備份叢集節點的 root (/) 檔案系統。請先確定叢集執行時沒有任何錯誤,再執行備份程序。

  1. 在您要備份的叢集節點上成為超級使用者。

  2. 將每個執行的資料服務從要備份的節點切換到叢集中的另一節點上。


    # scswitch -z -D disk-device-group -h nodelist
    

    -z

    執行切換。

    -D disk-device-group

    要進行切換的磁碟裝置群組名稱。

    -h nodelist

    指定要當作磁碟裝置群組切換目標的叢集節點名稱。 此節點會成為新的主要節點。

  3. 停止節點。


    # shutdown -g0 -y -i0
    

  4. ok 提示,重新啟動為非叢集模式。


    ok boot -x
    

  5. 備份 root (/) 檔案系統。

    • 如果根磁碟為未密封,請使用下列指令。


      # ufsdump 0ucf dump-device /
      

    • 如果根磁碟為密封,請使用下列指令。


      # ufsdump 0ucf dump-device /dev/vx/rdsk/rootvol
      

    請參閱 ufsdump(1M) 線上援助頁,以取得詳細資訊。

  6. 將節點重新啟動為叢集模式。


    # init 6
    

8.1.3.1 範例備份 root (/) 檔案系統

在以下範例中,root (/) 檔案系統是備份到磁帶裝置 /dev/rmt/0


# ufsdump 0ucf /dev/rmt/0 /
  DUMP: Writing 63 Kilobyte records
  DUMP: Date of this level 0 dump: Tue Apr 18 18:06:15 2000
  DUMP: Date of last level 0 dump: the epoch
  DUMP: Dumping /dev/rdsk/c0t0d0s0 (phys-schost-1:/) to /dev/rmt/0
  DUMP: Mapping (Pass I) [regular files]
  DUMP: Mapping (Pass II) [directories]
  DUMP: Estimated 859086 blocks (419.48MB).
  DUMP: Dumping (Pass III) [directories]
  DUMP: Dumping (Pass IV) [regular files]
  DUMP: 859066 blocks (419.47MB) on 1 volume at 2495 KB/sec
  DUMP: DUMP IS DONE
  DUMP: Level 0 dump on Tue Apr 18 18:06:15 2000