Sun Cluster 3.0 系統管理手冊

2.2 關閉與啟動單一叢集節點


註解 -

請使用 scswitch 指令及 Solaris shutdown 指令,來關閉個別的節點。只有在關閉整個的叢集時,才使用 scshutdown 指令。


表 2-2 作業指引:關閉與啟動叢集節點

作業 

有關資訊,請進到 ... 

停止叢集節點  

- 使用 scswitch(1M) 與 shutdown(1M)

"2.2.1 如何關閉叢集節點"

以開機方式啟動節點。 

節點和叢集交互連接之間必須有運轉中的連線,才能夠成為叢集成員。 

"2.2.2 如何啟動叢集節點"

停止並重新啟動(重新開機)叢集節點 

- 使用 scswitchshutdown

節點和叢集交互連接之間必須有運轉中的連線,才能夠成為叢集成員。 

"2.2.3 如何重新啟動叢集節點"

啟動節點,讓此節點不參與叢集的成員身份 

- 使用 scswitchshutdown,然後啟動 -x

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

2.2.1 如何關閉叢集節點

  1. (選擇性)。在執行 Oracle Parallel Server(OPS)的叢集節點時,請關閉所有的 OPS 資料庫實例。

    請參閱 Oracle Parallel Server 產品文件來取得關機程序。

  2. 成為要關機之叢集節點的超級使用者(superuser)。

  3. 使用 scswitch 以及 shutdown 指令來關閉叢集節點。

    在要關機的節點上,輸入下列指令。


    # scswitch -S -h node
    # shutdown -g 0 -y
    
  4. 確認叢集節點已經到達 ok PROM 提示。

  5. 必要時請關閉節點電源。

2.2.1.1 範例-關閉叢集節點

以下範例顯示關閉 phys-schost-1 節點時的主控台輸出。-g 0 選項可將寬限值設成零,-y 可對確認問題自動提供 yes(是)的回應。這個節點的關閉訊息出現在叢集中另一個節點的主控台上。


# scswitch -S -h phys-schost-1
# shutdown -g 0 -y
Sep  2 10:08:46 phys-schost-1 cl_runtime: WARNING: CMM monitoring disabled.phys-schost-1# 
INIT: New run level: 0
The system is coming down.  Please wait.
Notice: rgmd is being stopped.
Notice: rpc.pmfd is being stopped.
Notice: rpc.fed is being stopped.
umount: /global/.devices/node@1 busy
umount: /global/phys-schost-1 busy
The system is down.
syncing file systems... done
Program terminated
ok 

2.2.1.2 下一步

請參閱 "2.2.2 如何啟動叢集節點" 來重新啟動已經關機的叢集節點。

2.2.2 如何啟動叢集節點


註解 -

啟動叢集節點會受到 quorum 配置的影響。在二個節點的叢集,您必須配置法定裝置來使叢集的法定總數為 三(二個節點以及一個法定裝置)。在這個情況下,如果第一個節點關閉,第二個節點會使法定繼續當作單獨的叢集成員 執行。要使第一個回到叢集中成為叢集節點,第二個節點必須啟動並執行,必要的叢集法定計數(二)必須存在。


  1. 要啟動已經關閉的叢集節點,請啟動節點。


    ok boot
    

    當叢集元件啟動時,訊息會出現在啟動之節點的主控台以及成員節點的主控台上。


    註解 -

    叢集節點和叢集交互連接之間必須有運轉中的連線,才能夠成為叢集成員。


  2. 確認節點啟動成功而且在線上。

    scstat(1M) 指令可報告節點的狀態。


    # scstat -n
    

2.2.2.1 範例-啟動叢集節點

以下範例顯示 phys-schost-1 節點啟動為叢集時的主控台輸出。


ok boot
Rebooting with command: boot 
...
Hostname: phys-schost-1
Booting as part of a cluster
...
NOTICE: Node 1: attempting to join cluster
...
NOTICE: Node 1: joined cluster
...
The system is coming up.  Please wait.
checking ufs filesystems
...
reservation program successfully exiting
Print services started.
volume management starting.
The system is ready.
phys-schost-1 console login:

2.2.3 如何重新啟動叢集節點

  1. (選擇性)。在執行 Oracle Parallel Server(OPS)的叢集節點,請關閉所有的 OPS 資料庫實例。

    請參閱 Oracle Parallel Server 產品文件來取得關機程序。

  2. 成為要關機之叢集節點的超級使用者(superuser)。

  3. 使用 scswitch 以及 shutdown 指令來關閉叢集節點。

    在要關機的節點上,輸入下列指令。


    # scswitch -S -h node
    # shutdown -g 0 -y -i 6
    

    此項 -i 6 選擇含 shutdown 指令,可讓節點在關閉成 ok PROM 提示後重新開機。


    註解 -

    叢集節點和叢集交互連接之間必須有運轉中的連線,才能夠成為叢集成員。


  4. 確認節點啟動成功而且在線上。

    scstat(1M) 指令可報告節點的狀態。


    # scstat -n
    

2.2.3.1 範例-重新啟動叢集節點

以下範例顯示節點 phys-schost-1 節點關機再重新啟動時顯示的主控台輸出。-g 0 選項可將寬限值設成零,-y 可對確認問題自動提供 yes(是)的回應。這個節點的關機與啟動訊息會顯示在叢集中其他節點的主控台上。


# scswitch -S -h phys-schost-1
# shutdown -g 0 -y -i 6
Sep  2 10:08:46 phys-schost-1 cl_runtime: WARNING: CMM monitoring disabled.
phys-schost-1# 
INIT: New run level: 6
The system is coming down.  Please wait.
System services are now being stopped.
Notice: rgmd is being stopped.
Notice: rpc.pmfd is being stopped.
Notice: rpc.fed is being stopped.
umount: /global/.devices/node@1 busy
umount: /global/phys-schost-1 busy
The system is down.
syncing file systems... done
rebooting...
Resetting ... 
,,,
Sun Ultra 1 SBus (UltraSPARC 143MHz), No Keyboard
OpenBoot 3.11, 128 MB memory installed, Serial #7982421.
Ethernet address 8:0:20:79:cd:55, Host ID: 8079cd55.
...
Rebooting with command: boot
...
Hostname: phys-schost-1
Booting as part of a cluster
...
NOTICE: Node 1: attempting to join cluster
...
NOTICE: Node 1: joined cluster
...
The system is coming up.  Please wait.
The system is ready.
phys-schost-1 console login: 

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

您還可以非叢集模式啟動節點,使該節點不是叢集的成員。這在安裝叢集軟體或執行某些管理程序如修補節點時,非常有用。

  1. 在要以非叢集模式啟動的叢集上成為超級使用者(superuser)

  2. 使用 scswitchshutdown 指令來關閉節點。


    # scswitch -S -h node
    # shutdown -g 0 -y
    
  3. 確認節點顯示 ok PROM 提示。

  4. 使用 boot(1M) 指令以及 -x 選項,以非叢集模式啟動節點。


    ok boot -x
    

    節點的主控台出現的訊息指出,節點不是叢集的一部份。

2.2.4.1 範例-以非叢集模式啟動叢集節點

以下範例顯示 phys-schost-1 節點先關閉再以非叢集模式啟動時的主控台輸出。-g -0 選項可將寬限值設成零,-y 可對確認問題自動提供 yes(是)的回應。這個節點的關閉訊息出現在叢集中另一個節點的主控台上。


# scswitch -S -h phys-schost-1
# shutdown -g 0 -y
Sep  2 10:08:46 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 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: