mirror of https://github.com/apache/cloudstack.git
Don't allow Agent send out StartupCommand if it can not get its local IP address,
otherwise mgmt server will get an incomplete StartupCommand
This commit is contained in:
parent
7adedca8a3
commit
caf945bca2
|
|
@ -329,8 +329,7 @@ public class Agent implements HandlerFactory, IAgentControl {
|
|||
addr = InetAddress.getLocalHost();
|
||||
} catch (final UnknownHostException e) {
|
||||
s_logger.warn("unknow host? ", e);
|
||||
// ignore
|
||||
return;
|
||||
throw new CloudRuntimeException("Cannot get local IP address");
|
||||
}
|
||||
|
||||
final Script command = new Script("hostname", 500, s_logger);
|
||||
|
|
|
|||
Loading…
Reference in New Issue