1

When trying to start the Zabbix server, I get the following error:

Starting zabbix_server: /usr/local/sbin/zabbix_server [29360]: Cannot open [/tmp/zabbix_server.log] [Permission denied] [FAILED]

In My zabbix_server.log file:

18959:20100129:202911.592 [Z3001] Connection to database 'zabbix' failed: [104\ 5] Access denied for user 'root'@'localhost' (using password: NO)

How do I change it so that it tries to connect with the correct user / password? (I have set a password for my root account, so it can't connect to the database.)

4 Answers 4

1

Alright, you have two mistakes here : The first one : the log have to be in /var/log (well or somewhere else but not into /tmp) :

edit the file /etc/zabbix/zabbix_server.conf and look for this entry :

# Name of log file
# If not set, syslog is used

LogFile=/var/log/zabbix-server/zabbix_server.log

And check you have the same error. For the database access, you can launch :

dpkg-reconfigure zabbix-server

so you will be able to set a new password. OR, edit the file : /etc/zabbix/zabbix_server.conf again, at the end of the file, you will see :

# Database user

DBUser=zabbix

# Database password
# Comment this line if no password used

DBPassword=foo

# Connect to MySQL using Unix socket?

#DBSocket=/tmp/mysql.sock

Note that you will also have to edit the file /etc/zabbix/dbconfig.php :

$DB["TYPE"]      = "mysql";
$DB["SERVER"]    = "localhost";
$DB["PORT"]      = "0";
$DB["DATABASE"]  = "zabbix";
$DB["USER"]      = "zabbix";
$DB["PASSWORD"]  = "foo";
$ZBX_SERVER      = "127.0.0.1";
$ZBX_SERVER_PORT = "10051";

so the password match.

0

The latest Zabbix has a web interface to do the installation. Very neat. You may check here. It is better you read the entire installation procedure so that you do not end up in more errors.

1
  • But it doesn't have any option to configure the zabbix server itself...
    – Chetan
    Jan 30, 2010 at 5:49
0

You'll better make a /var/log/zabbix directory whith appropriate permission and ownership and modify your zabbix_server.conf to write the log file here, by the way, assuming zabbix server has been compiled with mysql support, you need to create a mysql user for zabbix and grant him the needed privileges on the Zabbix database.

Here are are some links regarding setting up MySQL:

Creating users in MySQL

Assigning priliges in MySQL

Hope this helps.

0

in /etc/default/zabbix-server

set START=yes

1
  • 1
    I don't see how that will help with the problem that zabbix can't open its log file.
    – Jenny D
    May 8, 2013 at 10:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .