 如何備份根 (/) 檔案系統
如何備份根 (/) 檔案系統使用此程序備份叢集節點的根 (/) 檔案系統。請先確定叢集執行時沒有任何錯誤,再執行備份程序。
此程序提供長形式的 Sun Cluster 指令。大多指令也有短的形式。除了指令名稱有長形式和短形式之分外,指令本身是相同的。如需指令及其短形式的清單,請參閱附錄 ASun Cluster 以物件為導向的指令。
成為超級使用者,或在您正在備份的叢集節點上成為提供 solaris.cluster.modify RBAC 授權的角色
將每個執行的資料服務從要備份的節點切換到叢集中的另一節點上。
| # clnode evacuate 節點 | 
指定您要從中切換資源群組及裝置群組的節點。
關閉節點。
| # shutdown -g0 -y -i0 | 
重新啟動節點進入非叢集模式。
SPARC:鍵入:
| ok boot -x | 
在 x86 架構的系統上,執行下列指令:
| phys-schost# shutdown -g -y -i0 Press any key to continue | 
在 GRUB 功能表中,使用方向鍵選取適合的 Solaris 項目,並鍵入 e 以編輯其指令。
GRUB 功能表會以類似以下的方式顯示:
| GNU GRUB version 0.95 (631K lower / 2095488K upper memory) +-------------------------------------------------------------------------+ | Solaris 10 /sol_10_x86 | | Solaris failsafe | | | +-------------------------------------------------------------------------+ Use the ^ and v keys to select which entry is highlighted. Press enter to boot the selected OS, 'e' to edit the commands before booting, or 'c' for a command-line. | 
如需得知更多以 GRUB 為基礎的啟動之相關資訊,請參閱「System Administration Guide: Basic Administration 」中的「System Administration Guide: Basic Administration」中的第 11 章「GRUB Based Booting (Tasks)」。
在啟動參數畫面中,使用方向鍵選取核心項目並鍵入 e 以編輯該項目。
GRUB 啟動參數畫面會以類似以下的方式顯示:
| GNU GRUB version 0.95 (615K lower / 2095552K upper memory)
+----------------------------------------------------------------------+
| root (hd0,0,a)                                                       |
| kernel /platform/i86pc/multiboot                                     |
| module /platform/i86pc/boot_archive                                  |
+----------------------------------------------------------------------+
Use the ^ and v keys to select which entry is highlighted.
Press 'b' to boot, 'e' to edit the selected command in the
boot sequence, 'c' for a command-line, 'o' to open a new line
after ('O' for before) the selected line, 'd' to remove the
selected line, or escape to go back to the main menu. | 
將 -x 增加至指令以指定系統會啟動至非叢集模式。
| [ Minimal BASH-like line editing is supported. For the first word, TAB lists possible command completions. Anywhere else TAB lists the possible completions of a device/filename. ESC at any time exits. ] grub edit> kernel /platform/i86pc/multiboot -x | 
按 Enter 鍵接受變更並返回啟動參數畫面。
畫面會顯示已編輯的指令。
| GNU GRUB version 0.95 (615K lower / 2095552K upper memory)
+----------------------------------------------------------------------+
| root (hd0,0,a)                                                       |
| kernel /platform/i86pc/multiboot -x                                  |
| module /platform/i86pc/boot_archive                                  |
+----------------------------------------------------------------------+
Use the ^ and v keys to select which entry is highlighted.
Press 'b' to boot, 'e' to edit the selected command in the
boot sequence, 'c' for a command-line, 'o' to open a new line
after ('O' for before) the selected line, 'd' to remove the
selected line, or escape to go back to the main menu.- | 
鍵入 b 將節點啟動至非叢集模式。
對核心啟動參數指令所做的這個變更不會在系統啟動後持續。下次您重新啟動節點時,將會啟動至叢集模式。若要啟動至非叢集模式,請重新執行這些步驟,將 -x 選項增加至核心啟動參數指令。
備份 root (/) 檔案系統。
如果根磁碟為未密封,請使用下列指令。
| # ufsdump 0ucf dump-device / | 
如果已封裝根磁碟,請使用下列指令。
| # ufsdump 0ucf dump-device /dev/vx/rdsk/rootvol | 
請參閱 ufsdump(1M) 線上手冊,以取得更多資訊。
將節點重新啟動為叢集模式。
| # init 6 | 
在以下範例中,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 |