mysql - 无法重新启动mysql

标签 mysql wordpress ubuntu digital-ocean

我为 DigitalOcean 托管的 WordPress 网站建立数据库连接时出错。所以我检查了数据库出了什么问题。

sudo/etc/init.d/mysql restart 返回

stop: Unknown instance: 
start: Job failed to start

df -h/ 返回以下内容,因此磁盘未满?

Filesystem                 Size  Used Avail Use% Mounted on
/dev/disk/by-label/DOROOT   20G   12G  6.9G  63% /

sudo -u mysql mysqld 返回

170828  4:33:48 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
170828  4:33:48 [Note] mysqld (mysqld 5.5.52-0ubuntu0.14.04.1) starting as process 18825 ...

mysqld 返回

170828  4:34:17 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
170828  4:34:17 [Note] mysqld (mysqld 5.5.52-0ubuntu0.14.04.1) starting as process 18866 ...
170828  4:34:17 [Warning] Can't create test file /var/lib/mysql/chengtie.lower-test
170828  4:34:17 [Warning] Can't create test file /var/lib/mysql/chengtie.lower-test
mysqld: Can't change dir to '/var/lib/mysql/' (Errcode: 13)
170828  4:34:17 [ERROR] Aborting

170828  4:34:17 [Note] mysqld: Shutdown complete

有谁知道mysql出了什么问题吗?我怎样才能重新启动它?

编辑 1: 我注意到 config.inc.phpconfig.sample.inc.php 下没有 /var/lib/mysql/phpmyadmin

最佳答案

您看过这篇文章吗:Ubuntu - 12.04 - MySql won't start by using service mysql start

您可以尝试

mysqld --verbose
获取更多信息

关于mysql - 无法重新启动mysql,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45914888/

相关文章:

python - 可以使用 Python 3.4 版从 IDLE3 访问 MySQLdb 吗?

php - 如果 MySQL 行包含数组中的变量,请更新它?

wordpress - Vagrant Up 失败,因为该名称已存在

javascript - Contact Form 7 在发送电子邮件后不重定向

node.js - Node 版本管理器不会更改 Ubuntu 中的 Node 版本。卡在系统 Node 版本上。如何使用 nvm 更改 Node 版本?

mysql - 在 mysql 5.5 performance_schema 表中跟踪索引页读取吗?

php - 在 Windows 中为 MySQL 配置 ODBC

css - 除非我编辑 cache/combined.css,否则 Wordpress css 不会改变

php - 我在 php.ini 中禁用了 PHP 错误报告,但它继续在浏览器中显示

linux - 为什么我无法在 NASM Assembly 中打印我的数字常量?