The rc.d script shipped with the port of mysql server exits immediately after mysqld starts. This normally wouldn't be a problem but the mysql daemon exits about a second before it has established it's unix domain listening socket: "/tmp/mysql". The problem here is that the rc startup system can queue the next daemon to start before "/tmp/mysql" is available. If the next daemon needs mysql it will fail and exit. On my system rcorder starts mysql-server and then immediately follows up with jabberd. Since mysql doesn't appear ready for about a second jabberd fails and exits. I've attached a patch which waits for up to 15 seconds for the /tmp/mysql socket to appear in the filesystem and exits as soon as it's available. This allows the next daemon in line to startup properly if it needs mysql. Note that I have had this problem with postfix up until I removed my mail information from mysql. Fix: This may not adhere to the strictest rules of the rcorder system but my solution is to hack the provider's (mysql-server) startup script. The goal was to prevent the script from exiting until either the listening socket is established or a 15 second timeout has passed. A better solution would be for mysqld to establish the listening socket first (even if it ignores incoming connections for a little bit) but that's much higher effort. Patch attached with submission follows: How-To-Repeat: Build a system that uses mysql and jabber or postfix. Ensure that jabberd starts after mysql by hacking /usr/local/etc/rc.d/jabberd's ## REQUIRES line. Assuming you're not on some hot rod of a machine check your logs for jabberd2's failure line in the service manager.
Responsible Changed From-To: freebsd-ports-bugs->ale Over to maintainer (via the GNATS Auto Assign Tool)
ale 2008-06-07 08:33:50 UTC FreeBSD ports repository Modified files: databases/mysql51-server Makefile distinfo databases/mysql51-server/files mysql-server.sh.in Log: Update to 5.1.25-rc release. Fix startup script to wait until server is completely up. [1] PR: ports/122063 [1] Submitted by: Christopher Sean Hilton <chris@vindaloo.com> [1] Revision Changes Path 1.232 +2 -2 ports/databases/mysql51-server/Makefile 1.103 +3 -3 ports/databases/mysql51-server/distinfo 1.5 +12 -1 ports/databases/mysql51-server/files/mysql-server.sh.in _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: open->closed A slightly different patch has been applied, thanks.