I have a virtual linux server with 1G RAM installed ubuntu 15.10 on Linode. I have very limited knowledge about setting up LAMP environment, so I could only blindly follow the guides to set up my website. I just finished step 5 in "Optimizing MySQL for a Linode 1GB". When I tried to proceed to the next step and start mysql to create database, I got this error message:"unknown variable 'max_connections=75'".
Here is the content of my "my.cnf":
#
# The MySQL database server configuration file.
#
# You can copy this to one of:
# - "/etc/mysql/my.cnf" to set global options,
# - "~/.my.cnf" to set user-specific options.
#
# One can use all long options that the program supports.
# Run program with --help to get a list of available options and with
# --print-defaults to see which it would actually understand and use.
#
# For explanations see
# http://dev.mysql.com/doc/mysql/en/server-system-variables.html
#
# * IMPORTANT: Additional settings that can override those from this file!
# The files must end with '.cnf', otherwise they'll be ignored.
#
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
#### Added by me #####
[mysql]
max_connections = 75
max_allowed_packet = 1M
thread_stack = 128K
table_open_cache = 32M
key_buffer_size = 32M
Anything below "Added by me" comment line didnt' exist before I modified the file. I checked my mysql verysion, it is 5.6+, and I was able to login mysql before I modified the my.conf file. Apparenly the problem lies in the '[mysql]' block, but what could possibly be wrong?
Please edit [mysql] to [mysqld] and start mysql
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With