• sql bị tắt và không bật lên được

  • Thông báo lỗi bạn gặp và mọi người giúp fix.

Thông báo lỗi bạn gặp và mọi người giúp fix.
 #3041  by xoideo
 02 Nov 2018 15:13
Chào anh,
hiện tại con VPS của em đang bị tắt mysql và em ko làm thế nào mà bật nó lên dc ạ.
Nãy sử dụng chức năng restart service mà nó ra vậy luôn @@
Code: Select all
[root@localhost ~]# service sql start
sql: unrecognized service
[root@localhost ~]# service mysql start
Starting MySQL.181102 15:19:30 mysqld_safe Logging to '/home/vpssim.demo/logs/mysql.log'.
181102 15:19:30 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
.. ERROR!
[root@localhost ~]# service mysql stop
 ERROR! MySQL server PID file could not be found!
[root@localhost ~]# service mysql restart
 ERROR! MySQL server PID file could not be found!
Starting MySQL.181102 15:19:46 mysqld_safe Logging to '/home/vpssim.demo/logs/mysql.log'.
181102 15:19:46 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
.. ERROR!
 ERROR! Failed to restart server.
Get 25 USD Free To USE VPSSIM
 #3044  by nguyenoanh
 02 Nov 2018 16:07
Code: Select all
nnoDB: Using innodb_file_format is deprecated and the parameter may be removed in future releases.
Em comment (thêm # vào đầu dòng) dòng bắt đầu bằng:
Code: Select all
innodb_file_format
trong /etc/my.cnf

sau đó bật MySQL lên là được.
 #3046  by xoideo
 02 Nov 2018 18:28
Code: Select all
[client]
socket=/var/lib/mysql/mysql.sock

[mysql]
max_allowed_packet = 32M

[mysqld]
local-infile=0
ignore-db-dir=lost+found
character-set-server=utf8
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock


#bind-address=127.0.0.1
# optimized my.cnf for MariaDB 5.5.x
# by eva2000
# vbtechsupport.com

tmpdir=/tmp

innodb=ON
#skip-federated
#skip-pbxt
#skip-pbxt_statistics
#skip-archive
#skip-name-resolve
#old_passwords
back_log = 75
max_connections = 250
key_buffer_size = 32M
của em không có như anh nói ạ ?
 #3050  by xoideo
 02 Nov 2018 19:00
nguyenoanh wrote:innodb_file_format
đã # nhưng vẫn vậy anh à
mà em thấy trong /var/lib/mysql/ ko có mysql.sock

còn cái này nữa anh
Code: Select all
[root@localhost mysql]# service mysql stop
 ERROR! MySQL server PID file could not be found!
Get 25 USD Free To USE VPSSIM