
linux Can't connect to local MySQL server through socket '/opt/lampp/var/m...
Unable to connect to your database server using the provided settings.
root@menjin:/data/wwwroot/face360/system/core# vim Loader.php
vim /application/config/database.php
修改:
$db['default']['pconnect'] = TRUE;
$db['default']['db_debug'] = TRUE;
修改后:
$db['default']['pconnect'] = FALSE;
$db['default']['db_debug'] = FALSE;
/opt/lampp/lampp startmysql
/opt/lampp/bin/mysql.server: line 260: kill: (11145) - No such process
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/opt/lampp/var/mysql/mysql.sock' (2 "No such file or directory")
xampp程序以及配置文件都没有任何改动,前几天,网站还正常运行,今天就莫名其妙的显示mysql无法正常连接。初步判断不是程序的问题。
所以第一步开始去排查服务器的系统盘占用情况
df -l –执行命令,查看系统盘空间占用情况
du -s -h ./*
/opt/lampp/var/mysql
2018-12-24 10:50:50 10085 mysqld_safe Starting mysqld daemon with databases from /opt/lampp/var/mysql
2018-12-24 10:50:50 140491172915008 [Note] InnoDB: innodb_empty_free_list_algorithm has been changed to legacy because of small buffer pool size. In order to use backoff, increase buffer pool at least up to 20MB.
2018-12-24 10:50:50 140491172915008 [Note] Using unique option prefix 'key_buffer' is error-prone and can break in the future. Please use the full name 'key_buffer_size' instead.
2018-12-24 10:50:50 140491172915008 [Note] /opt/lampp/sbin/mysqld (mysqld 10.1.37-MariaDB) starting as process 10231 ...
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Using mutexes to ref count buffer pool pages
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: The InnoDB memory heap is disabled
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Compressed tables use zlib 1.2.11
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Using SSE crc32 instructions
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Initializing buffer pool, size = 16.0M
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Completed initialization of buffer pool
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Highest supported file format is Barracuda.
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: 128 rollback segment(s) are active.
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Waiting for purge to start
2018-12-24 10:50:51 140491172915008 [Note] InnoDB: Percona XtraDB (http://www.percona.com) 5.6.41-84.1 started; log sequence number 17666815
2018-12-24 10:50:51 140491172915008 [Note] Plugin 'FEEDBACK' is disabled.
2018-12-24 10:50:51 140491172915008 [Note] Recovering after a crash using tc.log
2018-12-24 10:50:51 140491172915008 [ERROR] Can't init tc log
2018-12-24 10:50:51 140491172915008 [ERROR] Aborting
2018-12-24 10:50:53 10085 mysqld_safe mysqld from pid file /opt/lampp/var/mysql/izuf655vwf6dndsynw1j3mz.pid ended
转载请注明:XAMPP中文组官网 » 记一次使用xampp安装的MySQL启动失败问题排查