Software


24
Apr 11

Automatically starting XAMPP on MAC OSX boot up

Using Terminal

$ cd /Library/StartupItems

$ sudo mkdir xampp

$ cd xampp/

$ sudo nano xampp

Enter the contents below:


#!/bin/sh

/Applications/XAMPP/xamppfiles/xampp start

If you installed XAMPP elsewhere you will need to modify the path above.

You can also start specific xampp apps for example, starting apache only by using /Applications/XAMPP/xamppfiles/xampp startapache instead.

 

$ sudo nano  StartupParameters.plist

Enter the contents below:


<?xml version=”1.0″ encoding=”UTF-8″?>

<!DOCTYPE plist SYSTEM “file://localhost/System/Library/DTDs/PropertyList.dtd”>

<plist version=”0.9″>

<dict>

<key>Description</key>

<string>XAMPP</string>

<key>OrderPreference</key>

<string>Late</string>

<key>Provides</key>

<array>

<string>Starts Apache and MySQL</string>

</array>

<key>Uses</key>

<array>

<string>SystemLog</string>

</array>

</dict>

</plist>

$ cd ..

$ sudo chown -R root xampp

$ sudo chgrp -R wheel xampp

$ sudo chmod 755 xampp/xampp

 

That’s it!

All you now have to do is to restart your MAC and xampp will start automatically on boot.

 

Original Solution was by Sreeprakash N which can be found here (http://sree.cc/mac-os-x/how-start-xampp-at-startup-on-mac-os-x) , however it’s not easy to follow as a few commands have been jumbled together, hence this post to make it easier for others to follow.