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

Procedure如何以非叢集模式啟動叢集節點

您可以啟動一個節點以便該節點不以叢集成員身份參與作業,即非叢集模式。在安裝叢集軟體或執行某些管理程序 (如修補節點) 時,非叢集模式非常有用。

此程序提供長形式的 Sun Cluster 指令。大多數指令還有簡短的形式。除了指令名稱有長形式和短形式之分外,指令本身是相同的。如需指令及其短形式的清單,請參閱附錄 ASun Cluster 以物件為導向的指令

  1. 成為超級使用者或成為可在叢集中要關閉的節點上提供 solaris.cluster.admin RBAC 授權的角色。

  2. 使用 clnode evacuate shutdown 指令關閉節點。

    clnode evacuate 指令會將所有裝置群組從特定節點切換至下一個喜好的節點。指定也會將所有資源群組從特定節點上的全域或非全域區域切換至其他節點上的下一個喜好全域或非全域區域。


    # clnode evacuate  node
    # shutdown -g0 -y
    
  3. 驗證叢集節點在以 Solaris 為基礎的系統上是否顯示 ok 提示符號或在以 x86 為基礎的系統的 GRUB 功能表上顯示 Press any key to continue 訊息。

  4. 在非叢集模式中啟動節點。

    • 在 SPARC 架構的系統上,執行下列指令:


      phys-schost# boot -xs
      
    • 在 x86 架構的系統上,執行下列指令:


      phys-schost# shutdown -g -y -i0
      
      Press any key to continue
    1. 在 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」中的第 11 章「GRUB Based Booting (Tasks)」

    2. 在啟動參數畫面中,使用方向鍵選取核心項目並鍵入 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.
    3. -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
    4. 按 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.-
    5. 鍵入 b 將節點啟動至非叢集模式。


      備註 –

      對核心啟動參數指令所做的這個變更不會在系統啟動後持續。下次您重新啟動節點時,將會啟動至叢集模式。若要啟動至非叢集模式,請重新執行這些步驟,將 -x 選項增加至核心啟動參數指令。



範例 3–10 SPARC: 以非叢集模式啟動叢集節點

當關閉節點 phys-schost-1 且重新啟動於非叢集模式中時,下列範例會顯示主控台輸出。-g0 選項會將寬限期設成零,而 -y 選項會對確認的問題提供自動的 yes 回應,-i0 選項會呼叫執行層級 0 (零)。這個節點的關閉訊息出現在叢集中另一個節點的主控台上。


# clnode evacuate phys-schost-1
# cluster shutdown -T0 -y
Shutdown started.    Wed Mar 10 13:47:32 phys-schost-1 cl_runtime: 

WARNING: CMM monitoring disabled.
phys-schost-1# 
...
rg_name = schost-sa-1 ...
offline node = phys-schost-2 ...
num of node = 0 ...
phys-schost-1# 
INIT: New run level: 0
The system is coming down.  Please wait.
System services are now being stopped.
Print services stopped.
syslogd: going down on signal 15
...
The system is down.
syncing file systems... done
WARNING: node phys-schost-1 is being shut down.
Program terminated

ok boot -x
...
Not booting as part of cluster
...
The system is ready.
phys-schost-1 console login: