0.8.5 to 0.8.6g upgrade: blank page (cause: no snmp2_get() )

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
Antoine Musso
Posts: 12
Joined: Mon Dec 12, 2005 10:56 am

0.8.5 to 0.8.6g upgrade: blank page (cause: no snmp2_get() )

Post by Antoine Musso »

Hello,

I have an existing cacti running 0.8.5 and would like to upgrade it to 0.8.6g . When upgrading the database, the script fail in the 0_8_5_to_0_8_6.php script giving no error (just a blank page).

I tracked the issue : the upgrade system reindex the poller cache and call cacti_snmp_get function from ./lib/snmp.php. Debugging it, there is a @snmp2_get call which have been implemented by a patch for 0_8_6c : http://www.cacti.net/downloads/patches/ ... p_v2.patch

That call is obviously wrong ! If the snmp2_get() function does not exist, php will raise a fatal error which end the script but the @ will hide it to the user :(

I think you should remove that '@'.


Finally, I have been unable to find any php version that ship with the snmp2_get() & snmp3_get() functions , maybe you should remove them from script or revert to commandline 'snmpget' system calls for snmpv2 & v3 .
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

What version of php are you running?
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
Antoine Musso
Posts: 12
Joined: Mon Dec 12, 2005 10:56 am

Post by Antoine Musso »

php-4.3.9-3.1 coming from Red Hat Enterprise Linux ES release 4 (Nahant).

Php got snmp extension too:

$ php -m | grep snmp
snmp
$
Antoine Musso
Posts: 12
Joined: Mon Dec 12, 2005 10:56 am

Post by Antoine Musso »

Would it be possible to revert the patch for next 0.8.6 version and use the snmpget -v[1|2|3] syntax instead ?

looks like snmp_get2 is an undocumented function in php.
Post Reply

Who is online

Users browsing this forum: No registered users and 17 guests