MySQL crashes with plenty of system resources [closed] - php

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I have a centos server running a couple of very low traffic WordPress websites. For some reason MySQL keeps crashing.
In the mysql log file, there is a line that states:
Fatal error: cannot allocate memory for the buffer pool
The server has 1.75gb of ram so unless something is configured horribly wrong, I am not quite sure how there wouldn't be enough ram. Is that a hint that the problem is a ram issue? Here is a section of my log file. I'm not quite sure what any of it means though.
Version: '5.5.37' socket: '/var/lib/mysql/mysql.sock' port: 3306 MySQL Community Server (GPL) by Remi
141218 06:52:12 mysqld_safe Number of processes running now: 0
141218 06:52:12 mysqld_safe mysqld restarted
141218 6:52:13 [Note] Plugin 'FEDERATED' is disabled.
141218 6:52:13 InnoDB: The InnoDB memory heap is disabled
141218 6:52:13 InnoDB: Mutexes and rw_locks use GCC atomic builtins
141218 6:52:13 InnoDB: Compressed tables use zlib 1.2.3
141218 6:52:13 InnoDB: Using Linux native AIO
141218 6:52:13 InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(137363456 bytes) failed; errno 12
141218 6:52:13 InnoDB: Completed initialization of buffer pool
141218 6:52:13 InnoDB: Fatal error: cannot allocate memory for the buffer pool
141218 6:52:13 [ERROR] Plugin 'InnoDB' init function returned error.
141218 6:52:13 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
141218 6:52:13 [ERROR] Unknown/unsupported storage engine: InnoDB
141218 6:52:13 [ERROR] Aborting
141218 6:52:13 [Note] /usr/libexec/mysqld: Shutdown complete
141218 06:52:13 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
141218 18:15:42 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
141218 18:15:42 [Note] Plugin 'FEDERATED' is disabled.
141218 18:15:42 InnoDB: The InnoDB memory heap is disabled
141218 18:15:42 InnoDB: Mutexes and rw_locks use GCC atomic builtins
141218 18:15:42 InnoDB: Compressed tables use zlib 1.2.3
141218 18:15:42 InnoDB: Using Linux native AIO
141218 18:15:42 InnoDB: Initializing buffer pool, size = 128.0M
141218 18:15:42 InnoDB: Completed initialization of buffer pool
141218 18:15:42 InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
141218 18:15:42 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...
141218 18:15:42 InnoDB: Waiting for the background threads to start
141218 18:15:43 InnoDB: 5.5.37 started; log sequence number 143507172
141218 18:15:43 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
141218 18:15:43 [Note] - '0.0.0.0' resolves to '0.0.0.0';
141218 18:15:43 [Note] Server socket created on IP: '0.0.0.0'.
141218 18:15:43 [ERROR] Missing system table mysql.proxies_priv; please run mysql_upgrade to create it
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_current' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_history' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_history_long' has the wrong structure
141218 06:52:12 mysqld_safe mysqld restarted
141218 6:52:13 [Note] Plugin 'FEDERATED' is disabled.
141218 6:52:13 InnoDB: The InnoDB memory heap is disabled
141218 6:52:13 InnoDB: Mutexes and rw_locks use GCC atomic builtins
141218 6:52:13 InnoDB: Compressed tables use zlib 1.2.3
141218 6:52:13 InnoDB: Using Linux native AIO
141218 6:52:13 InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(137363456 bytes) failed; errno 12
141218 6:52:13 InnoDB: Completed initialization of buffer pool
141218 6:52:13 InnoDB: Fatal error: cannot allocate memory for the buffer pool
141218 6:52:13 [ERROR] Plugin 'InnoDB' init function returned error.
141218 6:52:13 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
141218 6:52:13 [ERROR] Unknown/unsupported storage engine: InnoDB
141218 6:52:13 [ERROR] Aborting
141218 6:52:13 [Note] /usr/libexec/mysqld: Shutdown complete
141218 06:52:13 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
141218 18:15:42 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
141218 18:15:42 [Note] Plugin 'FEDERATED' is disabled.
141218 18:15:42 InnoDB: The InnoDB memory heap is disabled
141218 18:15:42 InnoDB: Mutexes and rw_locks use GCC atomic builtins
141218 18:15:42 InnoDB: Compressed tables use zlib 1.2.3
141218 18:15:42 InnoDB: Using Linux native AIO
141218 18:15:42 InnoDB: Initializing buffer pool, size = 128.0M
141218 18:15:42 InnoDB: Completed initialization of buffer pool
141218 18:15:42 InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
141218 18:15:42 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...
141218 18:15:42 InnoDB: Waiting for the background threads to start
141218 18:15:43 InnoDB: 5.5.37 started; log sequence number 143507172
141218 18:15:43 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
141218 18:15:43 [Note] - '0.0.0.0' resolves to '0.0.0.0';
141218 18:15:43 [Note] Server socket created on IP: '0.0.0.0'.
141218 18:15:43 [ERROR] Missing system table mysql.proxies_priv; please run mysql_upgrade to create it
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_current' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_history' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_history_long' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'setup_consumers' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'setup_instruments' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'setup_timers' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'performance_timers' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'threads' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_summary_by_thread_by_event_name' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_summary_by_instance' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'events_waits_summary_global_by_event_name' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'file_summary_by_event_name' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'file_summary_by_instance' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'mutex_instances' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'rwlock_instances' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'cond_instances' has the wrong structure
141218 18:15:43 [ERROR] Native table 'performance_schema'.'file_instances' has the wrong structure
141218 18:15:43 [Note] Event Scheduler: Loaded 0 events
141218 18:15:43 [Note] /usr/libexec/mysqld: ready for connections.
Here is my my.cnf file:
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
skip-host-cache
skip-name-resolve
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used (fedora >= 15).
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mysqld according to the
# instructions in http://fedoraproject.org/wiki/Systemd
user=mysql
# Semisynchronous Replication
# http://dev.mysql.com/doc/refman/5.5/en/replication-semisync.html
# uncomment next line on MASTER
;plugin-load=rpl_semi_sync_master=semisync_master.so
# uncomment next line on SLAVE
;plugin-load=rpl_semi_sync_slave=semisync_slave.so
# Others options for Semisynchronous Replication
;rpl_semi_sync_master_enabled=1
;rpl_semi_sync_master_timeout=10
;rpl_semi_sync_slave_enabled=1
# http://dev.mysql.com/doc/refman/5.5/en/performance-schema.html
;performance_schema
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

Related

MySQL Database on XAMPP 7.1.7 no longer working

my MySQL Database on XAMPP 7.1.7 is not running anymore. I tried numerous solutions proposed in this post MySQL Database won't start in XAMPP Manager-osx but with no luck so far. Here's what I’ve tried:
sudo /Applications/XAMPP/xamppfiles/bin/mysql.server start ->
Terminal simply states „ERROR!“
sudo killall mysqld -> Terminal states „No matching processes were found“
changing the MySQL port from 3306 to 3307 in the XAMPP Control Panel -> no change
killing all active mysql processes in Monitor Activity tool -> couldn’t find any active processes named „mysql“ or „sql“
Clearly I don’t know what the problem and it feels I’m just randomly trying out every solution I stumple upon.
So I am posting below my log files from xamppfiles/var/mysql/[mycomputername].home.err.
Maybe there's an indication in here of what the problem might be?
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Using mutexes to ref count buffer pool pages
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: The InnoDB memory heap is disabled
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: GCC builtin __sync_synchronize() is used for memory barrier
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Compressed tables use zlib 1.2.8
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Using SSE crc32 instructions
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Initializing buffer pool, size = 16.0M
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Completed initialization of buffer pool
2018-04-02 20:05:21 140735637578560 [Note] InnoDB: Restoring page 0 of tablespace 0
2018-04-02 20:05:21 140735637578560 [Warning] InnoDB: Doublewrite does not have page_no=0 of space: 0
2018-04-02 20:05:21 140735637578560 [ERROR] InnoDB: space header page consists of zero bytes in data file /Applications/XAMPP/xamppfiles/var/mysql/ibdata1
2018-04-02 20:05:21 140735637578560 [ERROR] InnoDB: Could not open or create the system tablespace. If you tried to add new data files to the system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the new ibdata files InnoDB created in this failed attempt. InnoDB only wrote those files full of zeros, but did not yet use them in any way. But be careful: do not remove old data files which contain your precious data!
2018-04-02 20:05:21 140735637578560 [ERROR] Plugin 'InnoDB' init function returned error.
2018-04-02 20:05:21 140735637578560 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2018-04-02 20:05:21 140735637578560 [Note] Plugin 'FEEDBACK' is disabled.
2018-04-02 20:05:21 140735637578560 [ERROR] Unknown/unsupported storage engine: InnoDB
2018-04-02 20:05:21 140735637578560 [ERROR] Aborting
2018-04-02 20:05:21 29871 mysqld_safe mysqld from pid file /Applications/XAMPP/xamppfiles/var/mysql/josephs-imac.home.pid ended
Any help would be highly appreciated :-)

Mysql Down On Amazon EC2 Error Connecting To Database

Our database shutdown last night and i cannot figure out why i just did a service restart to get everything backup, we are running a c4.large so quite a big box outputting the mysql error log is below.
160526 23:27:31 [Note] Plugin 'FEDERATED' is disabled.
160526 23:27:31 InnoDB: The InnoDB memory heap is disabled
160526 23:27:31 InnoDB: Mutexes and rw_locks use GCC atomic builtins
160526 23:27:31 InnoDB: Compressed tables use zlib 1.2.8
160526 23:27:31 InnoDB: Using Linux native AIO
160526 23:27:31 InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(137363456 bytes) failed; errno 12
160526 23:27:31 InnoDB: Completed initialization of buffer pool
160526 23:27:31 InnoDB: Fatal error: cannot allocate memory for the buffer pool
160526 23:27:31 [ERROR] Plugin 'InnoDB' init function returned error.
160526 23:27:31 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
160526 23:27:31 [ERROR] Unknown/unsupported storage engine: InnoDB
160526 23:27:31 [ERROR] Aborting
160526 23:27:31 [Note] /usr/libexec/mysql55/mysqld: Shutdown complete
Can someone help me with this error i see the fatal error cannot allocate memory for buffer pool but not sure what this means or how to fix?
Also what may have caused this?
Thanks
After googling a bit i have added
innodb_buffer_pool_size = 20M
to my.cnf is this a solid fix?

MySQL server shuts itself down after startup

I tried shutting down XAMPP and deleting the ibdata1 already. Yesterday the server did still work, but when starting up today it didn't start anymore. I'm using the server for a PHP project using PHPMyAdmin.
This is the error log from XAMPP:
2016-05-26 09:07:29 15a0 InnoDB: Warning: Using innodb_additional_mem_pool_size is DEPRECATED.
This option may be removed in future releases, together with the option innodb_use_sys_malloc and with the InnoDB's internal memory allocator.
160526 9:07:29 [Note] InnoDB: Using mutexes to ref count buffer pool pages
160526 9:07:29 [Note] InnoDB: The InnoDB memory heap is disabled
160526 9:07:29 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
160526 9:07:29 [Note] InnoDB: Memory barrier is not used
160526 9:07:29 [Note] InnoDB: Compressed tables use zlib 1.2.3
160526 9:07:29 [Note] InnoDB: Not using CPU crc32 instructions
160526 9:07:29 [Note] InnoDB: Initializing buffer pool, size = 16.0M
160526 9:07:29 [Note] InnoDB: Completed initialization of buffer pool
160526 9:07:29 [Note] InnoDB: Restoring page 0 of tablespace 0
160526 9:07:29 [Warning] InnoDB: Doublewrite does not have page_no=0 of space: 0
160526 9:07:29 [ERROR] InnoDB: space header page consists of zero bytes in data file C:\xampp\mysql\data\ibdata1
160526 9:07:29 [ERROR] InnoDB: Could not open or create the system tablespace.
If you tried to add new data files to the system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the new ibdata files InnoDB created in this failed attempt.
InnoDB only wrote those files full of zeros, but did not yet use them in any way.
But be careful: do not remove old data files which contain your precious data!
160526 9:07:29 [ERROR] Plugin 'InnoDB' init function returned error.
160526 9:07:29 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
160526 9:07:29 [Note] Plugin 'FEEDBACK' is disabled.
160526 9:07:29 [ERROR] Unknown/unsupported storage engine: InnoDB
160526 9:07:29 [ERROR] Aborting
160526 9:07:29 [Note] c:\xampp\mysql\bin\mysqld.exe: Shutdown complete`

XAMPP MySQL shuts down unexpectedly

XAMPP MySQL shuts down unexpectedly. I was trying to enable the configuration storage settings earlier, turned my PC off, and returned to this. I have uninstalled and reinstalled XAMPP within the past couple of days, changed port numbers to apache and setup a password.
I've deleted the ibdata1, ib_logfile0, and the ib_logfile1 files, and changes the port numbers to the my.ini and php.ini files.
Help would be appreciated.
2015-11-10 17:40:54 418 InnoDB: Warning: Using innodb_additional_mem_pool_size is DEPRECATED. This option may be removed in future releases, together with the option innodb_use_sys_malloc and with the InnoDB's internal memory allocator.
151110 17:40:54 [Note] InnoDB: Using mutexes to ref count buffer pool pages
151110 17:40:54 [Note] InnoDB: The InnoDB memory heap is disabled
151110 17:40:54 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
151110 17:40:54 [Note] InnoDB: Memory barrier is not used
151110 17:40:54 [Note] InnoDB: Compressed tables use zlib 1.2.3
151110 17:40:54 [Note] InnoDB: Not using CPU crc32 instructions
151110 17:40:54 [Note] InnoDB: Initializing buffer pool, size = 16.0M
151110 17:40:54 [Note] InnoDB: Completed initialization of buffer pool
151110 17:40:54 [Note] InnoDB: Restoring page 0 of tablespace 0
151110 17:40:54 [Warning] InnoDB: Doublewrite does not have page_no=0 of space: 0
151110 17:40:54 [ERROR] InnoDB: space header page consists of zero bytes in data file C:\xampp\mysql\data\ibdata1
151110 17:40:54 [ERROR] InnoDB: Could not open or create the system tablespace. If you tried to add new data files to the system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the new ibdata files InnoDB created in this failed attempt. InnoDB only wrote those files full of zeros, but did not yet use them in any way. But be careful: do not remove old data files which contain your precious data!
151110 17:40:54 [ERROR] Plugin 'InnoDB' init function returned error.
151110 17:40:54 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
151110 17:40:54 [Note] Plugin 'FEEDBACK' is disabled.
151110 17:40:54 [ERROR] Unknown/unsupported storage engine: InnoDB
151110 17:40:54 [ERROR] Aborting
151110 17:40:54 [Note] c:\xampp\mysql\bin\mysqld.exe: Shutdown complete

WAMP: Plugin 'FEDERATED' is disabled. #2002 mysql error

I am running 2 locally hosted wp sites for testing on my Win 7 pc. Unfortunately windows update did a update install and reboot last night while wamp was online.
Usually I can fix this myself, but I am having no luck. After about 6 hours of search for a resolution I turn to you wonderful people.
PROBLEM: Orange Icon.
PhpMyAdmin error #2002
Here is my error log:
2014-02-25 13:12:44 4420 [Note] Plugin 'FEDERATED' is disabled
2014-02-25 13:12:44 4420 [Note] InnoDB: The InnoDB memory heap is disabled
2014-02-25 13:12:44 4420 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2014-02-25 13:12:44 4420 [Note] InnoDB: Compressed tables use zlib 1.2.3
2014-02-25 13:12:44 4420 [Note] InnoDB: Not using CPU crc32 instructions
2014-02-25 13:12:44 4420 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2014-02-25 13:12:44 4420 [Note] InnoDB: Completed initialization of buffer pool
2014-02-25 13:12:44 4420 [Note] InnoDB: Highest supported file format is Barracuda.
2014-02-25 13:12:44 4420 [Note] InnoDB: The log sequence numbers 12054850 and 12054850 in ibdata files do not match the log sequence number 12746597 in the ib_logfiles!
2014-02-25 13:12:44 4420 [Note] InnoDB: Database was not shutdown normally!
2014-02-25 13:12:44 4420 [Note] InnoDB: Starting crash recovery.
2014-02-25 13:12:44 4420 [Note] InnoDB: Reading tablespace information from the .ibd files...
2014-02-25 13:12:44 4420 [ERROR] InnoDB: Attempted to open a previously opened tablespace. Previous tablespace dlkei4n83xuf/rvcommentmeta uses space ID: 11 at filepath: .\dlkei4n83xuf\rvcommentmeta.ibd. Cannot open tablespace test/rvscommentmeta which uses space ID: 11 at filepath: .\test\rvscommentmeta.ibd
InnoDB: Error: could not open single-table tablespace file .\test\rvscommentmeta.ibd
InnoDB: We do not continue the crash recovery, because the table may become
InnoDB: corrupt if we cannot apply the log records in the InnoDB log to it.
InnoDB: To fix the problem and start mysqld:
InnoDB: 1) If there is a permission problem in the file and mysqld cannot
InnoDB: open the file, you should modify the permissions.
InnoDB: 2) If the table is not needed, or you can restore it from a backup,
InnoDB: then you can remove the .ibd file, and InnoDB will do a normal
InnoDB: crash recovery and ignore that table.
InnoDB: 3) If the file system or the disk is broken, and you cannot remove
InnoDB: the .ibd file, you can set innodb_force_recovery > 0 in my.cnf
InnoDB: and force InnoDB to continue crash recovery here.

Categories