Max1303
@Max1303
Программист

Откуда столько процессов MySQL?

На хостинге CentOS 8, MySQL, 1С-Битрикс. На сервере стали появляться процессы:
usr/sbin/mysqld --daemonize --pid-file=/var/run/mysqld/mysqld.pid
Сначала один, потом два и до сотен. Загружают процессоры на 100%.
Выполняю на сервере KILL какого либо процесса, удаляются сразу все. Сайт перестаёт работать, выдаёт ошибку подключения к базе. MySQL сам не запускает процесс, приходится выполнять команду service mysqld restart.
После сайт начинает работать. но через мин 20 процессы снова множатся и занимают процессоры почти на 100%. В логе ниже кусок из файла. Сразу после перезагрузки MySQL и до новой перезагрузки.

Лог (var/log/mysql/error.log):
2020-05-23T14:25:19.098847Z 0 [Note] /usr/sbin/mysqld: Shutdown complete

2020-05-23T14:25:39.120898Z 0 [Warning] Changed limits: max_open_files: 5000 (requested 8703)
2020-05-23T14:25:39.121236Z 0 [Warning] Changed limits: table_open_cache: 2245 (requested 4096)
2020-05-23T14:25:39.238234Z 0 [Warning] 'NO_AUTO_CREATE_USER' sql mode was not set.
2020-05-23T14:25:39.238381Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.29-32-log) starting as process 230704 ...
2020-05-23T14:25:39.294598Z 0 [Note] InnoDB: PUNCH HOLE support available
2020-05-23T14:25:39.294644Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2020-05-23T14:25:39.294647Z 0 [Note] InnoDB: Uses event mutexes
2020-05-23T14:25:39.294650Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2020-05-23T14:25:39.294653Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.7
2020-05-23T14:25:39.294656Z 0 [Note] InnoDB: Using Linux native AIO
2020-05-23T14:25:39.295035Z 0 [Note] InnoDB: Number of pools: 1
2020-05-23T14:25:39.295138Z 0 [Note] InnoDB: Using CPU crc32 instructions
2020-05-23T14:25:39.303760Z 0 [Note] InnoDB: Initializing buffer pool, total size = 9G, instances = 9, chunk size = 128M
2020-05-23T14:25:39.561860Z 0 [Note] InnoDB: Completed initialization of buffer pool
2020-05-23T14:25:39.624537Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2020-05-23T14:25:39.643057Z 0 [Note] InnoDB: Crash recovery did not find the parallel doublewrite buffer at /var/lib/mysql/xb_doublewrite
2020-05-23T14:25:39.645074Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2020-05-23T14:25:39.801553Z 0 [Note] InnoDB: Created parallel doublewrite buffer at /var/lib/mysql/xb_doublewrite, size 35389440 bytes
2020-05-23T14:25:40.043166Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2020-05-23T14:25:40.043313Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2020-05-23T14:25:40.075397Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2020-05-23T14:25:40.077189Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2020-05-23T14:25:40.077215Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2020-05-23T14:25:40.078403Z 0 [Note] InnoDB: Waiting for purge to start
2020-05-23T14:25:40.129057Z 0 [Note] InnoDB: Percona XtraDB (http://www.percona.com) 5.7.29-32 started; log sequence number 103422489791
2020-05-23T14:25:40.129384Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2020-05-23T14:25:40.129829Z 0 [Note] Plugin 'FEDERATED' is disabled.
2020-05-23T14:25:40.185387Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them.
2020-05-23T14:25:40.185421Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory.
2020-05-23T14:25:40.186909Z 0 [Warning] CA certificate ca.pem is self signed.
2020-05-23T14:25:40.187010Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory.
2020-05-23T14:25:40.187204Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2020-05-23T14:25:40.187271Z 0 [Note] IPv6 is available.
2020-05-23T14:25:40.187292Z 0 [Note] - '::' resolves to '::';
2020-05-23T14:25:40.187302Z 0 [Note] Server socket created on IP: '::'.
2020-05-23T14:25:40.200247Z 0 [Note] Failed to start slave threads for channel ''
2020-05-23T14:25:40.209190Z 0 [Note] Event Scheduler: Loaded 0 events
2020-05-23T14:25:40.209467Z 0 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.7.29-32-log' socket: '/var/lib/mysqld/mysqld.sock' port: 3306 Percona Server (GPL), Release 32, Revision 56bce88
2020-05-23T14:25:48.817802Z 0 [Note] InnoDB: Buffer pool(s) load completed at 200523 17:25:48
2020-05-23T15:58:42.574580Z 3144 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2020-05-23T16:02:55.851978Z 0 [Note] Giving 360 client threads a chance to die gracefully
2020-05-23T16:02:55.858015Z 0 [Note] Shutting down slave threads
2020-05-23T16:02:57.858428Z 0 [Note] Forcefully disconnecting 0 remaining clients
2020-05-23T16:02:57.858494Z 0 [Note] Event Scheduler: Purging the queue. 0 events
2020-05-23T16:02:57.858730Z 0 [Note] Binlog end
2020-05-23T16:02:57.889190Z 0 [Note] Shutting down plugin 'ngram'
2020-05-23T16:02:57.889217Z 0 [Note] Shutting down plugin 'BLACKHOLE'
2020-05-23T16:02:57.889228Z 0 [Note] Shutting down plugin 'ARCHIVE'
2020-05-23T16:02:57.889233Z 0 [Note] Shutting down plugin 'partition'
2020-05-23T16:02:57.889237Z 0 [Note] Shutting down plugin 'MRG_MYISAM'
2020-05-23T16:02:57.889244Z 0 [Note] Shutting down plugin 'MyISAM'
2020-05-23T16:02:57.889257Z 0 [Note] Shutting down plugin 'CSV'
2020-05-23T16:02:57.889262Z 0 [Note] Shutting down plugin 'MEMORY'
2020-05-23T16:02:57.889266Z 0 [Note] Shutting down plugin 'INNODB_TABLESPACES_SCRUBBING'
2020-05-23T16:02:57.889271Z 0 [Note] Shutting down plugin 'INNODB_TABLESPACES_ENCRYPTION'
2020-05-23T16:02:57.889275Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL'
2020-05-23T16:02:57.889279Z 0 [Note] Shutting down plugin 'INNODB_CHANGED_PAGES'
2020-05-23T16:02:57.889283Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2020-05-23T16:02:57.889286Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2020-05-23T16:02:57.889290Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2020-05-23T16:02:57.889294Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2020-05-23T16:02:57.889298Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2020-05-23T16:02:57.889302Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2020-05-23T16:02:57.889306Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2020-05-23T16:02:57.889310Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2020-05-23T16:02:57.889325Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2020-05-23T16:02:57.889329Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2020-05-23T16:02:57.889333Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2020-05-23T16:02:57.889337Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2020-05-23T16:02:57.889341Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2020-05-23T16:02:57.889344Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2020-05-23T16:02:57.889348Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2020-05-23T16:02:57.889352Z 0 [Note] Shutting down plugin 'INNODB_METRICS'
2020-05-23T16:02:57.889356Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO'
2020-05-23T16:02:57.889359Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2020-05-23T16:02:57.889363Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2020-05-23T16:02:57.889367Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2020-05-23T16:02:57.889371Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2020-05-23T16:02:57.889375Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2020-05-23T16:02:57.889378Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2020-05-23T16:02:57.889382Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM'
2020-05-23T16:02:57.889386Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2020-05-23T16:02:57.889390Z 0 [Note] Shutting down plugin 'INNODB_CMP'
2020-05-23T16:02:57.889393Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2020-05-23T16:02:57.889397Z 0 [Note] Shutting down plugin 'INNODB_LOCKS'
2020-05-23T16:02:57.889402Z 0 [Note] Shutting down plugin 'INNODB_TRX'
2020-05-23T16:02:57.889405Z 0 [Note] Shutting down plugin 'XTRADB_ZIP_DICT_COLS'
2020-05-23T16:02:57.889409Z 0 [Note] Shutting down plugin 'XTRADB_ZIP_DICT'
2020-05-23T16:02:57.889413Z 0 [Note] Shutting down plugin 'XTRADB_RSEG'
2020-05-23T16:02:57.889417Z 0 [Note] Shutting down plugin 'XTRADB_INTERNAL_HASH_TABLES'
2020-05-23T16:02:57.889420Z 0 [Note] Shutting down plugin 'XTRADB_READ_VIEW'
2020-05-23T16:02:57.889424Z 0 [Note] Shutting down plugin 'InnoDB'
2020-05-23T16:02:58.168839Z 0 [Note] InnoDB: FTS optimize thread exiting.
2020-05-23T16:02:58.169131Z 0 [Note] InnoDB: Starting shutdown...
2020-05-23T16:02:58.270573Z 0 [Note] InnoDB: Dumping buffer pool(s) to /var/lib/mysql/ib_buffer_pool
2020-05-23T16:02:58.290300Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 200523 19:02:58
2020-05-23T16:02:59.071597Z 0 [Note] InnoDB: Waiting for page_cleaner to finish flushing of buffer pool
2020-05-23T16:03:01.023000Z 0 [Note] InnoDB: Shutdown completed; log sequence number 103524038347
2020-05-23T16:03:01.023244Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2020-05-23T16:03:01.023257Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2020-05-23T16:03:01.023290Z 0 [Note] Shutting down plugin 'sha256_password'
2020-05-23T16:03:01.023293Z 0 [Note] Shutting down plugin 'mysql_native_password'
2020-05-23T16:03:01.023496Z 0 [Note] Shutting down plugin 'binlog'
2020-05-23T16:03:01.039096Z 0 [Note] /usr/sbin/mysqld: Shutdown complete
  • Вопрос задан
  • 176 просмотров
Решения вопроса 1
@vitaly_il1
DevOps Consulting
Покажите список процессов

ps -ef | grep mysqld
Ответ написан
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы