Cacti PHP error after upgrade

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

Moderators: Developers, Moderators

Post Reply
bjorn
Posts: 19
Joined: Wed Mar 23, 2005 9:43 pm

Cacti PHP error after upgrade

Post by bjorn »

I've just upgraded from Fedora 6 to Fedora 10. After the upgrade I noticed that cacti was not polling.

This is the error I get:

[root@iccmon modules]# /usr/bin/php /usr/share/cacti/poller.php
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/modules/snmp.so' - libnetsnmp.so.10: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Notice: Constant URL_PATH already defined in /usr/share/cacti/include/plugins.php on line 46

Fedora 10
PHP 5.2.6-5
Cacti 0.8.7a



Any ideas?
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

These are PHP build issues. There appear to be missing PHP module shared library files.

TheWitness
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?
bjorn
Posts: 19
Joined: Wed Mar 23, 2005 9:43 pm

Post by bjorn »

So the best thing would be to reinstall php?
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

You need to locate the libnetsnmp.so.10 file is or uninstall php_snnp and use Net-SNMP instead. I hope you didn't build from source.

TheWitness
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?
bjorn
Posts: 19
Joined: Wed Mar 23, 2005 9:43 pm

Post by bjorn »

Alright I uninstalled php_snmp

and installed net_snmp with the following results

Do I need to change the config for cacti now to point at net_snmp?

[root@iccmon modules]# /usr/bin/php /usr/share/cacti/poller.php
PHP Notice: Constant URL_PATH already defined in /usr/share/cacti/include/plugins.php on line 46
PHP Notice: Constant URL_PATH already defined in /usr/share/cacti/include/plugins.php on line 46
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
/usr/bin/snmpgetnext: error while loading shared libraries: libnetsnmp.so.10: cannot open shared object file: No such file or directory
03/27/2009 03:06:59 PM - SYSTEM STATS: Time:2.1934 Method:cmd.php Processes:1 Threads:N/A Hosts:36 HostsPerProcess:36 DataSources:108 RRDsProcessed:0
03/27/2009 03:06:59 PM - WEATHERMAP: Poller[0] Weathermap 0.941 starting - Normal logging mode. Turn on DEBUG in Cacti for more information
03/27/2009 03:06:59 PM - WEATHERMAP: Poller[0] Map: /usr/share/cacti/plugins/weathermap/configs/vmswitchs.conf -> /usr/share/cacti/plugins/weathermap/output/weathermap_3.html & /usr/share/cacti/plugins/weathermap/output/weathermap_3.png
03/27/2009 03:06:59 PM - WEATHERMAP: Poller[0] ReadData: LINK ICCBLSW1-ICCTS2c, target: /usr/share/cacti/rra/iccblsw1_traffic_in_709.rrd on config line 83 had no valid data, according to WeatherMapDataSource_rrd
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Something is jacked with your installation. Do you not have the net-snmp-libs installed. They are a dependency. You definately have a smoked system if net-snmp is not even working. That URL_PATH is also an 088 file and not 087. Are you testing MacTrack or just have the development version installed?

TheWitness
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?
bjorn
Posts: 19
Joined: Wed Mar 23, 2005 9:43 pm

Post by bjorn »

No mactrack testing or dev

[root@iccmon ~]# rpm -q cacti
cacti-0.8.7a-1.fc6.noarch
[root@iccmon ~]# rpm -q net-snmp-libs
net-snmp-libs-5.4.2.1-3.fc10.i386
[root@iccmon ~]# rpm -q net-snmp
net-snmp-5.4.2.1-3.fc10.i386
[root@iccmon ~]#
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Well, who knows. Maybe the dependencies for the fc6 package screwed things up for you. Not sure. Sorry. You know what the problem is, now you have to figure out how to fix it. If you can just find a copy of that file and put it in the right directory, you would be fine.

TheWitness
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?
bjorn
Posts: 19
Joined: Wed Mar 23, 2005 9:43 pm

Post by bjorn »

Thanks TheWitness... appreciate the time spent
bjorn
Posts: 19
Joined: Wed Mar 23, 2005 9:43 pm

Post by bjorn »

I fixed this by doing a yum update cacti

==================================================================================================================================================================================
Package Arch Version Repository Size
==================================================================================================================================================================================
Updating:
cacti noarch 0.8.7d-1.fc10 updates 2.1 M
Installing for dependencies:
php-snmp i386 5.2.6-5 fedora 24 k


All is working now :)
jerryshenk
Posts: 1
Joined: Sat Jul 21, 2007 11:44 am

Post by jerryshenk »

Updating did not help for me. I've spent WAY too much time on this...maybe this will help the next guy. Here's a change to /etc/php.ini that worked for me.

#extension_dir = /etc/php.d
extension_dir = /usr/lib/php/modules/
User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

Post by maxxic »

TheWitness wrote:You need to locate the libnetsnmp.so.10 file is or uninstall php_snnp and use Net-SNMP instead. I hope you didn't build from source.
I solved the problem this way.
Thanks!
Sapienti sat
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests