Sun Cluster 系統管理指南(適用於 Solaris 作業系統)

Procedure如何備份根 (/) 檔案系統

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

步驟
  1. 在要備份的叢集節點上以超級使用者身份登入或成為等效角色。

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


    # scswitch -z -D disk-device-group[,...] -h node[,...]
    
    -z

    執行切換。

    -D disk-device-group

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

    -h node

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

  3. 關閉節點。


    # shutdown -g0 -y -i0
    
  4. 將節點重新啟動為非叢集模式。

    • SPARC:


      ok boot -x
      
    • x86:


                            <<< Current Boot Parameters >>>
      Boot path: /pci@0,0/pci8086,2545@3/pci8086,1460@1d/pci8086,341a@7,1/
      sd@0,0:a
      Boot args:
      
      Type  b [file-name] [boot-flags] <ENTER> to boot with options
      or    i <ENTER>                          to enter boot interpreter
      or    <ENTER>                            to boot with defaults
      
                        <<< timeout in 5 seconds >>>
      Select (b)oot or (i)nterpreter: b -x
      
  5. 備份 root (/) 檔案系統。

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


      # ufsdump 0ucf dump-device /
      
    • 如果已封裝根磁碟,請使用下列指令。


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

    請參閱 ufsdump(1M) 線上手冊,以取得更多資訊。

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


    # init 6
    

範例 9–3 備份根 (/) 檔案系統

在以下範例中,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