ZenPack talk:Amazon Web Services
This looks like it has lots more useful stuff than the old version. Couple of questions:
1) The old version created Zenoss locations for Amazon regions. This doesn't appear to be happening any more. Is this as designed or have I missed something?
Rob(Zenoss): Sorry but we did remove that feature as it didn't seem to add much value overall. Of course we can add it back in if this is a requested feature.
(Jane): I quite liked the way that regions showed up in Zenoss Locations. If it is easy, I would put it back in as taking away functionality is always going to hurt someone.
2) I am not getting any graphs for anything - regions, instances, etc - just NaN on the graphs. Don't have an entry for my EC2 device under $ZENHOME/perf/Devices even. Suggestions??
Eric(Zenoss): Make sure zenpython is running.
(Jane): Spot on rocket - zenpython is the trick!
Love the links from regions to instances / volumes etc - folk must check the screenshots though or they may not realise the snazzy functionality that is there!
3) Discovered guest instances do indeed get put into the Zenoss decommisioned state when the instance is taken down (once the EC2 device has been remodelled) - excellent. What doesn't work so well is where you have instances that get a new IP address when they are started afresh. We have lots of these for teaching. The modeler discovers the regions, instances and guests. There is a create_guest function in EC2Instance.py that sets the external IP address correctly the first time but when the guest is stopped and started and receives a new external IP then it would be great to have an "update_guest" function that checks whether the IP address has changed and updates that IP if it has.
I suspect this is fairly trivial for you (Zenoss). If you are not likely to do this, please say so and I shall have a go.
OK - I think I have an update to EC2Instance.py that updates the external IP address. See commented bits in the discover_guest function below:
def discover_guest(self): ''' Attempt to discover and link guest device. ''' if not self.state: return deviceclass = self.guest_deviceclass() if not deviceclass: return if self.state.lower() == 'running': guest_device = self.guest_device() if guest_device: if guest_device.productionState != self._running_prodstate: LOG.info( 'instance %s running. Changing guest device ' 'to production', self.titleOrId()) guest_device.setProdState(self._running_prodstate) # Added by JC to check whether external IP address has changed new_ip=self.guest_manage_ip() old_ip = guest_device.manageIp if new_ip != old_ip: guest_device.setManageIp(new_ip) LOG.info( 'manageIp address of device %s changed from %s to %s' % ( guest_device.titleOrId(), old_ip, new_ip )) # End of JC addition else: self.create_guest() elif self.state.lower() == 'stopped': guest_device = self.guest_device() if guest_device: if guest_device.productionState != -1: LOG.info( 'instance %s stopped. Decommissioning guest device', self.titleOrId()) guest_device.setProdState(-1)