Sun Cluster 軟體安裝指南 (適用於 Solaris 作業系統)

範例—鏡像 Root (/) 檔案系統

下列範例顯示在節點 phys-schost-1 上建立的鏡像 d0,是由分割區 c0t0d0s0 上的子鏡像 d10 和分割區 c2t2d0s0 上的子鏡像 d20 組成。裝置 c2t2d0 是多重主機磁碟,因此已啟用 localonly 特性。


(建立鏡像)
# metainit -f d10 1 1 c0t0d0s0
d11: Concat/Stripe is setup
# metainit d20 1 1 c2t2d0s0
d12: Concat/Stripe is setup
# metainit d0 -m d10
d10: Mirror is setup
# metaroot d0
# lockfs -fa
 
(從 phys-schost-1 中移出資源群組和裝置群組)
# scswitch -S -h phys-schost-1
 
(重新啟動節點)
# shutdown -g0 -y -i6
 
(附加第二子鏡像)
# metattach d0 d20
d0: Submirror d20 is attached
 
(顯示裝置群組節點清單)
# scconf -pvv | grep dsk/d2
Device group name:						dsk/d2
…
  (dsk/d2) Device group node list:		phys-schost-1, phys-schost-3
…
 
(從節點清單中移除 phys-schost-3)
# scconf -r -D name=dsk/d2,nodelist=phys-schost-3
 
(啟用 localonly 特性)
# scconf -c -D name=dsk/d2,localonly=true
 
(記錄替代啟動路徑)
# ls -l /dev/rdsk/c2t2d0s0
lrwxrwxrwx  1 root     root          57 Apr 25 20:11 /dev/rdsk/c2t2d0s0 
–> ../../devices/node@1/pci@1f,0/pci@1/scsi@3,1/disk@2,0:a,raw