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

When using php-snmp and setting SNMPv3, warning is now shown as library does not support it properly #3299

Closed
Uedogit opened this issue Feb 26, 2020 · 11 comments
Labels
3rd Party Bug 3rd party bug
Milestone

Comments

@Uedogit
Copy link

Uedogit commented Feb 26, 2020

Describe the bug
If i use Cacti to monitor Brocade FC Switches with so called virtual fabrics i have to use this command

snmpwalk -v 3 -u userX -l authnoPriv -a MD5 -A passwordX -n VF:100 ipxxx .1.... oid

  • on cli it works --> i get a value

I created a data sourcee with the right OID
In the device section i use a new device where i insert for example VF:100

But the cacti poller show me U and no valid value.
With no context i get an integer value --> the correct value, but i need the context

there is an error message:

ERROR PHP WARNING: SNMP::get(): Fatal error: Bad context specified in file: /var/www/html/cacti/lib/snmp.php on line 479

And:
In production i use version 1.1.28 --> it works since many updates. If i want to update, i have the same problem.

Could : be the problem?

Desktop (please complete the following information):

  • OS: RHEL
  • Browser chrome
  • Cacti Version 1.2.9 plain install
@netniV
Copy link
Member

netniV commented Feb 26, 2020

Can you be clear. Are you using 1.1.28 or 1.2.8?

@Uedogit
Copy link
Author

Uedogit commented Feb 26, 2020

cacti-1.1.28 --> true

@netniV
Copy link
Member

netniV commented Feb 28, 2020

And that is the version you are having the problem with, or 1.2.9 is?

@Uedogit
Copy link
Author

Uedogit commented Feb 28, 2020

My problem is with the new Version 1.2.9!

https://github.com/Cacti/cacti/blob/develop/lib/snmp.php

function cacti_snmp_session_get($session, $oid, $strip_alpha = false)

Because I couldn't make an update to a new Version!
Then i test a new installation (1.2.9) and i see the snmp problem!

@netniV netniV added the bug Undesired behaviour label Feb 28, 2020
@TheWitness
Copy link
Member

Can you let us know if php-snmp is installed?

@Uedogit
Copy link
Author

Uedogit commented Mar 2, 2020

Yes! Version 5.4.16

@cigamit
Copy link
Member

cigamit commented Mar 8, 2020

You have to remove php-snmp to use SNMPv3 in Cacti. Can you remove the module and see if it works again.

@cigamit cigamit added unverified Some days we don't have a clue and removed bug Undesired behaviour labels Mar 8, 2020
@netniV
Copy link
Member

netniV commented Mar 8, 2020

Maybe we should throw up a warning or disable v3 if using php-snmp?

@TheWitness
Copy link
Member

Makes sense to me.

@Uedogit
Copy link
Author

Uedogit commented Mar 9, 2020

I removed php-snmp and it works! Thanks! 👍

I think a warning is necessary, cause of:

Cacti requires MySQL, PHP, RRDTool, net-snmp, and a webserver that supports PHP such as Apache or IIS.

@TheWitness TheWitness added 3rd Party Bug 3rd party bug and removed unverified Some days we don't have a clue labels Mar 14, 2020
@TheWitness TheWitness changed the title SNMP v3 Context Cacti should warn users who use php-snmp and SNMPv3 to uninstall php-snmp Mar 14, 2020
@TheWitness TheWitness added this to the 1.2.11 milestone Mar 14, 2020
TheWitness added a commit that referenced this issue Mar 14, 2020
Cacti should warn users who use php-snmp and SNMPv3 to uninstall php-snmp
@TheWitness
Copy link
Member

Warning added.

@netniV netniV changed the title Cacti should warn users who use php-snmp and SNMPv3 to uninstall php-snmp When using php-snmp and setting SNMPv3, warning is now shown as library does not support it properly Apr 5, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Jul 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
3rd Party Bug 3rd party bug
Projects
None yet
Development

No branches or pull requests

4 participants