Page 1 of 1
Mysql server stops always
Posted: Sat Oct 10, 2015 4:18 am
by anjalimay6
Mysql always stopping in my vesta cp. I run vesta cp on 1vcpu with 1.24 GB of RAM. I'm not able to restart or start service. Only workaround what I currently have to restart server . Please let me know how can I fix it. I haven't enabled swap memory to this server .

Re: Mysql server stops always
Posted: Sat Oct 10, 2015 4:29 am
by anjalimay6
Created a swap, following this post :
http://forum.vestacp.com/viewtopic.php?f=14&t=9239
will let you know if this stops again
Re: Mysql server stops always
Posted: Sun Oct 11, 2015 4:53 am
by anjalimay6
This is my RAM usauge status. It stopped once , but not frequent .

. Help me for permanent solution.
Re: Mysql server stops always
Posted: Sun Oct 11, 2015 7:12 pm
by skurudo
Make changes in your mysql config -> my.cnf
Code: Select all
key_buffer = 16K
max_allowed_packet = 1M
thread_stack = 64K
table_cache = 4
sort_buffer = 64K
net_buffer_length = 2K
or this
Code: Select all
max_connections= 20
connect_timeout= 5
wait_timeout= 28800
max_allowed_packet= 32M
thread_cache_size = 50
sort_buffer_size= 4M
bulk_insert_buffer_size= 16M
tmp_table_size= 32M
max_heap_table_size= 32M
join_buffer_size= 256K
#
# * MyISAM
#
# This replaces the startup script and checks MyISAM tables if needed
# the first time they are touched. On error, make copy and try a repair.
myisam_recover = BACKUP
key_buffer_size= 128M
open-files-limit= 5000
table_open_cache= 2000
myisam_sort_buffer_size= 128M
concurrent_insert= 2
read_buffer_size= 2M
read_rnd_buffer_size= 1M
#
# * Query Cache Configuration
#
query_cache_type= OFF
#
# * Logging and Replication
#
log_warnings= 2
slow_query_log= 1
slow_query_log_file= /srv/d_cs-amx/mysql/log/mariadb-slow.log
long_query_time= 5
log_slow_verbosity= query_plan
log_bin= /srv/d_cs-amx/mysql/log/mariadb-bin
log_bin_index= /srv/d_cs-amx/mysql/log/mariadb-bin.index
sync_binlog= 1
expire_logs_days= 3
max_binlog_size = 100M
#
# * InnoDB
#
default_storage_engine= InnoDB
innodb_buffer_pool_size= 128M
innodb_log_buffer_size= 8M
innodb_file_per_table= 1
innodb_open_files= 1024
innodb_io_capacity= 1024
innodb_flush_method= O_DIRECT
innodb_thread_concurrency= 0
innodb_stats_on_metadata= off
innodb_old_blocks_time= 1000
Re: Mysql server stops always
Posted: Sun Oct 11, 2015 7:13 pm
by skurudo
anjalimay6 wrote:This is my RAM usauge status. It stopped once , but not frequent .
Help me for permanent solution.
Well, there is no _permanent_ solution. Time to time you will need to make changes, when it needed.
Re: Mysql server stops always
Posted: Mon Oct 12, 2015 4:52 pm
by anjalimay6
Sorry I'm not expert in this , could please give me the file location?
Re: Mysql server stops always
Posted: Tue Oct 13, 2015 3:12 pm
by skurudo
Re: Mysql server stops always
Posted: Wed Oct 14, 2015 4:35 pm
by anjalimay6
Thanks alot ! always read manuals ! :)