VPS侦探论坛

 找回密码
 注册
搜索
热搜: pathinfo
查看: 177|回复: 1

Mysql无法启动 The server quit without updating PID file (/www/mysql/mysql.pid)

[复制链接]
发表于 2019-3-25 13:56:19 | 显示全部楼层 |阅读模式

最开始数据放在默认地址的,后来系统盘满了迁移数据存放地址后就无法启动了,

  1. 2019-03-25T05:08:48.584664Z 0 [Note] --secure-file-priv is set to NULL. Operations related to importing and exporting data are disabled
  2. 2019-03-25T05:08:48.584856Z 0 [Note] /usr/local/mysql/bin/mysqld (mysqld 5.7.22-log) starting as process 10644 ...
  3. 2019-03-25T05:08:48.600521Z 0 [Note] InnoDB: PUNCH HOLE support available
  4. 2019-03-25T05:08:48.600582Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
  5. 2019-03-25T05:08:48.600592Z 0 [Note] InnoDB: Uses event mutexes
  6. 2019-03-25T05:08:48.600598Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
  7. 2019-03-25T05:08:48.600603Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
  8. 2019-03-25T05:08:48.600613Z 0 [Note] InnoDB: Using Linux native AIO
  9. 2019-03-25T05:08:48.601366Z 0 [Note] InnoDB: Number of pools: 1
  10. 2019-03-25T05:08:48.601570Z 0 [Note] InnoDB: Using CPU crc32 instructions
  11. 2019-03-25T05:08:48.604278Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
  12. 2019-03-25T05:08:48.616778Z 0 [Note] InnoDB: Completed initialization of buffer pool
  13. 2019-03-25T05:08:48.620495Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
  14. 2019-03-25T05:08:48.632837Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
  15. 2019-03-25T05:08:48.641244Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
  16. 2019-03-25T05:08:48.641297Z 0 [Note] InnoDB: Setting file '/www/mysql/data/ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
  17. 2019-03-25T05:08:48.696527Z 0 [Note] InnoDB: File '/www/mysql/data/ibtmp1' size is now 12 MB.
  18. 2019-03-25T05:08:48.697545Z 0 [Note] InnoDB: 1 redo rollback segment(s) found. 1 redo rollback segment(s) are active.
  19. 2019-03-25T05:08:48.697561Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
  20. 2019-03-25T05:08:48.698112Z 0 [Note] InnoDB: Waiting for purge to start
  21. 2019-03-25T05:08:48.748269Z 0 [Note] InnoDB: 5.7.22 started; log sequence number 61931
  22. 2019-03-25T05:08:48.748286Z 0 [Note] InnoDB: !!! innodb_force_recovery is set to 1 !!!
  23. 2019-03-25T05:08:48.748488Z 0 [Note] InnoDB: Loading buffer pool(s) from /www/mysql/data/ib_buffer_pool
  24. 2019-03-25T05:08:48.748787Z 0 [Note] InnoDB: Buffer pool(s) load completed at 190325 13:08:48
  25. 2019-03-25T05:08:48.748798Z 0 [Note] Plugin 'FEDERATED' is disabled.
  26. 2019-03-25T05:08:48.752117Z 0 [Warning] InnoDB: Cannot open table mysql/plugin from the internal data dictionary of InnoDB though the .frm file for the table exists. Please refer to http://dev.mysql.com/doc/refman/5.7/en/innodb-troubleshooting.html for how to resolve the issue.
  27. mysqld: Table 'mysql.plugin' doesn't exist
  28. 2019-03-25T05:08:48.752175Z 0 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
  29. 2019-03-25T05:08:48.775629Z 0 [Warning] World-writable config file './auto.cnf' is ignored.
  30. 2019-03-25T05:08:48.775658Z 0 [Warning] World-writable config file './auto.cnf' has been removed.

  31. 2019-03-25T05:08:48.775693Z 0 [Note] Salting uuid generator variables, current_pid: 10644, server_start_time: 1553490528, bytes_sent: 0,
  32. 2019-03-25T05:08:48.775768Z 0 [Note] Generated uuid: '12cd0f60-4ebc-11e9-a366-00163e02633c', server_start_time: 2996019653661723636, bytes_sent: 67479984
  33. 2019-03-25T05:08:48.775782Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: 12cd0f60-4ebc-11e9-a366-00163e02633c.
  34. 2019-03-25T05:08:48.781529Z 0 [Warning] InnoDB: Cannot open table mysql/gtid_executed from the internal data dictionary of InnoDB though the .frm file for the table exists. Please refer to http://dev.mysql.com/doc/refman/5.7/en/innodb-troubleshooting.html for how to resolve the issue.
  35. mysqld: Table 'mysql.gtid_executed' doesn't exist
  36. 2019-03-25T05:08:48.781556Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
  37. 2019-03-25T05:08:48.783220Z 0 [Warning] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
  38. 2019-03-25T05:08:48.783238Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
  39. 2019-03-25T05:08:48.783287Z 0 [Note] IPv6 is available.
  40. 2019-03-25T05:08:48.783304Z 0 [Note]   - '::' resolves to '::';
  41. 2019-03-25T05:08:48.783328Z 0 [Note] Server socket created on IP: '::'.
  42. 2019-03-25T05:08:48.783385Z 0 [ERROR] Unix socket lock file is empty /tmp/mysql.sock.lock.
  43. 2019-03-25T05:08:48.783390Z 0 [ERROR] Unable to setup unix socket lock file.
  44. 2019-03-25T05:08:48.783395Z 0 [ERROR] Aborting


  45. ========/etc/my.cnf=============
  46. [client]
  47. #password   = your_password
  48. port        = 3306
  49. socket      = /tmp/mysql.sock

  50. [mysqld]
  51. port        = 3306
  52. socket      = /tmp/mysql.sock
  53. datadir = /www/mysql/data
  54. log-error = /www/mysql/error.log
  55. pid-file = /www/mysql/mysql.pid
  56. skip-external-locking
  57. key_buffer_size = 32M
  58. max_allowed_packet = 1M
  59. table_open_cache = 128
  60. sort_buffer_size = 768K
  61. net_buffer_length = 8K
  62. read_buffer_size = 768K
  63. read_rnd_buffer_size = 512K
  64. myisam_sort_buffer_size = 8M
  65. thread_cache_size = 16
  66. query_cache_size = 16M
  67. tmp_table_size = 32M
  68. performance_schema_max_table_instances = 1000
  69. innodb_force_recovery = 1
  70. #skip-grant-tables

  71. explicit_defaults_for_timestamp = true
  72. #skip-networking
  73. max_connections = 500
  74. max_connect_errors = 100
  75. open_files_limit = 65535

  76. log-bin=mysql-bin
  77. binlog_format=mixed
  78. server-id   = 1
  79. expire_logs_days = 10
  80. early-plugin-load = ""

  81. default_storage_engine = InnoDB
  82. innodb_file_per_table = 1
  83. innodb_data_home_dir = /www/mysql/data
  84. innodb_data_file_path = ibdata1:10M:autoextend
  85. innodb_log_group_home_dir = /www/mysql/data
  86. innodb_buffer_pool_size = 128M
  87. innodb_log_file_size = 32M
  88. innodb_log_buffer_size = 8M
  89. innodb_flush_log_at_trx_commit = 1
  90. innodb_lock_wait_timeout = 50

  91. [mysqldump]
  92. quick
  93. max_allowed_packet = 16M

  94. [mysql]
  95. no-auto-rehash

  96. [myisamchk]
  97. key_buffer_size = 32M
  98. sort_buffer_size = 768K
  99. read_buffer = 2M
  100. write_buffer = 2M

  101. [mysqlhotcopy]
  102. interactive-timeout
复制代码
美国VPS推荐: 遨游主机LinodeLOCVPSKVMLAVPS2EZ搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2019-3-25 16:41:36 | 显示全部楼层

回复 1# 的帖子


不清楚你具体怎么迁移的过程,看日志有可能数据库文件缺失
官网和论坛常见问题里有具体迁移mysql的步骤
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org/
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|VPS侦探 ( 鲁ICP备16040043号-1 )

GMT+8, 2019-4-25 11:04 , Processed in 0.046469 second(s), 26 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表