OID name resolution inside PHP

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

Post Reply
gilson
Posts: 27
Joined: Wed Jan 23, 2002 7:00 pm
Contact:

OID name resolution inside PHP

Post by gilson »

I'm seting up a new machine to my actual installation of cacti (0.6.7). I have it running on RH72.

The new machine has RH73 (all erratas applied).
The Mysql db and the entire Cacti's tree was rsync'd from the old machine.

Everything is running except those poolings that references textual OIDs. Ie, hrLoadProcessor.2. Even built in '"Get SNMP network data" doesn't work. All other poolings via perl,shell and python scripts, and numeric OIDs works fine.

At Linux prompt, for example, "snmpget 11.22.3.44 community hrProcessorLoad.2" (or any other textual OID) works fine.

These packages are installed:

Code: Select all

ucd-snmp-4.2.5-7.73.0
ucd-snmp-utils-4.2.5-7.73.0
ucd-snmp-devel-4.2.5-7.73.0
php-4.1.2-7.3.4
php-mysql-4.1.2-7.3.4
php-snmp-4.1.2-7.3.4
Any hint ?

Thanks
-Gilson
raX
Lead Developer
Posts: 2243
Joined: Sat Oct 13, 2001 7:00 pm
Location: Carlisle, PA
Contact:

Post by raX »

The reason textual OID's is working at the prompt but not from within cacti is because you are using PHP's builtin SNMP support. I know this because you have installed the php-snmp-4.1.2-7.3.4 package.

The problem is that the PHP module cannot find your MIB files. I know in win32 there is a directory you can dump them in, but I am not sure how PHP deals with MIB's in Unix. You may want to try looking in your php.ini and seeing if there is anything obvious.

Then again, you can always disable PHP's builtin support for SNMP if things aren't working out. You can do this by opening your 'include/config.php' file and changing line 59 to:

Code: Select all

$config["php_snmp_support"] = false;
Hope that helps.

-Ian
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest