ERROR! The server quit without updating PID file

5.9k views Asked by At

I´ve seen this question in another post, but I have one diference:

I´m triyng to follow the instructions in https://www.telepieza.com/wordpress/2008/03/13/replicar-bases-de-datos-mysql-en-servidores-locales-o-remotos/

But my in my server originally the line: #log-bin=mysql-bin is commented (#)

If I let the line without the # and restarts the MySql the service doesn´t start and shows the error:

ERROR! MySQL server PID file could not be found!
Starting MySQL.. ERROR! The server quit without updating PID file (/var/lib/mysql/xxxxxx.pid).

Thanks for your help

----------------- Added for the coments:

enter image description here 2017 Log

1

There are 1 answers

0
Bill Karwin On BEST ANSWER

In your error log, I see the error that it can't find the binary log file it expects to find. So some or all of your binary log files expired or got deleted or something. But there's still some reference to mysql-bin.000019 in mysql-bin.index.

I checked your screenshot you had posted previously and I see your mysql-bin.index is dated 2017-05-18. So it's three months out of date anyway. I would guess someone deleted the old binary logs to save space, but didn't think to delete the binlog index file.

If you want to start over with a clean slate of binary log files, just remove all your mysql-bin.* files (including mysql-bin.index), and then start mysqld. The startup will automatically create new binary logs, starting with mysql-bin.000001.

Note that if you have any replication slaves depending on this instance as their master, you'll have to reinitialize them with a new backup and the new binlog filename.