Specifications
Appendix B. UPS.CMD 79
118 REM Move groups to the other node
119
120 REM !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
121
122 REM (3) Enter one line as shown below
123 REM for each resource group which should be moved to the surviving node
124 REM when one node shuts down!
125
126 cluster . GROUP “Cluster Group” /MOVETO:%TheOtherNodeName% > NUL
127 cluster . GROUP “Quorum” /MOVETO:%TheOtherNodeName% > NUL
128 cluster . GROUP “VFS_a” /MOVETO:%TheOtherNodeName% > NUL
129 cluster . GROUP “VFS_b” /MOVETO:%TheOtherNodeName% > NUL
130
131 REM !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
132
133 CLUSTER.EXE %TheOtherNodeName% NODE %TheOtherNodeName% | FIND “Up”
134 IF %errorlevel% == 1 GOTO GroupOffline
135
136 NET SEND /DOMAIN:APC “The groups are moved from node %COMPUTERNAME% to %TheOtherNodeName%
and will be shutdown in 2 minutes!”
137 GOTO Shutdown
138 REM ---------------------------------------------------------------------------
139
140 REM ---------------------------------------------------------------------------
141 :GroupOffline
142
143 REM 5005 the other node is not available
144 REM 5023 the group is in the state online pending and could not changed
145 REM 70 the node is in pause status and the resouce could not be set to online
146
147 REM Set groups to the offline state
148
149 REM !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
150
151 REM (4) Enter one three-line section as shown below
152 REM for each resource group which should be brought offline
153 REM when both nodes shut down!
154
155 REM :off1
156 REM cluster . GROUP “Cluster Group” /OFFLINE /WAIT:30 > NUL
157 REM IF %errorlevel% == 5023 GOTO off1
158
159 REM :off2
160 REM cluster . GROUP “Quorum” /OFFLINE /WAIT:30 > NUL
161 REM IF %errorlevel% == 5023 GOTO off2
162
163 :off3
164 cluster . GROUP “VFS_a” /OFFLINE /WAIT:30 > NUL
165 IF %errorlevel% == 5023 GOTO off3
166
167 :off4
168 cluster . GROUP “VFS_b” /OFFLINE /WAIT:30 > NUL
169 IF %errorlevel% == 5023 GOTO off4
170
171 REM !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
172
173 NET SEND /DOMAIN:APC “The cluster server is down due to powerfailure! Node %COMPUTERNAME%
will be shutdown in 2 minutes!”
174 GOTO shutdown
175 REM ---------------------------------------------------------------------------










