Supermicro - divice mis-identification #149

Closed
opened 2020-07-06 23:18:39 +02:00 by wolfman2g1 · 18 comments
wolfman2g1 commented 2020-07-06 23:18:39 +02:00 (Migrated from github.com)

the agent is recognizing Supermicro SYS-1029U-E1CRTP-2-LL09G as a chassis. This should be a 1U service not a chassis. Is there a specific override that I can set in the config file? I don't have any chassis in my infra.

Also identifying any servers with motherboard X11SPW-TF as a blade.

the agent is recognizing Supermicro SYS-1029U-E1CRTP-2-LL09G as a chassis. This should be a 1U service not a chassis. Is there a specific override that I can set in the config file? I don't have any chassis in my infra. Also identifying any servers with motherboard X11SPW-TF as a blade.
Solvik commented 2020-07-07 08:49:14 +02:00 (Migrated from github.com)

It's because of this code line:
https://github.com/Solvik/netbox-agent/blob/master/netbox_agent/vendors/supermicro.py#L27

We should be more specific in the detection of blade or not based on the product number. Do you have more information for that ?

Forcing server or blade with the command line could be a nice addition I'll open an issue for that

It's because of this code line: https://github.com/Solvik/netbox-agent/blob/master/netbox_agent/vendors/supermicro.py#L27 We should be more specific in the detection of blade or not based on the product number. Do you have more information for that ? Forcing server or blade with the command line could be a nice addition I'll open an issue for that
wolfman2g1 commented 2020-07-07 16:13:54 +02:00 (Migrated from github.com)

Sure what kind of information do you need? Also do you need help with the project?
This is the product page.
https://www.supermicro.com/products/system/1U/1029/SYS-1029U-E1CRTP.cfm

Sure what kind of information do you need? Also do you need help with the project? This is the product page. https://www.supermicro.com/products/system/1U/1029/SYS-1029U-E1CRTP.cfm
Solvik commented 2020-07-07 16:28:29 +02:00 (Migrated from github.com)

The blade detection system is based per manufacturer.
With manufacturers like Dell, it's pretty easy, blade's product number always begins with MXXX (M610, M640 etc)

It's also true with HP, but I have a feeling that it's less easy with Supermicro... they tend to have false dmidecode infos and their product number doesn't reflect the "am I a blade or a pizza box" part

If you have a better understanding of their products and know a generic way to check that, I'd be very happy to implement it !

Regarding help with the project, it's more than welcome ! It was a personal project that I thought could be interesting for other netbox user, so I'm always happy to implement or merge additional features!

The blade detection system is based per manufacturer. With manufacturers like Dell, it's pretty easy, blade's product number always begins with `MXXX` (M610, M640 etc) It's also true with HP, but I have a feeling that it's less easy with Supermicro... they tend to have false dmidecode infos and their product number doesn't reflect the "am I a blade or a pizza box" part If you have a better understanding of their products and know a generic way to check that, I'd be very happy to implement it ! Regarding help with the project, it's more than welcome ! It was a personal project that I thought could be interesting for other netbox user, so I'm always happy to implement or merge additional features!
wolfman2g1 commented 2020-07-07 16:59:23 +02:00 (Migrated from github.com)

All the supermicro servers i've used in the past few years start with SYS including their microcloud( these considered blades?).

All the supermicro servers i've used in the past few years start with SYS including their microcloud( these considered blades?).
Solvik commented 2020-07-07 17:15:38 +02:00 (Migrated from github.com)

Microcloud are considered blade from my point of view, especially if dmidecode mentions a Slot

Microcloud are considered blade from my point of view, especially if dmidecode mentions a `Slot`
wolfman2g1 commented 2020-07-07 19:39:39 +02:00 (Migrated from github.com)

From what I've noticed their product numbers aren't something that's predictable. I think to handle that programmatically would be difficult( at least for me). I have someone working with me to look at solutions. But I think being able to pass an option like is_blade: True|False when the detected vendor is supermicro may be an easy way to do it.

From what I've noticed their product numbers aren't something that's predictable. I think to handle that programmatically would be difficult( at least for me). I have someone working with me to look at solutions. But I think being able to pass an option like is_blade: True|False when the detected vendor is supermicro may be an easy way to do it.
Solvik commented 2020-07-07 20:02:45 +02:00 (Migrated from github.com)

I understand

The agent will need to know the S/N of the chassis to do the lookup, and its blade slot to correctly assign the server to the blade.

I will see if I can work on this additional feature this week

I understand The agent will need to know the S/N of the chassis to do the lookup, and its blade slot to correctly assign the server to the blade. I will see if I can work on this additional feature this week
Solvik commented 2020-07-11 15:56:23 +02:00 (Migrated from github.com)

It adds more complexity to the agent, so I preferred to rework the supermicro blade/pizza detection, would you be able to try the branch supermicro?

It adds more complexity to the agent, so I preferred to rework the supermicro blade/pizza detection, would you be able to try the branch `supermicro`?
wolfman2g1 commented 2020-07-11 21:03:48 +02:00 (Migrated from github.com)

I can try bright and early on Monday.

ryan.jones26@gmail.com
On Jul 11, 2020, 9:56 AM -0400, Solvik notifications@github.com, wrote:

It adds more complexity to the agent, so I preferred to rework the supermicro blade/pizza detection, would you be able to try the branch supermicro?

You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

I can try bright and early on Monday. ryan.jones26@gmail.com On Jul 11, 2020, 9:56 AM -0400, Solvik <notifications@github.com>, wrote: > It adds more complexity to the agent, so I preferred to rework the supermicro blade/pizza detection, would you be able to try the branch supermicro? > — > You are receiving this because you authored the thread. > Reply to this email directly, view it on GitHub, or unsubscribe.
wolfman2g1 commented 2020-07-13 19:58:31 +02:00 (Migrated from github.com)

I'm free to test the branch today. which branch should I test ?

I'm free to test the branch today. which branch should I test ?
Solvik commented 2020-07-13 20:10:42 +02:00 (Migrated from github.com)

This one : https://github.com/Solvik/netbox-agent/tree/supermicro

Le lun. 13 juil. 2020 à 19:58, Ryan Jones notifications@github.com a
écrit :

I'm free to test the branch today. which branch should I test ?


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/Solvik/netbox-agent/issues/149#issuecomment-657705155,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AABRIIMKKALYF4SVWWSGBGTR3NDNNANCNFSM4OR7HYEA
.

This one : https://github.com/Solvik/netbox-agent/tree/supermicro Le lun. 13 juil. 2020 à 19:58, Ryan Jones <notifications@github.com> a écrit : > I'm free to test the branch today. which branch should I test ? > > — > You are receiving this because you commented. > Reply to this email directly, view it on GitHub > <https://github.com/Solvik/netbox-agent/issues/149#issuecomment-657705155>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/AABRIIMKKALYF4SVWWSGBGTR3NDNNANCNFSM4OR7HYEA> > . >
wolfman2g1 commented 2020-07-13 20:31:00 +02:00 (Migrated from github.com)

I assume i need to pass an option

if self.is_blade():
File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 26, in is_blade
  product_name = self.get_product_name()
File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 52, in get_product_name
  if self.is_blade():
File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 26, in is_blade
  product_name = self.get_product_name()
File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 52, in get_product_name
  if self.is_blade():
File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 26, in is_blade
  product_name = self.get_product_name()
RecursionError: maximum recursion depth exceeded

I assume i need to pass an option ``` if self.is_blade(): File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 26, in is_blade product_name = self.get_product_name() File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 52, in get_product_name if self.is_blade(): File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 26, in is_blade product_name = self.get_product_name() File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 52, in get_product_name if self.is_blade(): File "/tmp/netbox/netbox_agent/vendors/supermicro.py", line 26, in is_blade product_name = self.get_product_name() RecursionError: maximum recursion depth exceeded ```
Solvik commented 2020-07-13 21:05:59 +02:00 (Migrated from github.com)

No, I just forgot I didn't implement supermicro server compatibilty
I've checked the code and fixed some stuff and added more tests

I got a dmidecode of a some kind of blade system to test it

Could you retry?

No, I just forgot I didn't implement supermicro server compatibilty I've checked the code and fixed some stuff and added more tests I got a dmidecode of a some kind of blade system to test it Could you retry?
wolfman2g1 commented 2020-07-13 21:59:34 +02:00 (Migrated from github.com)

seems better. still getting an error.

File "/tmp/netbox/netbox_agent/cli.py", line 39, in run
   server.netbox_create_or_update(config)
 File "/tmp/netbox/netbox_agent/server.py", line 306, in netbox_create_or_update
   if server.name != self.get_hostname():
AttributeError: 'NoneType' object has no attribute 'name'

will use the new branch to test other systems. but the box I just tested on is a model that I was having the issue with previously

seems better. still getting an error. ``` File "/tmp/netbox/netbox_agent/cli.py", line 39, in run server.netbox_create_or_update(config) File "/tmp/netbox/netbox_agent/server.py", line 306, in netbox_create_or_update if server.name != self.get_hostname(): AttributeError: 'NoneType' object has no attribute 'name' ``` will use the new branch to test other systems. but the box I just tested on is a model that I was having the issue with previously
wolfman2g1 commented 2020-07-13 22:50:34 +02:00 (Migrated from github.com)

deployed on another 6 boxes. All throw the error above however everything else seems to be working fine.

deployed on another 6 boxes. All throw the error above however everything else seems to be working fine.
Solvik commented 2020-07-15 17:25:50 +02:00 (Migrated from github.com)

You're not the first one to raise this error to me, what netbox version are you using ?

You're not the first one to raise this error to me, what netbox version are you using ?
wolfman2g1 commented 2020-07-16 01:35:48 +02:00 (Migrated from github.com)

v2.8.6
Ryan
3476787719
ryan.jones26@gmail.com

On Wed, Jul 15, 2020 at 11:35 AM Solvik notifications@github.com wrote:

You're not the first one to raise this error to me, what netbox version
are you using ?


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Solvik/netbox-agent/issues/149#issuecomment-658834102,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJFFHASQ6DEQUNFNEXPNA3R3XEEJANCNFSM4OR7HYEA
.

v2.8.6 Ryan 3476787719 ryan.jones26@gmail.com On Wed, Jul 15, 2020 at 11:35 AM Solvik <notifications@github.com> wrote: > You're not the first one to raise this error to me, what netbox version > are you using ? > > — > You are receiving this because you authored the thread. > Reply to this email directly, view it on GitHub > <https://github.com/Solvik/netbox-agent/issues/149#issuecomment-658834102>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/AAJFFHASQ6DEQUNFNEXPNA3R3XEEJANCNFSM4OR7HYEA> > . >
Solvik commented 2020-07-29 00:31:10 +02:00 (Migrated from github.com)

I'm closing this issue since I've merge the supermicro modifications
I'll open another to fix the server.name problem

I'm closing this issue since I've merge the supermicro modifications I'll open another to fix the `server.name` problem
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: DGNum/netbox-agent#149
No description provided.