Sockets

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

Moderators: Developers, Moderators

Post Reply
bemartinezm
Posts: 2
Joined: Fri Sep 16, 2011 7:37 am

Sockets

Post by bemartinezm »

Hi!
I have just updated cacti from 0.8.7b to 0.8.7e vesion, and when i try to access cacti (http://localost), it appears this message:


"The following PHP extensions are missing:

sockets
Please install those PHP extensions and retry"

Which can be the problem?

Thanks!
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Re: Sockets

Post by gandalf »

The problem is, that cacti can't open a network socket. To do so, we need php-socket support. Many distros have it built-in, but some don't. Unfortunately, the name of a required additional php module differs from distro to distro.
R.
Jerryjerry
Posts: 1
Joined: Mon Sep 26, 2011 2:37 pm
Contact:

Re: Sockets

Post by Jerryjerry »

Hello Guys,

Dear thanks for sharing. I really need this. I use it in my regular life. I think i keep updated with this.
noname
Cacti Guru User
Posts: 1566
Joined: Thu Aug 05, 2010 2:04 am
Location: Japan

Re: Sockets

Post by noname »

bemartinezm wrote:I have just updated cacti from 0.8.7b to 0.8.7e vesion, and when i try to access cacti (http://localost), it appears this message:

"The following PHP extensions are missing:

sockets
Please install those PHP extensions and retry"
and
gandalf wrote:The problem is, that cacti can't open a network socket. To do so, we need php-socket support. Many distros have it built-in, but some don't.
From particular version of Cacti (I'm not sure), it seems that php-socket support is needed to work downed-device detection via SNMP.

Try to perform ./configure with "--enable-sockets" option, then re-build PHP.

To check:
% php -m | grep sockets
sockets
Wavebourn
Posts: 4
Joined: Sat Nov 14, 2009 10:39 pm

Re: Sockets

Post by Wavebourn »

I have the same problem, despite sockets module present.

Error

The following PHP extensions are missing:

* sockets

Please install those PHP extensions and retry

# php -m
[PHP Modules]
bz2
calendar
ctype
curl
date
dbase
exif
ftp
gettext
gmp
hash
iconv
ldap
libxml
mime_magic
mysql
mysqli
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_sqlite
posix
pspell
Reflection
session
shmop
SimpleXML
snmp
sockets
SPL
standard
sysvmsg
sysvsem
sysvshm
tokenizer
wddx
xml
zlib

[Zend Modules]
noname
Cacti Guru User
Posts: 1566
Joined: Thu Aug 05, 2010 2:04 am
Location: Japan

Re: Sockets

Post by noname »

To check more detailed:

Code: Select all

% php -i | grep -i socket
...
Registered Stream Socket Transports => tcp, udp, unix, udg
MYSQL_SOCKET => /tmp/mysql.sock
mysql.default_socket => no value => no value
sockets
Sockets Support => enabled
default_socket_timeout => 60 => 60
Or, please make sure whether you don't have multiple installation of PHP.

Or, try this:
- http://numpanglewat.wordpress.com/2009/05/26/how-to-install-cacti-0-8-7d/
(See "Troubleshooting" section)

Or, ... (no idea, sorry)
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: Sockets

Post by TheWitness »

So, in more recent PHP's, you have the option of having a separate configuration for both Apache and the CLI. More than likely you have an Apache configuration that removes Socket support and a CLI configuration that enables it. Check under '/etc/php5' for more information.

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?
bemartinezm
Posts: 2
Joined: Fri Sep 16, 2011 7:37 am

Re: Sockets

Post by bemartinezm »

But where must I put "--enable-sockets"? In which File?
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: Sockets

Post by TheWitness »

there should be a conf.d directory. look for it.
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?
Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests