MySQL has three different kinds of configuration, both for the server process at server startup and for the client processes when a user executes them.
In order of preference, these configuration options include:
- Command-line options
- Configuration file options
- Environment variable options
MySQL specifies options according to the different groups, usually the names of the server tools. The options arranged in group segments. The group name placed within brackets and options applied to it follow.
It can be more clear when you will see the default /etc/my.cnf file.
View the different options currently set for both server and client
Run mysqld directly with the –help option.
- /usr/libexec/mysqld –help
changing the configuration of MySQL
Specifies the root directory of your MySQL install.
Executes in batch mode, meaning no command-line prompts or other information is sent to stdout. It is the default mode when used with a pipe.
Specifies where your character set files stored.
Tells the client and server to use compression in the network protocol.
Specifies the location of MySQL's data files.
Specifies a file to send debug information.
Indicates that you want processing to continue for client utilities even when an error encountered.
Identifies the host to which a client should connect by default.
Specifies the language to use for localization.
Specifies the file to which connections and queries logged.
Specifies the file to which isam changes logged.
Specifies a default password for clients to use to connect.
Specifies the port number to which the server should listen and to which clients should connect.
Silently exit if a connection failure occurs.
Tells the MySQL server to avoid new, potential buggy routines.
Tells the server to ignore all grant tables, effectively giving all users full access to the database server.
Potentially provides better system performance by avoiding system locking. It should not used in conjunction with isamchk or myisamchk.
Sleep between commands.
Socket file to use for local connections.
Specifies the user name to use for client connections.
- variable-name =value
Sets the specified variable name to a particular value.
Tells MySQL to talk more about what is happening.
Tells the client to wait after a connection failure and then retry the connection.
MySQL supports multiple configuration files. As a general rule, it checks files in the following order of preference:
- User configuration file (Linux only).
- Configuration file specified through the –defaults-extra-file=filename option.
- A configuration file in the MySQL data directory.
- The system configuration file.
- In all cases except the command-line and user configuration options, the name of the configuration file on Unix is my.cnf and on Windows is my.ini.
- A Unix user can override system configuration information by building their configuration file in ~/.my.cnf.
- The system configuration file on a Linux system is /etc/my.cnf.
Windows, on the other hand, has two system configuration locations, in order of preference:
You can alternately specify a file on the command line using the –defaults-file=filename option.
This option causes all the possibilities defined in other files to be ignored, even if they not overridden in the file you specify.
Cloud SSD Hosting
|$1.43 /mo.||WILMINGTON, DE, US||Price @ $1.43 /mo.||Visit Now|
|$2.99 /mo.||LASALLE, CA||Price @ $2.99 /mo.||Visit Now|
|$2.75/mo.||Burlington, MA, US||Price : $2.75/mo.||Visit Now|
Lifetime Free Domain
|$3.95/mo.||Panama, PA||Start @ $3.95/mo.||Visit Now|
|$1.99/mo.||Arlington Heights, IL, US||Start @ $1.99/mo.||Visit Now|
|$4.95/mo||AUBURN, MA, US||Start @ $4.95/mo||Visit Now|
|$3.25/mo.||Burlington, MA, US||Start @ $3.25/mo.||Visit Now|
|$3.95/mo||Columbus, OH, US||Start @ $3.95/mo||Visit Now|
|$4.95/mo||NASHUA, NH, US||Start @ $4.95/mo||Visit Now|
Managed WordPress Hosting
|$89.00/mo.||Lansing, MI, US||Price : $19.00/mo.||Visit Now|