Installing Zabbix on WHM / cPanel
Is there an approved WHM / cPanel method for installing Zabbix? Using Zabbix's yum instructions [1] results in:
I believe everything 'missing' is already installed by cPanel, so is 'skip-broken' a valid method for installing this? Thanks, Michael Ref: [1] https://www.zabbix.com/documentation/2.2/manual/installation/install_from_packages
--> Finished Dependency Resolution
Error: Package: zabbix-server-mysql-2.2.2-1.el6.x86_64 (zabbix)
Requires: libmysqlclient.so.16(libmysqlclient_16)(64bit)
Error: Package: zabbix-web-mysql-2.2.2-1.el6.noarch (zabbix)
Requires: php-mysql
Error: Package: zabbix-web-2.2.2-1.el6.noarch (zabbix)
Requires: httpd
Error: Package: zabbix-web-2.2.2-1.el6.noarch (zabbix)
Requires: php-gd
Error: Package: zabbix-server-mysql-2.2.2-1.el6.x86_64 (zabbix)
Requires: libmysqlclient.so.16()(64bit)
Error: Package: zabbix-web-2.2.2-1.el6.noarch (zabbix)
Requires: php-mbstring
Error: Package: zabbix-web-2.2.2-1.el6.noarch (zabbix)
Requires: php-xml
Error: Package: zabbix-web-2.2.2-1.el6.noarch (zabbix)
Requires: php >= 5.3
Error: Package: zabbix-web-2.2.2-1.el6.noarch (zabbix)
Requires: php-bcmath
You could try using --skip-broken to work around the problem
** Found 1 pre-existing rpmdb problem(s), 'yum check' output follows:
sendmail-cf-8.14.4-8.el6.noarch has missing requires of sendmail = ('0', '8.14.4', '8.el6')
I believe everything 'missing' is already installed by cPanel, so is 'skip-broken' a valid method for installing this? Thanks, Michael Ref: [1] https://www.zabbix.com/documentation/2.2/manual/installation/install_from_packages
-
The missing packages are not provided by cPanel. PHP in particular is compiled from source, not installed via RPM. Installing these depedency RPMs will break your PHP installation. A couple suggestions: * Install the zabbix rpms using --nodeps and hope it works * Install zabbix on a separate server, which you should be doing anyways. You typically don't want to monitor a server from itself...it's rather pointless. 0 -
[quote="vanessa, post: 1577851">The missing packages are not provided by cPanel. PHP in particular is compiled from source, not installed via RPM. Installing these depedency RPMs will break your PHP installation.
CPanel installs its own versions (PHP/MySQL/etc.) and blocks yum from installing them, so they aren't actually 'missing,' just not 'see-able' from yum. No dependency might work, but... [quote="vanessa, post: 1577851">* Install the zabbix rpms using --nodeps and hope it works
Yeah, not happening, without a cPanel admin type saying, "We've done it this way, and it's worked." cPanel has too many changes from a standard CentOS install to blindly try something like that. [quote="vanessa, post: 1577851">* Install zabbix on a separate server, which you should be doing anyways. You typically don't want to monitor a server from itself...it's rather pointless.
I'm wanting to install in on a backup server which needs to monitor production servers for failover.0 -
[quote="Michael-Inet, post: 1577871">CPanel installs its own versions (PHP/MySQL/etc.) and blocks yum from installing them, so they aren't actually 'missing,' just not 'see-able' from yum. No dependency might work, but...
cPanel has its own internal PHP installed via RPM, but it's located in /usr/local/cpanel/3rdparty. The system PHP is compiled from source via EasyApache. This is simple enough to confirm:root@server [~]# rpm -ql cpanel-php53-5.3.17-6.cp1136.x86_64 |head /usr/local/cpanel/3rdparty/php/53/bin/phar /usr/local/cpanel/3rdparty/php/53/bin/phar.phar /usr/local/cpanel/3rdparty/php/53/bin/php /usr/local/cpanel/3rdparty/php/53/bin/php-cgi ...
[quote="Michael-Inet, post: 1577871">Yeah, not happening, without a cPanel admin type saying, "We've done it this way, and it's worked." cPanel has too many changes from a standard CentOS install to blindly try something like that.
I don't really see anything in the Zabbix RPMs that would conflict with cPanel. Some things may not work right off the bat (like the httpd.conf include, which would need to be configured separately), but you can easily see what's being installed. Download the RPM, and run:rpm -qpl zabbix-web-2.2.2-1.el6.noarch.rpm
You'll see what files are being put where. If it's something that makes you nervous you could always just compile from source and install in the location of your choice. I'll probably look into the RPM stuff a little bit more and see if I can figure it out, if you can wait a day or so. Unless you'd rather hear it from a cPanel admin that isn't me ;)0 -
Well played, Vanessa. :p 0 -
[quote="Infopro, post: 1577912">Well played, Vanessa. :p
Why thank you, sir ;) @Michael-Inet: I did an RPM'd Zabbix installation on a CentOS 6 VPS, and it works fine. I'll probably write this up and post it to the blog at some point, but here are the steps:rpm -i --nodeps http://linux.mirrors.es.net/fedora-epel/6/x86_64/zabbix-1.8.19-1.el6.x86_64.rpm rpm -i --nodeps http://linux.mirrors.es.net/fedora-epel/6/x86_64/zabbix-agent-1.8.19-1.el6.x86_64.rpm rpm -i --nodeps http://linux.mirrors.es.net/fedora-epel/6/x86_64/zabbix-web-1.8.19-1.el6.noarch.rpm
This error is fine: [QUOTE] warning: user apache does not exist - using root warning: group apache does not exist - using root
cp zabbix.conf /usr/local/apache/conf/includes/
Add the following to /usr/local/apache/conf/httpd.conf:Include "/usr/local/apache/conf/includes/zabbix.conf"
Run the distiller to save the manual httpd.conf edit:/usr/local/cpanel/bin/apache_conf_distiller --update
Set the correct permissions on the Zabbix home (this is what the RPM tried to set to the 'apache' user that doesn't exist):chown -R nobody:nobody /usr/share/zabbix
(note: you probably don't need to do thus unless you run PHP as a CGI module, ie suphp, fastcgi, etc) The just go to0
Please sign in to leave a comment.
Comments
5 comments