Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bandwidth direction - Link color mixed up? #213

Open
maziggy opened this issue Mar 17, 2019 · 7 comments
Open

Bandwidth direction - Link color mixed up? #213

maziggy opened this issue Mar 17, 2019 · 7 comments

Comments

@maziggy
Copy link

maziggy commented Mar 17, 2019

I have two links in my map where the colouring seems to be mixed up (please see screenshot). Ingress direction should be coloured as higher utilized, but is is applied to Egress direction. All other links on the map are shown as they should.

Upper link on screenshot:
LINK ipaddress-ipaddress
WIDTH 4
BWLABELPOS 40 60
TARGET snmp:community:ipaddress:.1.3.6.1.2.1.31.1.1.1.6.511:.1.3.6.1.2.1.31.1.1.1.10.511
NODES ipaddress:0r45 ipaddress:0r45
VIA 1034 432
BANDWIDTH 40

Lower link on screenshot:
LINK ipaddress-ipaddress aa
WIDTH 4
BWLABELPOS 35 65
TARGET snmp:community:ipaddress:.1.3.6.1.2.1.31.1.1.1.6.512:.1.3.6.1.2.1.31.1.1.1.10.512
NODES ipaddress:0r15 ipaddress:0r15
VIA 1038 486
BANDWIDTH 40

Any hints are appreciated.

Screenshot-2019-03-17-at-17 39 27

@howardjones
Copy link
Owner

You've removed too much information, but my guess is that one of the links is from A->B and the other is from B->A.

@maziggy
Copy link
Author

maziggy commented Mar 17, 2019

Both link targets start at the same switch.

LINK 10.0.1.204-10.0.1.206
WIDTH 4
BWLABELPOS 40 60
TARGET snmp:community:10.0.1.204:.1.3.6.1.2.1.31.1.1.1.6.511:.1.3.6.1.2.1.31.1.1.1.10.511
NODES 10.0.1.204:0r45 10.0.1.206:0r45
VIA 1034 432
BANDWIDTH 40

LINK 10.0.1.204-10.0.1.206aa
WIDTH 4
BWLABELPOS 35 65
TARGET snmp:community:10.0.1.204:.1.3.6.1.2.1.31.1.1.1.6.512:.1.3.6.1.2.1.31.1.1.1.10.512
NODES 10.0.1.204:0r15 10.0.1.206:0r15
VIA 1038 486
BANDWIDTH 40

@howardjones
Copy link
Owner

OK, then try a run with debugging on for one map calculation, and check that the SNMP plugin is returning what you think it is. Look for the lines with ReadData (and the link name) in the output. The colours match the numbers. See if the numbers match your assumption...

@howardjones
Copy link
Owner

Did that shed any light?

@TekunoKage
Copy link

Remove BWLABELPOS and check, sometime modifying those swap the proper placement based on the indicated positions.

@howardjones
Copy link
Owner

Well spotted!

In the manual it does say:

The two position values are percentages along the link arrow, from the first to the second node. Therefore BWLABELPOS 75 25 is the default.

and then:

Weathermap will produce a warning if the outpostion is greater than the inposition. In most cases, you have probably made a mistake, but if you have a good reason to do this, then you can disable that warning using 'SET nowarn_bwlabelpos 1' in the top section of you map config file.

So you should have had a warning in the log file. You checked the logfile, right? :-)

(or is this a bug and I need to check that the warning is still generated? Looking at the code, it does look like it might have been removed...)

@howardjones
Copy link
Owner

And for 0.98 and 0.98a the warning is still there:

if( ($this->linkstyle=='twoway') && ($this->labeloffset_in < $this->labeloffset_out) && (intval($map->get_hint("nowarn_bwlabelpos"))==0) )
		{
			wm_warn("LINK ".$this->name." probably has it's BWLABELPOSs the wrong way around [WMWARN50]\n");
		}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants