2015-06-05 45 views
0

MySQL数据库每十天崩溃/下降。我一直在阅读下面的错误日志文件,它说:数据库没有正常关闭! (但我不知道为什么)需要帮助才能了解mysql错误日志

它使一些表崩溃......我怎么知道为什么?

我们的网站是AWS EC2实例下的一个WordPress项目,包含ubuntu,apache server和mysql。

150604 14:38:32 mysqld_safe Number of processes running now: 0 
    150604 14:38:32 mysqld_safe mysqld restarted 
    150604 14:38:32 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead. 
    150604 14:38:32 [Note] /usr/sbin/mysqld (mysqld 5.5.43-0ubuntu0.14.04.1) starting as process 5163 ... 
    150604 14:38:32 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead. 
    150604 14:38:32 [Note] Plugin 'FEDERATED' is disabled. 
    150604 14:38:32 InnoDB: The InnoDB memory heap is disabled 
    150604 14:38:32 InnoDB: Mutexes and rw_locks use GCC atomic builtins 
    150604 14:38:32 InnoDB: Compressed tables use zlib 1.2.8 
    150604 14:38:32 InnoDB: Using Linux native AIO 
    150604 14:38:32 InnoDB: Initializing buffer pool, size = 128.0M 
    150604 14:38:32 InnoDB: Completed initialization of buffer pool 
    150604 14:38:32 InnoDB: highest supported file format is Barracuda. 
    InnoDB: Log scan progressed past the checkpoint lsn 2022756426 
    150604 14:38:32 InnoDB: Database was not shut down normally! 
    InnoDB: Starting crash recovery. 
    InnoDB: Reading tablespace information from the .ibd files... 
    InnoDB: Restoring possible half-written data pages from the doublewrite 
    InnoDB: buffer... 
    InnoDB: Doing recovery: scanned up to log sequence number 2022758706 
    150604 14:38:32 InnoDB: Starting an apply batch of log records to the database... 
    InnoDB: Progress in percents: 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 
    InnoDB: Apply batch completed 
    150604 14:38:33 InnoDB: Waiting for the background threads to start 
    150604 14:38:34 InnoDB: 5.5.43 started; log sequence number 2022758706 
    150604 14:38:34 [Note] Server hostname (bind-address): '127.0.0.1'; port: 3306 
    150604 14:38:34 [Note] - '127.0.0.1' resolves to '127.0.0.1'; 
    150604 14:38:34 [Note] Server socket created on IP: '127.0.0.1'. 
    150604 14:38:34 [Note] Event Scheduler: Loaded 0 events 
    150604 14:38:34 [Note] /usr/sbin/mysqld: ready for connections. 
    Version: '5.5.43-0ubuntu0.14.04.1' socket: '/var/run/mysqld/mysqld.sock' port: 3306 (Ubuntu) 
    150604 14:38:34 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_blogs' is marked as crashed and should be repaired 
    150604 14:38:34 [Warning] Checking table: './prod_gremyo/wp_blogs' 
    150604 14:38:34 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_sitemeta' is marked as crashed and should be repaired 
    150604 14:38:34 [Warning] Checking table: './prod_gremyo/wp_sitemeta' 
    150604 14:38:52 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_options' is marked as crashed and should be repaired 
    150604 14:38:52 [Warning] Checking table: './prod_gremyo/wp_options' 
    Killed 
    150604 14:38:58 mysqld_safe Number of processes running now: 0 
    150604 14:38:58 mysqld_safe mysqld restarted 
    150604 14:38:58 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead. 
    150604 14:38:58 [Note] /usr/sbin/mysqld (mysqld 5.5.43-0ubuntu0.14.04.1) starting as process 5346 ... 
    150604 14:38:59 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead. 
    150604 14:38:59 [Note] Plugin 'FEDERATED' is disabled. 
    150604 14:38:59 InnoDB: The InnoDB memory heap is disabled 
    150604 14:38:59 InnoDB: Mutexes and rw_locks use GCC atomic builtins 
    150604 14:38:59 InnoDB: Compressed tables use zlib 1.2.8 
    150604 14:38:59 InnoDB: Using Linux native AIO 
    150604 14:38:59 InnoDB: Initializing buffer pool, size = 128.0M 
    InnoDB: mmap(137363456 bytes) failed; errno 12 
    150604 14:38:59 InnoDB: Completed initialization of buffer pool 
    150604 14:38:59 InnoDB: Fatal error: cannot allocate memory for the buffer pool 
    150604 14:38:59 [ERROR] Plugin 'InnoDB' init function returned error. 
    150604 14:38:59 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed. 
    150604 14:38:59 [ERROR] Unknown/unsupported storage engine: InnoDB 
    150604 14:38:59 [ERROR] Aborting 

    150604 14:38:59 [Note] /usr/sbin/mysqld: Shutdown complete 

    150604 14:38:59 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended 
    150604 15:01:26 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql 
    150604 15:01:26 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead. 
    150604 15:01:26 [Note] /usr/sbin/mysqld (mysqld 5.5.43-0ubuntu0.14.04.1) starting as process 6338 ... 
    150604 15:01:26 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead. 
    150604 15:01:26 [Note] Plugin 'FEDERATED' is disabled. 
    150604 15:01:26 InnoDB: The InnoDB memory heap is disabled 
    150604 15:01:26 InnoDB: Mutexes and rw_locks use GCC atomic builtins 
    150604 15:01:26 InnoDB: Compressed tables use zlib 1.2.8 
    150604 15:01:26 InnoDB: Using Linux native AIO 
    150604 15:01:26 InnoDB: Initializing buffer pool, size = 128.0M 
    150604 15:01:26 InnoDB: Completed initialization of buffer pool 
    150604 15:01:26 InnoDB: highest supported file format is Barracuda. 
    InnoDB: Log scan progressed past the checkpoint lsn 2022758706 
    150604 15:01:26 InnoDB: Database was not shut down normally! 
    InnoDB: Starting crash recovery. 
    InnoDB: Reading tablespace information from the .ibd files... 
    InnoDB: Restoring possible half-written data pages from the doublewrite 
    InnoDB: buffer... 
    InnoDB: Doing recovery: scanned up to log sequence number 2022759772 
    150604 15:01:26 InnoDB: Starting an apply batch of log records to the database... 
    InnoDB: Progress in percents: 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 
    InnoDB: Apply batch completed 
    150604 15:01:26 InnoDB: Waiting for the background threads to start 
    150604 15:01:27 InnoDB: 5.5.43 started; log sequence number 2022759772 
    150604 15:01:27 [Note] Server hostname (bind-address): '127.0.0.1'; port: 3306 
    150604 15:01:27 [Note] - '127.0.0.1' resolves to '127.0.0.1'; 
    150604 15:01:27 [Note] Server socket created on IP: '127.0.0.1'. 
    150604 15:01:27 [Note] Event Scheduler: Loaded 0 events 
    150604 15:01:27 [Note] /usr/sbin/mysqld: ready for connections. 
    Version: '5.5.43-0ubuntu0.14.04.1' socket: '/var/run/mysqld/mysqld.sock' port: 3306 (Ubuntu) 
    150604 15:01:29 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp__3wp_broadcast_broadcastdata' is marked as crashed and should be repaired 
    150604 15:01:29 [Warning] Checking table: './prod_gremyo/wp__3wp_broadcast_broadcastdata' 
    150604 15:01:29 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_blog_versions' is marked as crashed and should be repaired 
    150604 15:01:29 [Warning] Checking table: './prod_gremyo/wp_blog_versions' 
    150604 15:01:29 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_commentmeta' is marked as crashed and should be repaired 
    150604 15:01:29 [Warning] Checking table: './prod_gremyo/wp_commentmeta' 
    150604 15:01:29 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_comments' is marked as crashed and should be repaired 
    150604 15:01:29 [Warning] Checking table: './prod_gremyo/wp_comments' 
    150604 15:01:29 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_options' is marked as crashed and should be repaired 
    150604 15:01:29 [Warning] Checking table: './prod_gremyo/wp_options' 
    150604 15:01:30 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_postmeta' is marked as crashed and should be repaired 
    150604 15:01:30 [Warning] Checking table: './prod_gremyo/wp_postmeta' 
    150604 15:01:30 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_posts' is marked as crashed and should be repaired 
    150604 15:01:30 [Warning] Checking table: './prod_gremyo/wp_posts' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_registration_log' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_registration_log' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_term_relationships' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_term_relationships' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_term_taxonomy' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_term_taxonomy' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_terms' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_terms' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_usermeta' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_usermeta' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_users' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_users' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_woocommerce_downloadable_product_permissions' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_woocommerce_downloadable_product_permissions' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_woocommerce_order_itemmeta' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_woocommerce_order_itemmeta' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_woocommerce_order_items' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_woocommerce_order_items' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_woocommerce_termmeta' is marked as crashed and should be repaired 
    150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_woocommerce_termmeta' 
    150604 15:01:31 [ERROR] /usr/sbin/mysqld: Table './prod_gremyo/wp_wslusersprofi 

les' is marked as crashed and should be repaired 
150604 15:01:31 [Warning] Checking table: './prod_gremyo/wp_wslusersprofiles' 
+0

堆栈溢出是与编程相关的问题,那些可以用代码解决的问题。您是否阅读了错误消息中说**“致命错误:无法为缓冲池分配内存”的部分**? – tadman

+0

所以这似乎是一个内存问题? – miganml

+0

如果有人知道一个更好的社区,我可以发布这个,我会感谢他/她的信息;) – miganml

回答

0

试图解决的首创警告和“InnoDB的内存堆已禁用”,然后看他们的表现。