# mysql 5.5 errmsg.sys



## indul (Feb 17, 2011)

Hi Members,

I can't start mysql 5.5.9 on FreeBSD 8.1-R server. New install, from ports; mysqld_safe is fine, all databases are up and running.
Error log (during */usr/local/etc/rc.d/mysql start*):


```
110217 13:14:47 mysqld_safe Starting mysqld daemon with databases from /var/db/mysql
110217 13:14:47 [ERROR] Can't find messagefile '/usr/local/share/mysql/errmsg.sys'
110217 13:14:47 InnoDB: The InnoDB memory heap is disabled
110217 13:14:47 InnoDB: Mutexes and rw_locks use GCC atomic builtins
110217 13:14:47 InnoDB: Compressed tables use zlib 1.2.3
110217 13:14:47 InnoDB: Initializing buffer pool, size = 128.0M
110217 13:14:47 InnoDB: Completed initialization of buffer pool
110217 13:14:47 InnoDB: highest supported file format is Barracuda.
110217 13:14:47  InnoDB: Waiting for the background threads to start
110217 13:14:48 InnoDB: 1.1.5 started; log sequence number 1778548
110217 13:14:48 [ERROR] Aborting

110217 13:14:48  InnoDB: Starting shutdown...
110217 13:14:49  InnoDB: Shutdown completed; log sequence number 1778548
110217 13:14:49 [Note]
110217 13:14:49 mysqld_safe mysqld from pid file /var/db/mysql/sql.local ended
```


```
[root@sql /usr/local/etc/rc.d]# ls -l /usr/local/share/mysql/errmsg.sys
-rw-r--r--  1 mysql  wheel  42670 Feb 16 23:15 /usr/local/share/mysql/errmsg.sys
```

How can I solve this problem?
Thanx.


----------



## ruudboon (Mar 9, 2011)

Having the same issue. File /usr/local/share/mysql/english/errmsg.sys exists, but still giving this error and I'm unable to start MySql. Using 8.1-RELEASE FreeBSD 8.1-RELEASE #0


----------



## seanluck13 (Jun 16, 2011)

*Please Help!*

I just upgraded to 8.2 RELEASE from 8.0 using the freebsd-update utility as described in the Handbook. Now I am seeing the same error. When I first installed mysql on 8.0 I recall having this problem and I can't for the life of me recall how I fixed it. (Document, document, document!! *sigh*). I'm going nuts!

I have tried copying the errmsg.sys file to /usr/local/share/mysql/ from /usr/local/share/mysql/english/. I've tried linking the file. I've tried using the --language=english argument in rc.conf, and the error just changes path to 
	
	



```
[ERROR] Can't find messagefile '/usr/local/share/mysql/english/errmsg.sys'
```
 It's THERE!

Yes, I've tried fooling with permissions. I've tried deinstalling and reinstalling (including removing all old databases). 

Now here's the kicker. If I start the server manually using the exact command line that the startup script in rc.d uses:
`/usr/sbin/daemon -c -f /usr/local/bin/mysqld_safe --defaults-extra-file=/var/db/mysql/my.cnf --user=mysql --datadir=/var/db/mysql \`[cmd=] --pid-file=/var/db/mysql/host.name.net.pid[/CMD] it starts fine, but `/usr/local/etc/rc.d/mysql-server start` bombs with the errmsg.sys error.

Someone PLEASE put me out of my misery! I know it's probably something stupid that I'm overlooking but Google doesn't have anything and I've spent the better part of two days banging my head against this.

Thanks!
Sean.


----------



## seanluck13 (Jun 16, 2011)

I should perhaps also mention that I'm using AMD64 and it's MySQL v5.5.13.


----------



## seanluck13 (Jun 17, 2011)

*The Answer*

For anyone else having this problem, here's what fixed it for me. Check the permissions on the /usr/local/share/mysql folder. The port installs it as:


```
drwxr-x---     root wheel
```

It has to be:


```
drwxr-xr-x     root wheel
```

in order to start from the .rc script. 

I swear I looked at that already but clearly I must have missed it. DOH!

Anyhow, there you go.


----------



## seanluck13 (Jun 17, 2011)

Annnnnnnnnd that would be my umask. *sigh*


----------



## SomeGuy (Nov 14, 2011)

@seanluck13:

Thank you for posting your solution and diagnosis. I had exactly the same problem for exactly the same reason. I think it's arguably a bug in the port that it honors umask while installing /usr/local/share/mysql. I see now that I copied over my user .bashrc to /root/.bashrc, and that had umask 027.

I decided to read the results of one last google search before formatting this FreeBSD VM and starting over. I'm so happy I just avoided 3 hours of work.


----------



## SomeGuy (Nov 14, 2011)

For anyone with a similar problem, might I suggest looking for files in /usr/local that are not world readable, because an over tightened root umask seems to affect most installs.

`find /usr/local ! -perm -004`


----------

