1

I installed percona-server-client-5.6 on Ubuntu; there is no mysql server installed on that same machine.

In /etc/mysql/, the only file is my.cnf. That file contains many sections of options and I am not sure which sections are applicable to the machine with only the client package installed.

I assume the [client] section of course, but why to the other sections exist at all? Will changing their values affect the mysql server the client connects to?

my.cnf:

[client]
...

[mysqld_safe]
...

[mysqld]
...

[mysqldump]
...

[mysql]
...

[isamchk]
...
1

Those other sections are there because they are included in the template cnf file from the package provider (Percona).

You can create a user specific cnf file in your home dir that looks like the one below and they will get used when you run the mysql command:

[client]
user=$myusername
password=$mypassword

n.b. if you're going to store your credentials in a cnf file make sure you set the permissions to 400.

| improve this answer | |
-1

mysql install my.cnf as template with all sections and commented help information

for start work You generally will need only [client] section

for connect use command line like

user$ mysql -h 192.168.10.111 -u root -p
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.