This repository has been archived by the owner on Jul 1, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 175
Unable to utilize any properties on a HostSnmpSystem object #125
Comments
nmaludy
changed the title
Unable to utilize an properties on a HostSnmpSystem object
Unable to utilize any properties on a HostSnmpSystem object
Nov 21, 2017
Did a little debugging this morning based on the stacktrace above. Here is the JSON for the {
"obj": "HostSnmpSystem(\"snmpSystem-2149\")",
"propSet": [
],
"missingSet": [
{
"path": "configuration",
"fault": {
"fault": {
"faultMessage": [
],
"reason": "unexpected error reading property",
"json_class": "RbVmomi::VIM::SystemError"
},
"localizedMessage": "",
"json_class": "RbVmomi::BasicTypes::LocalizedMethodFault"
},
"json_class": "RbVmomi::VIM::MissingProperty"
}
],
"json_class": "RbVmomi::VIM::ObjectContent"
} So, it looks like vSphere is returning a bad response for the PropertyCollector RetrieveProperties query that is being sent. |
Here is the SOAP that is being sent: <env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<env:Body>
<RetrieveProperties xmlns="urn:vim25">
<_this type="PropertyCollector">propertyCollector</_this>
<specSet xsi:type="PropertyFilterSpec">
<propSet xsi:type="PropertySpec">
<type>HostSnmpSystem</type>
<pathSet>configuration</pathSet>
</propSet>
<objectSet xsi:type="ObjectSpec">
<obj type="HostSnmpSystem">snmpSystem-2149</obj>
</objectSet>
</specSet>
</RetrieveProperties>
</env:Body>
</env:Envelope> And the response that is being received: <RetrievePropertiesResponse xmlns="urn:vim25">
<returnval>
<obj type="HostSnmpSystem">snmpSystem-2149</obj>
<missingSet>
<path>configuration</path>
<fault>
<fault xsi:type="SystemError">
<reason>unexpected error reading property</reason>
</fault>
<localizedMessage/>
</fault>
</missingSet>
</returnval>
</RetrievePropertiesResponse> |
Looks like this is related to #89 @crayfishx @jrgarcia |
FYI, not sure why but if i point rbvmomi directly at the ESX host and run the exact same code, it works just fine. For some reason pointing at vSphere fails. <env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<env:Body>
<RetrieveProperties xmlns="urn:vim25">
<_this type="PropertyCollector">ha-property-collector</_this>
<specSet xsi:type="PropertyFilterSpec">
<propSet xsi:type="PropertySpec">
<type>HostSnmpSystem</type>
<pathSet>configuration</pathSet>
</propSet>
<objectSet xsi:type="ObjectSpec">
<obj type="HostSnmpSystem">ha-snmp-agent</obj>
</objectSet>
</specSet>
</RetrieveProperties>
</env:Body>
</env:Envelope> <RetrievePropertiesResponse xmlns="urn:vim25">
<returnval>
<obj type="HostSnmpSystem">ha-snmp-agent</obj>
<propSet>
<name>configuration</name>
<val xsi:type="HostSnmpConfigSpec">
<enabled>true</enabled>
<port>161</port>
<readOnlyCommunities>xxx</readOnlyCommunities>
<option>
<key>EnvEventSource</key>
<value>indications</value>
</option>
<option>
<key>engineid</key>
<value>00000063000000a100000000</value>
</option>
<option>
<key>loglevel</key>
<value>info</value>
</option>
</val>
</propSet>
</returnval>
</RetrievePropertiesResponse> |
🤔 Interesting. I'm sure that has something to do with it. I'll definitely see what I can find out about that. Thanks! |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
This raises the following exception:
According to the documentation here: https://code.vmware.com/doc/preview?id=4206#/doc/vim.host.SnmpSystem.html i should be able to access the
configuration
andlimits
properties.System details:
The text was updated successfully, but these errors were encountered: