В продолжение темы: http://forum.lissyara.su/viewtopic.php?f=3&t=34672
Возникла проблема не запускается mysql, в процессах он то появляется, то пропадает(состояние в top постоянно меняется: RUN, STOP,sigwai,ucond) соответственно /tmp/mysql.sock тоже то пропадает, то появляется.
На данный момент конфиг Mysql следующий:
Код: Выделить всё
zabbix# vi /usr/local/etc/my.cnf
[client]
password =*****
port = 3306
socket = /tmp/mysql.sock
[mysqld]
port = 3306
bind-address = 127.0.0.1
socket = /tmp/mysql.sock
skip-locking
log = /var/log/mysql.log
Код: Выделить всё
ls -l /tmp/
srwxrwxrwx 1 mysql wheel 0 Nov 8 07:20 mysql.sock
Код: Выделить всё
cat /var/log/mysql.log
/usr/local/libexec/mysqld, Version: 5.1.54-log (FreeBSD port: mysql-server-5.1.54_1). started with:
Tcp port: 3306 Unix socket: /tmp/mysql.sock
Time Id Command Argument
Tcp port: 3306 Unix socket: /tmp/mysql.sock
Time Id Command Argument
111108 8:41:10 1 Connect root@localhost on
1 Init DB zabbix
1 Query SET NAMES utf8
1 Query SET CHARACTER SET utf8
1 Query SELECT * FROM nodes WHERE nodetype=1 ORDER BY no deid
1 Query SELECT u.*,s.* FROM sessions s,users u WHERE s. sessionid='ad55ef12426a0b2a5c5a9343e4d2c375' AND s.status=0 AND s.userid=u.useri d AND ((s.lastaccess+u.autologout>1320730870) OR (u.autologout=0)) AND ((u.useri d BETWEEN 000000000000000 AND 099999999999999))
1 Query SELECT u.* FROM users u WHERE u.alias='guest' AND ((u.userid BETWEEN 000000000000000 AND 099999999999999))
1 Query INSERT INTO sessions (sessionid,userid,lastacces s,status) VALUES ('3c611ffcb3d92f7a36f69104adee3805',2,1320730870,0)
1 Query SELECT MAX(g.gui_access) as gui_access FROM usr grp g, users_groups ug WHERE ug.userid=2 AND g.usrgrpid=ug.usrgrpid
1 Query SELECT g.usrgrpid FROM usrgrp g, users_groups u g WHERE ug.userid = 2 AND g.usrgrpid = ug.usrgrpid AND g.users_status = 1 LIMI T 1 OFFSET 0
1 Query SELECT s.* FROM sessions s WHERE s.sessionid=' 3c611ffcb3d92f7a36f69104adee3805' AND s.status=0 AND ((s.userid BETWEEN 0000000 00000000 AND 099999999999999))
1 Query DELETE FROM sessions WHERE status=1 AND userid=' 2'
/usr/local/libexec/mysqld, Version: 5.1.54-log (FreeBSD port: mysql-server-5.1.54_1). started with:
Tcp port: 3306 Unix socket: /tmp/mysql.sock
Time Id Command Argument
/usr/local/libexec/mysqld, Version: 5.1.54-log (FreeBSD port: mysql-server-5.1.54_1). started with:
Tcp port: 3306 Unix socket: /tmp/mysql.sock
Time Id Command Argument
/usr/local/libexec/mysqld, Version: 5.1.54-log (FreeBSD port: mysql-server-5.1.54_1). started with:
Tcp port: 3306 Unix socket: /tmp/mysql.sock
Time Id Command Argument
Код: Выделить всё
#mysql -u root -p
password: *****
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.1.54-log FreeBSD port: mysql-server-5.1.54_1
Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql>use zabbix;
No connection. Trying to reconnect...
Connection id: 1
Current database: *** NONE ***
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> show Tables;
ERROR 2006 (HY000): MySQL server has gone away
No connection. Trying to reconnect...
Connection id: 1
Current database: zabbix
+-----------------------+
| Tables_in_zabbix |
+-----------------------+
| acknowledges |
| actions |
| alerts |
| applications |
| auditlog |
| auditlog_details |
| autoreg_host |
| conditions |
| config |
| dchecks |
| dhosts |
| drules |
| dservices |
| escalations |
| events |
| expressions |
| functions |
| globalmacro |
| graph_theme |
| graphs |
| graphs_items |
| groups |
| help_items |
| history |
| history_log |
| history_str |
| history_str_sync |
| history_sync |
| history_text |
| history_uint |
| history_uint_sync |
| hostmacro |
| hosts |
| hosts_groups |
| hosts_profiles |
| hosts_profiles_ext |
| hosts_templates |
| housekeeper |
| httpstep |
| httpstepitem |
| httptest |
| httptestitem |
| ids |
| images |
| items |
| items_applications |
| maintenances |
| maintenances_groups |
| maintenances_hosts |
| maintenances_windows |
| mappings |
| media |
| media_type |
| node_cksum |
| nodes |
| opconditions |
| operations |
| opmediatypes |
| profiles |
| proxy_autoreg_host |
| proxy_dhistory |
| proxy_history |
| regexps |
| rights |
| screens |
| screens_items |
| scripts |
| service_alarms |
| services |
| services_links |
| services_times |
| sessions |
| slides |
| slideshows |
| sysmaps |
| sysmaps_elements |
| sysmaps_link_triggers |
| sysmaps_links |
| timeperiods |
| trends |
| trends_uint |
| trigger_depends |
| triggers |
| user_history |
| users |
| users_groups |
| usrgrp |
| valuemaps |
+-----------------------+
88 rows in set (0.20 sec)
Код: Выделить всё
# mysql -u root -p
Enter password: *****
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)