Apache2 and MySQL5 on Boot (LaunchDaemons)

aucwe aucwe at gmx.net
Fri Jun 8 06:49:55 PDT 2007


Hi all

I have some trouble with the LaunchDaemons of Apache2 and Mysql5.

I did install Apache2, PHP5 and Mysql5 using macports (newest version)
on a PPC-MacMini:

sudo port sync
sudo port install apache2
sudo port install mysql5 +server
sudo port install php5 +apache2 +mysql5 +pear

then I did:

sudo launchctl load -w /Library/LaunchDaemons/org.macports.apache2.plist
sudo launchctl load -w /Library/LaunchDaemons/org.macports.mysql5.plist

After that both mysql5 and apache2 started on boot or reboot. So the
macports standard installation works fine.

In a further step I copied (using rsync) the directories
/opt/local/apache2/htdocs  and /opt/local/var/db/mysql5 to another
partition of my harddrive.
And of course modified the config files properly.

After theses steps both LaunchDaemons dosen't work anymore. But I can
start both applications on the command line (mysqld_safe, apachectl)
using the non standard configuration.

Further I tried to start mysql using the wrapper script:
sudo /opt/local/etc/LaunchDaemons/org.macports.mysql5/mysql5.wrapper start
an got the message
Starting MySQL ERROR! Couldn't find MySQL manager or server.
(Is there a mysql error_log file? I couln't find any!)

In case of apache2 I can start an stop apache2 using the wrapper script
on the command line:
sudo /opt/local/etc/LaunchDaemons/org.macports.apache2/apache2.wrapper start
sudo /opt/local/etc/LaunchDaemons/org.macports.apache2/apache2.wrapper stop
but it does not work on boot time (the apache2 error_log shows a sigterm
shutting down entry)

When I go back to the macports standard installation everthing works fine.

Any help an tips will be appreciated!!

Kind regards, Roland




More information about the macports-users mailing list