Shinobu’s Secrets

September 29, 2008

No More XAMPP For Me! A Better Alternative Exists On Xubuntu

Filed under: Linux — Shinobu @ 7:47 am

If you’re on a Ubuntu-based distro, you’re in luck: you don’t have to install XAMPP to get a web server started! Just install the following packages, including all dependencies, in order:

  1. mysql-server
  2. apache2
  3. php5

Restart Apache with sudo /etc/init.d/apache2 restart. (Apache should complain like this: “Could not determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName” — to resolve this, open up /etc/apache2/httpd.conf and add a line like ServerName localhost. See this page for more info.)

Optionally, install phpmyadmin.

For phpmyadmin, the administrative user is “root”, as usual.

Your web pages are now stored in the /var/www/ directory. From here, symlink to any other directory in your hard drive to include that directory into your web server! The beauty of this method, instead of going with XAMPP, is that your system will automatically update all web-server related components whenever you update your system with apt-get or Synaptic Package Manager or whatever. Also, Apache will start automatically whenever you reboot. No more downloading XAMPP and extracting as superuser, and repeating it all over again every time XAMPP updates to a newer version. No more firing up a terminal and telling XAMPP to start with that horrendously long command sudo /opt/lampp/lampp start. Hooray Ubuntu!

The above steps worked fine for me on Xubuntu 8.04.1.

UPDATE March 23, 2009: I’m on Arch Linux now, and I simply followed the Arch wiki on Apache et al to get things rolling without XAMPP. And it works just fine. Use Arch!

3 Comments »

  1. Followed your recipie and agree with you on this. :)

    Comment by minter — January 5, 2009 @ 7:25 pm

  2. not sure yet..im new in xubuntu.. are the uninstall as easy as the installation

    Comment by pandi merdeka — June 18, 2009 @ 11:35 pm

  3. Like I mentioned in my post, I use Arch Linux now, and have not used Xubuntu for several months. But from what I can remember, the packages should be no different than the other ones in Synaptic — so if you’re good at using Synaptic then there should be no problem.

    Comment by Shinobu — June 19, 2009 @ 3:20 am


RSS feed for comments on this post. TrackBack URI

Leave a comment

Blog at WordPress.com.