Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why is the my.cnf file on the server incomplete or has very few entries?

Tags:

mysql

ssh

plesk

I have accessed a clients server (plesk) via ssh to view/edit the my.cnf and php.ini files if i view them using vi the file seem to be virtualy empty of entries ? see screenshot.

Not sure whether this is an access issue or the files are the right files any help would be appreciated

Thanks

enter image description here

like image 358
Ledgemonkey Avatar asked Jan 04 '12 11:01

Ledgemonkey


People also ask

What is stored in my CNF file?

cnf or in the default installation directory. This file contains configuration settings that will be loaded when the server is first started including settings for the clients, server, mysqld_safe wrapper and various other mysql client programs.

What is server CNF?

The Server Configuration File. Configuration settings for the Integration Server are stored in the server configuration file (server. cnf). This file resides in the Integration Server_directory \instances\instance_name\config directory and contains parameters that determine how the server operates.


1 Answers

As Rup already mentioned in his comment, the my.cnf file contains only these few lines. It is completely fine, mysql server is able to start also without any config file - in that case it uses the defaults plus whatever is on the commandline. To see what config files mysqld reads and what defaults it uses, just run:

mysqld --verbose --help

and it will produce report containing for example this:

mysqld  Ver 5.0.51a-24-log for debian-linux-gnu on x86_64 ((Debian))

Default options are read from the following files in the given order:
/etc/mysql/my.cnf ~/.my.cnf /usr/etc/my.cnf

The following groups are read: mysql_cluster mysqld server mysqld-5.0

Variables (--variable-name=value)
and boolean options {FALSE|TRUE}  Value (after reading options)
--------------------------------- -----------------------------
help                              TRUE
...
wait_timeout                      3600

To see what values a running MySQL server is using, type
'mysqladmin variables' instead of 'mysqld --verbose --help'.
like image 78
Marki555 Avatar answered Oct 01 '22 03:10

Marki555