# Mysql change port problem



## muczor (Oct 2, 2018)

Hello,
How on the FreeBSD 11 version change the MySQL port?
I edit my.cnf in the /usr/local/etc/mysql and nothing.
I really have no idea how to change it.


----------



## ShelLuser (Oct 2, 2018)

How did you change it and _what_ did you change? Without that info there's no way to say what could have gone wrong.


----------



## muczor (Oct 2, 2018)

My errors: https://pastebin.com/REe60gqE
My config file: https://pastebin.com/VKPVtgs8


----------



## ShelLuser (Oct 3, 2018)

Check the error log again and carefully read what it says at the top:


```
Warning: World-writable config file '/usr/local/etc/mysql/my.cnf' is ignored
Warning: World-writable config file '/usr/local/etc/mysql/my.cnf' is ignored
```
I'm pretty sure that's the key to your problem. Some software, such as MySQL, protects you from shooting yourself in the foot. Obviously using a config file which every user on your server could change is an _extremely_ bad idea as such it got ignored.

Solution is therefor to change your permission settings to something more sane. 644 for example.


----------



## SirDice (Oct 3, 2018)

Never, EVER, `chmod 777` a file or directory to "fix" a problem. It's rarely, if ever, the correct solution.


----------

