collins icon indicating copy to clipboard operation
collins copied to clipboard

Collins weirdness with lldp/lshw

Open sbocahu opened this issue 11 years ago • 3 comments

Hello,

Firstofall, thanks for sharing and releasing collins as open source software :)

I have struggled some time with the lshw/lldp parsing feature and I have noted this strange behaviour:

  • the lshw feature works when creating the asset + sending lshw info using the API with Curl

However:

  • it does 'not work' however when the asset has been created from the webui (either nothing or plain XML (not parsed)) but still displays 'success' when uploading lshw info, even if there are missing info (see below)
  • it does 'not work' when using the ruby client (plain xml or nothing), returns nothing

I couldn't find any information in the logs.

Also:

  • lshw parsing fails if it hasn't got any 'core' information on the CPU (old lshw ?). I believe that tags should be optionnal

Any hint would be greatly appreciated !

Thanks,

sbocahu avatar Nov 25 '13 17:11 sbocahu

Hi Sébastien,

I can't comment on the behavior your'e experiencing with lshw not working. However, regarding the parsing failing due to missing fields, I did experience a similar behavior with NIC cards. Here is the code that made the field optional, Default nic card to configured speed when missing in lshw. You could try something similar and submit a pull request.

--- Ben

papaben avatar Dec 01 '13 18:12 papaben

Thanks for your reply. I'll look into that.

About lshw/lldp parsing: I have the same problem with curl when the asset has already been created from the api (so its not webui related)

sbocahu avatar Jan 06 '14 17:01 sbocahu

Hey @zecrazytux Could you provide more information about this issue? I.e. exact error messages, what status:state assets are in when they reject LSHW/LLDP, etc?

Also, have you seen http://tumblr.github.io/collins/configuration.html#features (allowedServerUpdateStatuses)? This allows you to tune collins to accept lshw/lldp submissions in states other than maintenance and incomplete: allowedServerUpdateStatuses = [ INCOMPLETE, NEW, PROVISIONED, PROVISIONING ]. This may help resolve your issue.

byxorna avatar Aug 06 '14 18:08 byxorna