Why is /etc/mysql/my.cnf EMPTY?
up vote
11
down vote
favorite
I am trying to edit the my.cnf
file to allow remote access and ultimately using software from my Windows Server to configure scheduled backup for MySQL Server.
I was following these instructions.
However, the /etc/mysql/my.cnf
file on my Ubuntu has only:
#
# 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/
It doesn't contain any configuration that I can edit. Why is it like that?
server mysql
add a comment |
up vote
11
down vote
favorite
I am trying to edit the my.cnf
file to allow remote access and ultimately using software from my Windows Server to configure scheduled backup for MySQL Server.
I was following these instructions.
However, the /etc/mysql/my.cnf
file on my Ubuntu has only:
#
# 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/
It doesn't contain any configuration that I can edit. Why is it like that?
server mysql
add a comment |
up vote
11
down vote
favorite
up vote
11
down vote
favorite
I am trying to edit the my.cnf
file to allow remote access and ultimately using software from my Windows Server to configure scheduled backup for MySQL Server.
I was following these instructions.
However, the /etc/mysql/my.cnf
file on my Ubuntu has only:
#
# 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/
It doesn't contain any configuration that I can edit. Why is it like that?
server mysql
I am trying to edit the my.cnf
file to allow remote access and ultimately using software from my Windows Server to configure scheduled backup for MySQL Server.
I was following these instructions.
However, the /etc/mysql/my.cnf
file on my Ubuntu has only:
#
# 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/
It doesn't contain any configuration that I can edit. Why is it like that?
server mysql
server mysql
edited May 5 '17 at 18:18
Zanna
49.1k13123234
49.1k13123234
asked Nov 19 '15 at 6:21
Mercedez
56113
56113
add a comment |
add a comment |
4 Answers
4
active
oldest
votes
up vote
22
down vote
Firstly, as A.B. rightly points out, the file is not empty. It has two rather important directives, namely
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
Those lines are saying that additional configuration files (.cnf in this case) can be found in the directories listed:
/etc/mysql/conf.d/
/etc/mysql/mysql.conf.d/
The latter of the two directories should contain mysqld.cnf. In other words, the appropriate configuration file should be:
/etc/mysql/mysql.conf.d/mysqld.cnf
1
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
add a comment |
up vote
2
down vote
The file isn't empty. It contains comments, the lines wit a leading #
, and import statements, the lines with a leading !
. A import statement means, other configurations will be used, too.
And editing a configuration also means, add new configuration lines.
add a comment |
up vote
1
down vote
My file is the same. You need to add the correct group above the command you're trying to put in otherwise the service wont start.
To add bind-address
you will need to add [mysqld]
above it.
If you need to check what the groups are for the other commands, there's an example my.cnf
file here.
If you want to enable remote connections from all interfaces, your file would look something like below, however make sure you set up your firewall correctly if you do use 0.0.0.0:
#
# 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/
[mysqld]
bind-address = 0.0.0.0
Note the [mysqld] group.
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
add a comment |
up vote
0
down vote
In that case, that file is not the main where all the information about bind-adress, binlogs and etc include. But there is another file, where they include. Try this:
nano /etc/mysql/mysql.conf.d/mysqld.cnf
It helped me, and It should help you.
add a comment |
4 Answers
4
active
oldest
votes
4 Answers
4
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
22
down vote
Firstly, as A.B. rightly points out, the file is not empty. It has two rather important directives, namely
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
Those lines are saying that additional configuration files (.cnf in this case) can be found in the directories listed:
/etc/mysql/conf.d/
/etc/mysql/mysql.conf.d/
The latter of the two directories should contain mysqld.cnf. In other words, the appropriate configuration file should be:
/etc/mysql/mysql.conf.d/mysqld.cnf
1
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
add a comment |
up vote
22
down vote
Firstly, as A.B. rightly points out, the file is not empty. It has two rather important directives, namely
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
Those lines are saying that additional configuration files (.cnf in this case) can be found in the directories listed:
/etc/mysql/conf.d/
/etc/mysql/mysql.conf.d/
The latter of the two directories should contain mysqld.cnf. In other words, the appropriate configuration file should be:
/etc/mysql/mysql.conf.d/mysqld.cnf
1
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
add a comment |
up vote
22
down vote
up vote
22
down vote
Firstly, as A.B. rightly points out, the file is not empty. It has two rather important directives, namely
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
Those lines are saying that additional configuration files (.cnf in this case) can be found in the directories listed:
/etc/mysql/conf.d/
/etc/mysql/mysql.conf.d/
The latter of the two directories should contain mysqld.cnf. In other words, the appropriate configuration file should be:
/etc/mysql/mysql.conf.d/mysqld.cnf
Firstly, as A.B. rightly points out, the file is not empty. It has two rather important directives, namely
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
Those lines are saying that additional configuration files (.cnf in this case) can be found in the directories listed:
/etc/mysql/conf.d/
/etc/mysql/mysql.conf.d/
The latter of the two directories should contain mysqld.cnf. In other words, the appropriate configuration file should be:
/etc/mysql/mysql.conf.d/mysqld.cnf
answered Nov 19 '15 at 6:49
Techedemic
35614
35614
1
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
add a comment |
1
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
1
1
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
somethings not right either way. when I edit the halfway-empty my.conf file and e.g. set wait_timeout = 600, the service mysql cannot be started anymore..
– Blauhirn
Aug 4 '16 at 12:20
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
This is exact answer for the question.
– ambarox
Mar 14 '17 at 7:55
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
Wish I could find it 6 hours earlier!
– neophyte
Aug 3 '17 at 4:38
add a comment |
up vote
2
down vote
The file isn't empty. It contains comments, the lines wit a leading #
, and import statements, the lines with a leading !
. A import statement means, other configurations will be used, too.
And editing a configuration also means, add new configuration lines.
add a comment |
up vote
2
down vote
The file isn't empty. It contains comments, the lines wit a leading #
, and import statements, the lines with a leading !
. A import statement means, other configurations will be used, too.
And editing a configuration also means, add new configuration lines.
add a comment |
up vote
2
down vote
up vote
2
down vote
The file isn't empty. It contains comments, the lines wit a leading #
, and import statements, the lines with a leading !
. A import statement means, other configurations will be used, too.
And editing a configuration also means, add new configuration lines.
The file isn't empty. It contains comments, the lines wit a leading #
, and import statements, the lines with a leading !
. A import statement means, other configurations will be used, too.
And editing a configuration also means, add new configuration lines.
edited Nov 19 '15 at 6:37
answered Nov 19 '15 at 6:24
A.B.
67.4k12161249
67.4k12161249
add a comment |
add a comment |
up vote
1
down vote
My file is the same. You need to add the correct group above the command you're trying to put in otherwise the service wont start.
To add bind-address
you will need to add [mysqld]
above it.
If you need to check what the groups are for the other commands, there's an example my.cnf
file here.
If you want to enable remote connections from all interfaces, your file would look something like below, however make sure you set up your firewall correctly if you do use 0.0.0.0:
#
# 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/
[mysqld]
bind-address = 0.0.0.0
Note the [mysqld] group.
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
add a comment |
up vote
1
down vote
My file is the same. You need to add the correct group above the command you're trying to put in otherwise the service wont start.
To add bind-address
you will need to add [mysqld]
above it.
If you need to check what the groups are for the other commands, there's an example my.cnf
file here.
If you want to enable remote connections from all interfaces, your file would look something like below, however make sure you set up your firewall correctly if you do use 0.0.0.0:
#
# 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/
[mysqld]
bind-address = 0.0.0.0
Note the [mysqld] group.
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
add a comment |
up vote
1
down vote
up vote
1
down vote
My file is the same. You need to add the correct group above the command you're trying to put in otherwise the service wont start.
To add bind-address
you will need to add [mysqld]
above it.
If you need to check what the groups are for the other commands, there's an example my.cnf
file here.
If you want to enable remote connections from all interfaces, your file would look something like below, however make sure you set up your firewall correctly if you do use 0.0.0.0:
#
# 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/
[mysqld]
bind-address = 0.0.0.0
Note the [mysqld] group.
My file is the same. You need to add the correct group above the command you're trying to put in otherwise the service wont start.
To add bind-address
you will need to add [mysqld]
above it.
If you need to check what the groups are for the other commands, there's an example my.cnf
file here.
If you want to enable remote connections from all interfaces, your file would look something like below, however make sure you set up your firewall correctly if you do use 0.0.0.0:
#
# 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/
[mysqld]
bind-address = 0.0.0.0
Note the [mysqld] group.
edited Nov 21 at 9:48
Gigablah
1033
1033
answered Aug 10 '17 at 14:13
Rob
114
114
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
add a comment |
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
This is such pain in a**. Have been trying to make remote connections work for almost two days now. Remote connections should be enabled out of the box.
– Mark Alexa
Sep 7 '17 at 14:48
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
Why would you expose every database server to the internet out of the box? Aren't there enough unsecured systems out there?
– A. Scherbaum
Oct 10 '17 at 11:52
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
If you wish to access it from more than one, but less than all the interfaces, you should bind to 0.0.0.0 and firewall off the interfaces you don't want to be accessed through.
– Rob
Apr 9 at 13:32
add a comment |
up vote
0
down vote
In that case, that file is not the main where all the information about bind-adress, binlogs and etc include. But there is another file, where they include. Try this:
nano /etc/mysql/mysql.conf.d/mysqld.cnf
It helped me, and It should help you.
add a comment |
up vote
0
down vote
In that case, that file is not the main where all the information about bind-adress, binlogs and etc include. But there is another file, where they include. Try this:
nano /etc/mysql/mysql.conf.d/mysqld.cnf
It helped me, and It should help you.
add a comment |
up vote
0
down vote
up vote
0
down vote
In that case, that file is not the main where all the information about bind-adress, binlogs and etc include. But there is another file, where they include. Try this:
nano /etc/mysql/mysql.conf.d/mysqld.cnf
It helped me, and It should help you.
In that case, that file is not the main where all the information about bind-adress, binlogs and etc include. But there is another file, where they include. Try this:
nano /etc/mysql/mysql.conf.d/mysqld.cnf
It helped me, and It should help you.
answered Sep 29 at 7:15
Guu Mee
1
1
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f699903%2fwhy-is-etc-mysql-my-cnf-empty%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown