wordpress - My.cnf Optimization For Mysql Errors -


i getting mysql error nowadays.my vps @ digital ocean 5$ plan.1 cpu , 512 mb ram , centos 6.5 , apache , mysql , nginx, cpanel.just 2 wordpress sites in it.

here my.cnf

[mysqld]      port            = 3306      socket          = /var/lib/mysql/mysql.sock      default-storage-engine= myisam      max_connections = 150       key_buffer = 16k      max_allowed_packet = 1m      table_open_cache = 2000      sort_buffer_size = 64k      read_buffer_size = 256k      read_rnd_buffer_size = 256k      net_buffer_length = 2k      thread_stack = 64k      log-slow-queries= /var/lib/mysql/slow.log      log-error = /var/lib/mysql/error.log      thread_cache_size = 4       query_cache_type = 1      query_cache_size = 16m      query_cache_limit = 4m         # low memory, innodb should not used keep skip-innodb uncommented unless required      skip-innodb       # uncomment following if using innodb tables      #innodb_data_home_dir = /var/lib/mysql/      #innodb_data_file_path = ibdata1:10m:autoextend      #innodb_log_group_home_dir = /var/lib/mysql/      #innodb_log_arch_dir = /var/lib/mysql/      # can set .._buffer_pool_size 50 - 80 %      # of ram beware of setting memory usage high      #innodb_buffer_pool_size = 16m      #innodb_additional_mem_pool_size = 2m      # set .._log_file_size 25 % of buffer pool size      #innodb_log_file_size = 5m      #innodb_log_buffer_size = 8m      #innodb_flush_log_at_trx_commit = 1      #innodb_lock_wait_timeout = 50       [mysqldump]      quick      max_allowed_packet = 16m       [mysql]      no-auto-rehash      # remove next comment character if not familiar sql      #safe-updates       [isamchk]      key_buffer = 8m      sort_buffer_size = 8m       [myisamchk]      key_buffer = 8m      sort_buffer_size = 8m       [mysqlhotcopy]      interactive-timeout 

here mysqltuner output : http://i.imgur.com/dpds2uk.png

last mysql error log :

140818 14:01:15 mysqld_safe starting mysqld daemon databases /var/lib/mysql 140818 14:01:15 [warning] using unique option prefix key_buffer instead of key_buffer_size deprecated , removed in future release. please use full name instead. 140818 14:01:15 [warning] option 'thread_stack': unsigned value 65536 adjusted 131072 140818 14:01:15 [warning] syntax '--log-slow-queries' deprecated , removed in future release. please use '--slow-query-log'/'--slow-query-log-file' instead. 140818 14:01:15 [note] plugin 'federated' disabled. 140818 14:01:15 [note] plugin 'innodb' disabled. 140818 14:01:15 [note] server hostname (bind-address): '0.0.0.0'; port: 3306 140818 14:01:15 [note]   - '0.0.0.0' resolves '0.0.0.0'; 140818 14:01:15 [note] server socket created on ip: '0.0.0.0'. 140818 14:01:15 [note] event scheduler: loaded 0 events 140818 14:01:15 [note] /usr/sbin/mysqld: ready connections. version: '5.5.37-cll'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  mysql community server (gpl) 

can me fix , my.cnf file.mysql shutting down itself.i using innodb.here sql log shutdown error :

140818 13:13:31 innodb: initializing buffer pool, size = 16.0m innodb: mmap(17170432 bytes) failed; errno 12 140818 13:13:31 innodb: completed initialization of buffer pool 140818 13:13:31 innodb: fatal error: cannot allocate memory buffer pool 140818 13:13:31 [error] plugin 'innodb' init function returned error. 140818 13:13:31 [error] plugin 'innodb' registration storage engine failed. 140818 13:13:31 [error] unknown/unsupported storage engine: innodb 140818 13:13:31 [error] aborting  140818 13:13:31 [note] /usr/sbin/mysqld: shutdown complete 


Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -