Installing XAMPP Lite on a Portable Storage device
One of the fastest and best way to get a PHP server environment up and going is to use XAMPP. What is XAMPP you say?
Put together by the folks at Apache Friends, XAMPP is an installer package containing the Apache Web Server, MySQL, PHP and Perl. XAMPP takes away the hassle and headache of installing and configuring each of the parts individually. But best of all – It FREE!
XAMPP is currently available in 4 distribution packages, but the one this post will cover is XAMPP for Windows.
XAMPP for Windows is available in standard full edition, or a ‘lite’ version. Since we only need the bare necessities to get a PHP environment going, we’re just going to focus on installing the XAMPP Lite version for Windows onto a portable storage device. Frankly, the full edition includes a bunch of stuff you probably won’t need yet, whilst you’re picking up PHP.
By putting XAMPP onto a portable storage device, like a thumbdrive, or a portable HDD, will make the whole environment portable. You can take it anyway with you and plug it into any Windows PC/Notebook and you can carry on where you left off. It’s great for those of you who have more than one PC/Notebook, which you use regularly.
You can of course, choose to install a XAMPP with the installer version. You can find out how to do it by following the ‘Installation with Installer‘ guide at the XAMPP website.
Without further ado, let’s get started.
1. Go grab a copy of XAMPP Lite from Apache Friends.
- Visit http://www.apachefriends.org/en/xampp-windows.html and click the link as shown below.
- You’ll need to choose the option for ZIP.
- The EXE version is an executable installer which will install XAMPP Lite on your PC/Notebook. XAMPP will not be portable if you use the EXE version to install.
2. Installing your XAMPP Lite
- While XAMPP is downloading, go and prepare your portable storage. In my case, my portable HDD is identified as F: drive. I intend to put my XAMPP Lite into the F:\ root folder.
- Once downloaded, open the ZIP archive into a folder of your choice on your portable storage device. In my case, I would just extract to the F:\.
- Once extracted, there should be an ‘xampplite’ folder where you have specified as your destination folder path.
- In my case, it would have unpacked into the F:\ and created a ‘xampplite’ folder (F:\xampplite)
3. Setup the XAMPP Lite.
- Run the setup_xampp.bat file.
- This will configure all the necessary setting and filepaths automatically. Press any key to continue after that.
4. Starting XAMPP Lite
- Run the ‘xampp_start.exe’ file.
- This screen will appear, to show you that Apache and MySQL are running.
- Open your browser, and type ‘http://localhost/’ into the address bar.
- After choosing your language of choice, you’ll end up on this page.
- Well done, you’ve successfully got your XAMPP Lite going…
5. Stopping and Restarting XAMPP Lite
- To stop XAMPP Lite, double-click the ‘xampp_stop.exe’ file to stop the server running.
- Sometimes, you might need to stop and start XAMPP, use the ‘xampp_restart.exe’ if you need to restart your server. Normally, this is required after configuration changes.
Well, that’s it. Hopefully you managed to successfully get your XAMPP environment going. I’ll post more articles later on how to use the XAMPP environment.
In: PHP Tutorials · Tagged with: Apache, Guides, How-to, mysql, PHP, XAMPP Lite












Permalink
This is a great article.
Here is a Video Tutorial with instructions on setting this up.
Permalink
hi, great article, recently I found nice php utility to manage projects hosted on Xampp. This utility can allow / disallow Apache’s virtual hosts and even manage them. Its called XamppContent and you can find it here: XamppContent
Permalink
Cool article, I had always wanted to do this, but wasn’t sure how it would be possible with services and such; never knew about XAMPP Lite. Only problem is, how can I overcome the fact that every computer will map the drive to a different letter? My laptop wrote all the directories in the configuration files as ‘E’, so my other computers couldn’t get them because they saw the drive as ‘F’ or another one as ‘H’. I feel I will have to make a small program to replace all these letters in the config files…
Permalink
Hi Michael, what I do is to standardize the drive letters, e.g. i just make sure all the different computers i work on assign the ‘M:’ drive letter to my maxtor external hdd.
this is probably the easiest approach, just assign the letter you want in “Disk Management” under “Control Panel -> Administrative Tools -> Computer Management”
Permalink
can i install xampplite on my 4gb USB FlashDrive? thanks..
Permalink
Hi Loid, yes, it works the same way.
Permalink
I’ve followed your directions on this page for installing xampplite on a portable device but when trying to start apache I get the following error: ‘Only one usage of each socket address is normally permitted. : make_sock: could not bind to address 0.0.0.0:80 no listening sockets available, shutting down. Unable to open logs.’
What can I do?
Permalink
Hi Rob
That means that you have another program that is using Port 80 which is clashing with xampp. You can either modify xampp to run on another port or you can find what is the other program that is using Port 80.
Typically Port 80 is used by web servers. Its highly likely you have Microsoft IIS turned on in your Windows installation. You can check if this is so by typing “http://localhost/” into your browser to see if other webserver services are runing on your machine.
Check out this blog on how to change the default port on XAMPP if you prefer to take this route. http://veerasundar.com/blog/2009/07/how-to-change-xampp-server-port/
You can check out this XAMPP faq for more actions you can take.
http://www.apachefriends.org/en/faq-xampp-windows.html#nostart
Permalink
Fixed error “Only one usage of each socket address is normally permitted”:
I found i had more than one instance of apache.exe running in memory even though the xampp control panel showed it was off. I dont run a service unless it doesnt work – ie standalone. Hit ctrl-alt-esc – under processes tab click image name to order by name, look for any apache.exe programs – end them all and retry – should sort you out
when i doubt – restart. if still in doubt, google it.
Permalink
when i tried to run the setup file it i get an error message saying that permission was denied. can anyone help me? here is a screen shot: http://grab.by/pgS
email me at wraithstk@gmail.com
Permalink
hi Dan
I’ve no idea why you would get permission denied. Are you using Windows Vista? If you are, maybe you an execute the setup in WinXP mode? Sorry, not much help here.
Permalink
Very helpful, runs perfectly on my external HD.
Thank You, that´s a great tutorial!!!
Permalink
Well, I give up. I can’t even get the program downloaded. I’ve tried Imapp lite, regular, self-extracting, and the .zip file. I’ve tried using direct, using mirrors, going straight for the source and I always get the message that “Firefox has detected that the server is redirecting the request for this address in a way that will never complete.” I do accept cookies, so don’t understand what the problem is. I even downloaded an older version from another website, but when I clicked on the zip/exe file I was told “Error – does not appear to be a valid archive.” What the heck am I doing wrong?
Yes, I have Vista SP2, but since I haven’t even loaded anything yet, figure I’m not dealing with the next set of problems detailed in the documentation re permissions.
Then I got confused when Apache’s site said “If you choose a root directory “C:\” as target, you must not start “setup_xampp.bat”. No other websites, including this one, say any such thing. What are we supposed to use then? Jeez, if I can’t even get this far, I can’t wait until I download Wordpress…
Permalink
Thanks a lot…..i could install xampp successfully….
Permalink
if i want to connect with mysql database what port no. is to be used for localhost?? i tried using default value:3306, but it’s showing error, it’s not getting connected.. plz help. Thnx in advance.
Permalink
[...] Зроблено на основі допису Installing XAMPP Lite on a Portable Storage device [...]
Permalink
Thanks
Permalink
Thanks, it works on my usb!
Permalink
THANKS!!!..it finally worked
Permalink
[...] Xampp Lite – http://www.askaboutphp.com/7/installing-xampp-lite-on-a-portable-storage-device.html [...]
Permalink
Hi, thanks for this tutorial , it is great!
I installed xampp (full version not lite) on my portable storage drive (G:), it works perfectly with a pc without install any xampp. But when I use it with a pc which already install xampp on it (C:), I can’t open the (G:) drive.
It seems pretty easy to solve but I can’t figure out the solutions :S
Permalink
I’d like to ask you guys a question: if I run Xampp on a USB drive on my computer at work, will it leave any traces into the desktop computer?
cheers,
BobR
Permalink
When I downloaded Xampp Lite there is no set-up bat file and when I run xampp control i can’t start Apache.. I don’t even get the green ‘running’ indicator