After MySQL manually deleted partons from the database, the main database was not modified. Later, problems occurred after deleting partons from the main database
Fault site
Last_Errno: 1507
Last_Error: Error 'Error in list of partitions to DROP' on query. Default database: ''. Query: 'ALTER TABLE DROP PARTITION part_20170209'
Solution:
Check the partition to be deleted according to the error reported from the database to the corresponding location. It is found that there is no partition. The problem is clear here. The rest is simple repair operations
mysql> stop slave ; Query OK, 0 rows affected (0.00 sec) mysql> set global sql_slave_skip_counter=1; Query OK, 0 rows affected (0.00 sec) mysql> start slave; Query OK, 0 rows affected (0.01 sec)
Repeat until the problem is fixed. If there are many same errors, you can also write a script to continuously monitor the MySQL slave status. If the same errors are matched, you can skip. Let’s take a look at the situation after repair
Seconds_Behind_Master: 1265 Master_SSL_Verify_Server_Cert: No Last_IO_Errno: 0 Last_IO_Error: Last_SQL_Errno: 0 Last_SQL_Error:
I felt it was ok, there was a little delay, but I found it in time
Summary:
1. In case of such a problem, first of all, it is certain that the drop partition operation cannot be performed manually with a large permission account, resulting in no error found in the partition when the master database is executed
To control such problems, we can start with permissions and strictly control user permissions. Non DBA personnel are not allowed to have operation permissions directly (our permissions are very strict)
Similar Posts:
- ERROR 3021 (HY000): This operation cannot be performed with a running slave io thread; run STOP SLAVE IO_THREAD FOR CHANNEL ” first.
- [Solved] Last_IO_Error: error connecting to master ‘[email protected]:3306’ – retry-time: 60 …
- How to Solve MYSQL ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository
- How to Solve MySQL Errno:1782 Error
- mysql Slave_IO_Running:NO [How to Solve]
- [Solved] MYSQL ERROR 1044 (42000): Access denied for user ”@’localhost’ to database ‘mysql’
- MySQL 5.7 error reporting from database 1032 [How to Solve]
- [Solved] Mysql Got fatal error 1236 from master when reading data from binary log: ‘Could not find first log file name in binary log index file’
- [Solved] Error reading packet from server: Lost connection to MySQL server during query ( server_errno=20131)
- ERROR 1820 (HY000): Unknown error 1820 [How to Solve]