Skip to content

Commit cdc7c40

Browse files
committed
bug 12844 : use plugin echo main to test if master can connect to slave
status 12844: resolved fixed reviewed-by : edison
1 parent 6d0bb6d commit cdc7c40

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎core/src/com/cloud/hypervisor/xen/resource/XenServerConnectionPool.java‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -641,7 +641,13 @@ public Connection connect(String hostUuid, String poolUuid, String ipAddress,
641641
if (s_managePool) {
642642
try {
643643
Map<String, String> args = new HashMap<String, String>();
644-
host.callPlugin(mConn, "vmops", "pingxenserver", args);
644+
host.callPlugin(mConn, "echo", "main", args);
645+
} catch (Types.SessionInvalid e) {
646+
if (s_logger.isDebugEnabled()) {
647+
String msg = "Catch Exception: " + e.getClass().getName() + " Can't connect host " + ipAddress + " due to " + e.toString();
648+
s_logger.debug(msg);
649+
}
650+
PoolEmergencyResetMaster(ipAddress, mConn.getIp(), mConn.getUsername(), mConn.getPassword());
645651
} catch (Types.CannotContactHost e ) {
646652
if (s_logger.isDebugEnabled()) {
647653
String msg = "Catch Exception: " + e.getClass().getName() + " Can't connect host " + ipAddress + " due to " + e.toString();

0 commit comments

Comments
 (0)