Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fix to restoring address mappings

  • Loading branch information...
commit ae01776e7d8f4c40420e81f6f1905cc07cc7e2b7 2 parents 08dbead + 3127064
chris grzegorczyk grze authored
8 clc/modules/cluster-manager/src/main/java/com/eucalyptus/address/AbstractSystemAddressManager.java
View
@@ -270,20 +270,22 @@ private static VmInstance maybeFindVm( final String instanceId, final String pub
} catch ( NoSuchElementException ex ) {
Logs.extreme( ).error( ex );
}
- } else if ( privateIp != null ) {
+ }
+ if ( vm == null && privateIp != null ) {
try {
vm = VmInstances.lookupByPrivateIp( privateIp );
} catch ( NoSuchElementException ex ) {
Logs.extreme( ).error( ex );
}
- } else if ( publicIp != null ) {
+ }
+ if ( vm == null && publicIp != null ) {
try {
vm = VmInstances.lookupByPublicIp( publicIp );
} catch ( NoSuchElementException ex ) {
Logs.extreme( ).error( ex );
}
}
- if ( vm != null ) {
+ if ( vm != null && VmState.RUNNING.equals( vm ) ) {
Logs.extreme( ).debug( "Candidate vm which claims this address: " + vm.getInstanceId( ) + " " + vm.getState( ) + " " + publicIp );
if ( publicIp.equals( vm.getPublicAddress( ) ) ) {
Logs.extreme( ).debug( "Found vm which claims this address: " + vm.getInstanceId( ) + " " + vm.getState( ) + " " + publicIp );
Please sign in to comment.
Something went wrong with that request. Please try again.