Network map - device names

Started by nem, July 20, 2020, 04:16:22 PM

Previous topic - Next topic

nem

Hello,

Im struggling a bit to get started with netxms, and one of the questions i have is if i can somehow control how device names are generated in network map?

More specifically i want to use SNMP sysLocation as the name, or at least part of the name. Is this possible?
Ideally i would have SNMP sysname - SNMP sysLocation as name.

Im also wondering if there are more resources for learning to use the system, other than the documentation and the video series on youtube?

Thanks in advance!

Victor Kirhenshtein

Hi,

names on maps are the same as object names. You cannot have separate "map" name. However, you can rename your nodes automatically to include location information using configuration poll hook. For example, you can have hook script as this:


if (($node->snmpSysLocation != "") and not ($node->name like "*" . $node->snmpSysLocation))
   $node->rename($node->name . " " . $node->snmpSysLocation);


This script checks that node name is not already ended with location string and it is not empty, and then appends location string to node name. You may need to introduce more sophisticated logic if sysLocation can change over time and you'll need to replace old location with new one and not simply append new location.

Best regards,
Victor

nem

Hello,

Thanks for the thorough answer!

This looks interesting, but as you say it will need further logic in case things change.
I can use this for now, in case i need to expand it i would have to either rename it on each scan, or have it check every other day maybe.. I will see.

Thanks again!

Staj

It would be useful to be able to define a separate name for use in maps. We have an issue where we have to choose between descriptive node names, have large icons or use shorter names as the node name on a map is truncated based on the size of it's icon.

Victor Kirhenshtein

That sounds useful, I've registered it as feature request (https://track.radensolutions.com/issue/NX-1911).

Best regards,
Victor