Network Visualization

yes, without the connection between the neighbour host and the Checkmk host object, there is no inventory information and therefore no (usable) topology.

is Switch-21-6000-24G the exact name of the host object in CMK also? If yes, is there a LLDP inventory avilable inside CMK?

This is only nessecary for the L3v4 topology, CDP/LLDP will work without the labels.

As NVDCT is doing nothing in CMK (except for reading data) you are responsible to have the correct information in CMK available.

  • HW/SW Inventory (Interfaces, CDP/LLDP/IPv4 Addresses)
  • Interface services (at the hosts)

Cheers
Thomas

Here is a short update on LLDP and Fortinet:

  • Issue 1: Fortinet uses a different format for MAC addresses than inv_lldp_cache knew → this is now fixed inv_lldp_cache-0.9.9-20240724.mkp

  • Issue 2: Fortigate has a “creative” way to use the LLDP data. Specifically, Fortinet enters the port aggregations in the LLDP table, without interface mapping for the local port to the LLDP port table, but only the interface index for the port aggregation. The remote ports are OK. In the topology it looks like this

image

This are the LLDP data on which this is based

and to complete this the interface data

I have now added a tweak for Fortinet to inv_lldp_cache (not yet online). This will map the information for the port aggregation to the LLDP data. So the topology is ok.

The disadvantage is, that I have not yet found a way to read out which port from the port aggregation is actually connected to which neighboring port :frowning: I simply map the first port from the aggregation to the first neighboring port, the second to the second and so on. So if anyone here has any ideas…

Cheers
Thomas

2 Likes

Hello I have trouble to get this running. We are currently running 2.3.0p10 version so according comments above this plugin is already included. I had already install additional plugins -cdp, lldp, inv_ifname and nvdct as well. HW/SW intentory is providing data - I can see cdp and lldp cache and neighbours. All host are Cisco switches, enable for monitoring including all services - ports.

Json file with cdp is generated but I can see any drop down menu to see network layer topology from aby of enabled hosts in site.

Any advice please ?

Can you show an

ls -l ~/var/check_mk/topology/data

and an

ls ~/var/check_mk/topology/data/default/

please.

That’s another weird issue what i had noticed. After some time symlink @default is gone. Same with my custom config file located under ~/local/bin/nvdct/conf/.

I had to do it all over again this morning.

OMD[PR_BE]:~/var/check_mk/topology/data$ ~/local/bin/nvdct/nvdct.py -u ~/local/bin/nvdct/conf/my-mvdct.toml

Network Visualisation Data Creation Tool (NVDCT)
by thl-cmk[at]outlook[dot]com, version 0.8.12-20240702
see CheckMK / Vendor independent / Network Visualization Data Creation Tool - NVDCT · GitLab

Start time…: 2024-08-06T07:10:19.08
Devices added.: 11, source cdp
Time taken…: 0.121734454/s
End time…: 2024-08-06T07:10:20.08

Here is output of the directory:

OMD[PR_BE]:~/var/check_mk/topology/data$ ls -l ~/var/check_mk/topology/data
total 8
drwx------ 2 PR_BE PR_BE 4096 Aug 6 07:10 2024-08-06T07:10:20.08/
lrwxrwxrwx 1 PR_BE PR_BE 66 Aug 6 07:10 default → /omd/sites/PR_BE/var/check_mk/topology/data/2024-08-06T07:10:20.08/
OMD[PR_BE]:~/var/check_mk/topology/data$
OMD[PR_BE]:~/var/check_mk/topology/data$
OMD[PR_BE]:~/var/check_mk/topology/data$
OMD[PR_BE]:~/var/check_mk/topology/data$ ls ~/var/check_mk/topology/data/default/
data_cdp.json
OMD[PR_BE]:~/var/check_mk/topology/data$

Attached is log file and json data.
nvdct.log.txt (837 Bytes)
data_cdp.json.txt (8.6 KB)

Is it possible that you do your work on slave node inside a distributed monitoring setup?
If yes, please switch to the central instance.

Yes we have distributed setup for monitoring, correct. This mean all scripts and data must be executed in main / central server, although switches are monitored from slaves / satellite locations ?

Exactly - if you have enabled the sync of your mkp’s and other data, all changes on your remote instances are overwritten by your central system.
The tool from @thl-cmk fetches the needed data from the other instances. It is also important that the JSON file exists on the central system. Without this you will not see any icon in the GUI.

1 Like

Thank you for guide ! It help !!
So i can have several different configuration for each site and run command separately, correct and data will be merged in to one json file ?

I have addtional question - we do have some site under Cisco prime management and it this case they have CDP Neighbours name in full domain format - see attached image (checkmk host are in short names only without domain). If i use HOST_MAP like below, result in error ? Should I use quotes then ? ( “sw001bh.sz.lan” = “sw001bh” )

[HOST_MAP]
sw001bh.sz.lan = “sw001bh”


1 Like

Yes

Yes

No

NVDCT will automatically cut the domain name, except if you use the --keep-domain option. So as long as the hostname (without domain) matches the name in CMK you are fine.

Based on some comon issues I have created a little Troubleshooting guide. I hope this will help with the first steps. This not complete (yet). Based on the feedback here and the issues I run into my self, I will update the guide from time to time.

Cheers
Thomas

1 Like

Hi, guys! Good afternoon.

My environment is pretty simple. I have mostly Fortinet devices connected in the following sequence:

Firewalls >> Switches >> APs

The Firewalls and Switches are LLDP capable and the information is shown in the WATO interface as result of the HW/SW Inventory.

I did created a NVDCT file using the FWs and SWs as seed devices to generate the topologies and this is what I’ve got:

There are no connections between the devices. The filters do not work as desired.

What should I do?

Hello guys,

I have followed the documentation and reached here with the error.
Can you shed some light, please?

Thanks.

Hi Suman,
this is something for @thl-cmk , as the error message is triggered in his mkp.

As a short info. I haven’t had much time in the last few months to make further progress on the entire visualization project. There are some ongoing major refactorings in our monitoring GUI framework that are taking up all of my time.
Hopefully over the winter holidays I can make some updates and integrate the latest feedback.

Regards
Andreas

3 Likes

I have the same issue. Tried adding --log-level DEBUG --log-to-stdout to the command but still get the same output on the screen but do get this in the log file.

2024-11-04 09:35:07,593 :: INFO :: nvdct :: () :: 609 :: Data creation started
2024-11-04 09:35:07,594 :: INFO :: settings :: sites() :: 544 :: fFound 0 to filter on

CME 2.3.0p19

Not sure if this is the best over all fix but I changed line 387 in /opt/omd/sites/SITENAME/local/bin/nvdct/lib/backends.py and this fixed the error and was able to finally get data into the Network Topology.

‘customer’: data[‘customer’] # needed to filter by customer

to

‘customer’: data.get(‘customer’), # needed to filter by customer

I think this change is correct as you have only the customer attribute if you use a MSP edition of CheckMK.
I can ping @thl-cmk that he can implement this in his package.

Cool. I can’t take credit for it as it came from a ChatGPT suggestion but what was confusing is that I do have the MSP version. From what I understand it was not getting any data from the ‘customer’ values. I am not a programmer so I defer to the developer(s) to make sure this is correct.

@rickb & @shresu this was already fixed internally (in the same way as ChatGPT suggested :wink: ), but didn’t make it onto my website. It is now online.

@rickb send you a PM.

3 Likes

Hello @thl-cmk

Thanks for your Network Visualization Tool… thats great and our Network Team like it :wink:
But we have a probelm…

we have 3 Types of cisco switches…

  1. Switches where the CDP neighbor name is “normal” FQDN
  2. Switches where the CDP neighbor name is FQDN + Serial Number for example switch12.domain.de(fdo123456) but this can be changed via a setting to type 1
  3. Switches like type 2 but we are not able to change the behaviour. in this case your tool can’t match interfaces and we have only blue questionmarks :frowning:

is there an option to remove the “(fdo123456)” at the end of the device-name?

Thanks
Frank