Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Installation

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-10-2005, 02:20 PM
Intermediate Member
 
Posts: 16
Default Can't start MySQL to init db - Gentoo

I've gotten further today with the help of the forums in getting Zimbra up on Gentoo, but am now stuck at running MySQL. I've stopped my 'main' one, renamed /usr/bin/mysql to mysql.old, verified that which MySQL(d) is now the right one:

Code:
jorge bin # which mysql
/opt/zimbra/bin/mysql
jorge bin # which mysqld
/opt/zimbra/mysql-standard-4.1.10a-pc-linux-gnu-i686/bin/mysqld
but when I try to run the Zimbra mySQL I get a perm denied. I'm running this as root, shouldn't it *just work*? What am I doing wrong? Thanks

Code:
jorge mysql # cd /opt/zimbra/bin/
jorge bin # ./mysql.server start
jorge bin # Starting mysqld daemon with databases from /opt/zimbra/db/data
STOPPING server from pid file /opt/zimbra/db/mysql.pid
051010 14:52:17  mysqld ended

jorge bin # cat ../log/mysqld.log
051010 14:52:17  mysqld started
/etc/host.conf: line 24: bad command `mdns off'
051010 14:52:17 [ERROR] Can't start server : Bind on unix socket: Permission denied
051010 14:52:17 [ERROR] Do you already have another mysqld server running on socket: /opt/zimbra/db/mysql.sock ?
051010 14:52:17 [ERROR] Aborting

051010 14:52:17 [Note] /opt/zimbra/mysql/bin/mysqld: Shutdown complete

051010 14:52:17  mysqld ended
jorge bin # ps aux | grep mysql
jorge bin #

Also I have run the fixpermissions script in bin, to no avail, then I tried running zmmyinit again, but it failed to set root and zimbra's password since it couldn't start MySQL either:


Code:
jorge bin # /opt/zimbra/libexec/zmmyinit
* Creating required directories
* Generating mysql config /opt/zimbra/conf/my.cnf
* Creating database in /opt/zimbra/db/data
* Starting mysql server
* Loading schema /opt/zimbra/db/db.sql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/opt/zimbra/db/mysql.sock' (2)
* Loading version from /opt/zimbra/db/versions-init.sql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/opt/zimbra/db/mysql.sock' (2)
* Setting random password for mysql root user in zimbra local config
* Setting random password for mysql zimbra user in zimbra local config
* Changing mysql root user password
/opt/zimbra/mysql/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/opt/zimbra/db/mysql.sock' (2)'
Check that mysqld is running and that the socket: '/opt/zimbra/db/mysql.sock' exists!
* Changing mysql zimbra user password
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/opt/zimbra/db/mysql.sock' (2)
**** PASSWORD CHANGE FAILED
jorge bin #
How can I get MySQL running?

Thanks

fak3r
Reply With Quote
  #2 (permalink)  
Old 10-10-2005, 05:16 PM
Zimbra Employee
 
Posts: 4,792
Default

Does a file call mysql.sock already defined? Is so maybe delete it?


'/opt/zimbra/db/mysql.sock'
Reply With Quote
  #3 (permalink)  
Old 10-10-2005, 05:29 PM
Zimbra Employee
 
Posts: 2,103
Default run as the zimbra user

You don't have to run mysql as root - it doesn't bind to a privileged port. I'd remove the socket file, then try starting it as the zimbra user.
Reply With Quote
  #4 (permalink)  
Old 10-10-2005, 07:59 PM
Intermediate Member
 
Posts: 16
Default

Apparently I didn't have rights correctly set - this fixed it:
Code:
chown -R zimbra:zimbra /opt/zimbra/db/data
chmod -R 775 /opt/zimbra/db/data
Now, is this the right way or wrong way to fix it, since fixpermissions.sh didn't set it like this?

fak3r
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.