Page 1 of 1

Renaming devices

Posted: Sun Jul 17, 2022 4:37 pm
by kingtrw
Our devices are named via hostfile entry (I know, but it's what I've got to work with for now) and I have an Observium NSM sync that runs daily.

The problem I face is - how to deal with renaming devices (which is something we need to do quite a lot of)?

At the moment if I rename the device, when the sync runs the new name appears as a new device ; and when the backup worker runs it will back up as a new device, and the old device will fail.

What I have been doing is deleting the new device, and then editing the name and description of the old one and rediscovering it -- this seems to work, but it's dependent on me being told when a device is renamed (which isn't something I can rely on).

Is there a more preferable way to handle this, or do I just need to keep better track of changes?

many thanks!

Re: Renaming devices

Posted: Thu Jul 28, 2022 2:25 pm
by Vik@Unimus
The reason this is happening is because Unimus doesn't sync devices based on remote IDs (internal IDs from Observium) to pair them not just by their addresses, but also by an identifiers from Observium, so when an address changes, the device will still pair correctly with the one in Unimus database. This will be the reason why you are seeing the behavior on your end and why you'd have to rename devices in beforehand to not having a new device being created after the next NMS sync runs.

In any case, I have done some digging and it looks there are device IDs in the responses from Observium API. We have created an internal ticket and we will take a look at it and see if we can add device ID syncing (it looks like we should be able to do it), pretty much solving this issue. I will update the ticket when there is any update to share.

Re: Renaming devices

Posted: Sun Jul 31, 2022 5:33 pm
by kingtrw
Thanks! For now it's not really a problem - because we're relying on a manual sync of a hostfile for our switch names, everything is fine as long as I remember to rename the device *before* the auto-sync runs!