Error: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Errno.: 2002
2)我们建立一个软连接,ln -s /tmp/mysql.sock /var/lib/mysql/mysql.sock
二、在重启mysql出现:Timeout error occurred trying to start MySQL Daemon.
Timeout error occurred trying to start MySQL Daemon.
Starting MySQL: [FAILED]
(1)先看日志 /var/log/message,但是看来 /var/log/mysql
(2)磁盘满的话也会出现这个情况
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/hda1 9920592 2292208 7116316 25% /
/dev/hda6 19171756 963340 17218816 6% /backup
tmpfs 509492 0 509492 0% /dev/shm
/dev/hda2 39674224 22471284 15155056 60% /home
/dev/hda3 4956316 4714212 0 100% /var
{linux环境下执行命令ls,ls >>log.txt; 将其结果重定向输出到log.txt文件中; 但缺省的每次都会追加到log.txt文件中;
请问怎么样才能让日志内容不追加;只保留当前操作的输出内容}
[root@linux log]#ls > log.txt
一个>就是覆盖log.txt
-rw-r----- 1 mysql mysql 17256394 Sep 18 02:13 mysqld.log //17256394k=1.8M
个人操作:[root@linux mysql]# ls >mysqld.log
变成
-rw-r----- 1 mysql mysql 403 Sep 18 02:33 mysqld.log //403k
[root@linux mysql]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hda1 9.5G 2.2G 6.8G 25% /
/dev/hda6 19G 941M 17G 6% /backup
tmpfs 498M 0 498M 0% /dev/shm
/dev/hda2 38G 22G 15G 60% /home
/dev/hda3 4.8G 4.5G 8.0K 100% /var
Stopping MySQL: [ OK ]
Starting MySQL: [ OK ]