File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -220,7 +220,10 @@ def pool_ha_enable(self, host):
220220 print "Note: Enabling HA"
221221 try :
222222 with settings (host_string = self .ssh_user + "@" + host .ipaddress ):
223- return fab .run ("xe pool-ha-enable heartbeat-sr-uuids=$(xe sr-list type=nfs params=uuid --minimal) ha-config:timeout=180 ha-config:ha-host-failures-to-tolerate=1" )
223+ if fab .run ("cat /etc/redhat-release | awk '{ $3 = substr($3,1,3); print $3 }'" ) == "6.2" :
224+ return fab .run ("xe pool-ha-enable heartbeat-sr-uuids=$(xe sr-list type=nfs params=uuid --minimal) ha-config:timeout=180 ha-config:ha-host-failures-to-tolerate=1" )
225+ else :
226+ return fab .run ("xe pool-ha-enable heartbeat-sr-uuids=$(xe sr-list type=nfs params=uuid --minimal) ha-config:timeout=180; xe pool-param-set uuid=$(xe pool-list params=uuid --minimal) ha-host-failures-to-tolerate=1" )
224227 except :
225228 return False
226229
You can’t perform that action at this time.
0 commit comments