TECHZEN Zenoss User Community ARCHIVE  

KeyError: cant remove device IP from dmd/Networks

Subject: KeyError: cant remove device IP from dmd/Networks
Author: [Not Specified]
Posted: 2016-01-28 15:54

Hey everyone,

Today I was trying to clean up some dangling references (POSKeyErrors)using zodbscan on Zenoss 4.2.5. It returned about ~240 issues. After running FindPOSKeyerrors.py, zenrelationscan.py, and zencatalogscan.py; I was still seeing them.

They mostly all shared the same path of /global_catalog/_catalog/allowedRolesAndUsers/_unidex. After doing some digging I decided to run the following command to recreate the catalog.

zencatalog run --createcatalog --forceindex

In the end, it removed/fixed all the dangling references under global_catalog; HOWEVER! I am now experiencing issues with the GUI. I am getting KeyErrors whenever I open the Infrastructure or Reports Tabs. Below is the error message output when I attempt to open the Infrastructure tab.

http://pastebin.com/gjVXxGf3



Subject:
Author: Jay Stanley
Posted: 2016-01-29 09:32

run zodbscan ; zenrelationscan -f ; findposkeyerror -f

Do not do a catalog rebuild or scan with -f until all errors are fixed in the above commands

Post details on the errors that could not be fixed and we can go from there



Subject: Command Results
Author: [Not Specified]
Posted: 2016-01-29 10:39

As you will see below there are a lot of references to the OID 0x102f25 and the exact same VM.

http://pastebin.com/hjBCgFUy

** Side note, how can I copy output into here without getting html errors regarding the use ofcarrots.



Subject: zodbscan with device path
Author: [Not Specified]
Posted: 2016-01-29 10:47

Pastebin contains device path unlike last post.

http://pastebin.com/HFdFGVbc



Subject: progress
Author: [Not Specified]
Posted: 2016-01-29 12:41

Ended up deleting the device. However it still pops up in a few of the zodbscan poskeyerrors as well as some new ones that still reference eth0.

http://pastebin.com/k3BF7Bbe



Subject: So, after deleting the device
Author: [Not Specified]
Posted: 2016-01-29 14:05

So, after deleting the device; I ran into an issue with the IP still being located under /dmd/Networks.

Using the below snippets didnt work either :

dmd.global_catalog.uncatalog_object('/zport/dmd/Networks/192.168.8.0/ipaddresses/192.168.8.52')commit()network = dmd.Networks.unrestrictedTraverse('192.168.8.0/ipaddresses')address = dmd.Networks.unrestrictedTraverse('192.168.8.0/ipaddresses/192.168.8.52')network._remove(address)commit()

At the moment, trying to assign the Ip to address in zendmd works just fine. However, it wont let me remove it from network. Also, I was not able to uncatalog it either.

This is the error message I get attempting to call network._remove(address);

2016-01-29 14:37:53 ERROR ZODB.Connection Couldn't load state for 0x4101e1

Any ideas as to why this is happening would be much appreciated.



Subject: Did some more digging, the
Author: [Not Specified]
Posted: 2016-01-29 14:28

Did some more digging, the error message above is pointing to an OID for the /zport/dmd/Networks/path/to/ip/eth0 which are located in the zodbscan log.



Subject: bump
Author: [Not Specified]
Posted: 2016-01-31 21:48

bump



< Previous
Zenoss Core 5 to Grafana Device Interface Raw Data not Mapping as Reported in Ze ...
  Next
Zenoss Core 5 - zSnmpCollectionInterval set at 300 (5 min) but Reports display e ...
>