AutoM8 Question - Picking up Switch Interfaces it should not be
Moderators: Developers, Moderators
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
Query is returning interfaces that are in a Down/Down state and not just ones in an Up/Up state as I expect.
System - Red Hat Enterprise
Cacti Version - 1.2.23
RRDTool - 1.7.0
Poller - CMD
[u]Plugins Installed[/u]
Monitor 2.5
ReportIT 1.1.3
Thold 1.7
Weathermap 1.0
Cacti Version - 1.2.23
RRDTool - 1.7.0
Poller - CMD
[u]Plugins Installed[/u]
Monitor 2.5
ReportIT 1.1.3
Thold 1.7
Weathermap 1.0
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
Can you log this on GitHub? It's a bug the inside query is missing a group by hsc.host_id.
Before history, there was a paradise, now dust.
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
Sure thing
System - Red Hat Enterprise
Cacti Version - 1.2.23
RRDTool - 1.7.0
Poller - CMD
[u]Plugins Installed[/u]
Monitor 2.5
ReportIT 1.1.3
Thold 1.7
Weathermap 1.0
Cacti Version - 1.2.23
RRDTool - 1.7.0
Poller - CMD
[u]Plugins Installed[/u]
Monitor 2.5
ReportIT 1.1.3
Thold 1.7
Weathermap 1.0
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
Saw the ticket and it's not missing the GROUP BY. I guess the question is, when did you last Re-Index the devices? The data it's pulling to do the automation is from the Re-Index Cache and not the live device info. Could this be the issue as I did not find any logic errors in my review. I think showing the SQL is a great idea, but not before the 1.2.25 release.
True understanding begins only when we realize how little we truly understand...
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
I have to say this part look wrong to me:
First the OpenStatus AND the Admin Status is UP, not like. I my code I use the option Match and that part work.
Second when you do the Alias Test, the AND should be outside the parenthesis, not as first field inside of it.
So add a item AND after the position 2, then you start the ( Alias test without the and
Rough copy of my code (sorry not good at print screen with GitHub)
This Autom( is to create graph on link that are UP, where the ifAlias is SE- or SRE, etc
For my it's a trunk port to another switch.
Code: Select all
WHERE ( a.`ifOperStatus` LIKE '%Up%' AND a.`ifAdminStatus` LIKE '%Up%' ( AND a.`ifAlias` LIKE '%//%' OR a.`ifAlias` LIKE '%Wireless%' OR a.`ifName` LIKE '%Stack%' ))
Second when you do the Alias Test, the AND should be outside the parenthesis, not as first field inside of it.
So add a item AND after the position 2, then you start the ( Alias test without the and
Rough copy of my code (sorry not good at print screen with GitHub)
This Autom( is to create graph on link that are UP, where the ifAlias is SE- or SRE, etc
For my it's a trunk port to another switch.
Code: Select all
Item#1 1 ifType contains ethernetCsmacd
Item#2 4 AND ifOperStatus matches Up
Item#3 5 AND
Item#4 8 (
Item#5 9 ( ifAlias begins with SE-
Item#6 11 OR ifAlias begins with SRE-
Item#7 12 )
Item#8 13 OR ifHighSpeed is greater than or equal 10000
Item#9 14 AND ifAlias does not contain Stackwise
Item#10 15 AND ifAlias does not contain XXX
Item#11 16 AND ifAlias is not empty
Item#12 17 )
Test
Almalinux
php 8.2.14
mariadb 10.6.16
Cacti 1.2.27
Spine 1.2.27
RRD 1.7.2
thold 1.8
monitor 2.5
syslog 3.2
flowview: 3.3
weathermap 1.0 Beta
Almalinux
php 8.2.14
mariadb 10.6.16
Cacti 1.2.27
Spine 1.2.27
RRD 1.7.2
thold 1.8
monitor 2.5
syslog 3.2
flowview: 3.3
weathermap 1.0 Beta
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
Ho by the way what's the goal of testing the adminStatus if you test the operStatus ?
You will never have a operStatus UP with an adminStatus DOWN.
So just testing the operStatus on UP is enough.
You will never have a operStatus UP with an adminStatus DOWN.
So just testing the operStatus on UP is enough.
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Re: AutoM8 Question - Picking up Switch Interfaces it should not be
So, I did not write this, I inherited it instead. It's a bug for sure.
True understanding begins only when we realize how little we truly understand...
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Who is online
Users browsing this forum: No registered users and 2 guests