You are on page 1of 11

Make your own web-server Step one Find, download and install VMware player.

Step two Find, download and install Ubuntu through VMware player I gave mine the following settings

but honestly, Ubuntu is pretty lenient with that sort of thing, I would give it minimum 512megs of ram, 2 cores of CPU, 10gigs of HDD, BUT THE MOST IMPORTANT THING TO REMEMBER TO DO IS.....Make sure you have set the network settings exactly like mine up there so for those who cant see the picture, make sure your network connection is on bridged and then on replicate, this is very important like you would not believe I will explain later on in the article. Also when Ubuntu asks for you to set a password, make it something easy to remember and something you can type fast, because you will be typing it in A LOT. Step three Follow how to geek's article to on how to install LAMP he wrote it really well and theres no point me plagiarising it so here it is after you have done what he says in the article and all of his checks come back successfully continue to step 4

Step four for the next bit ill be ripping slightly modified instructions off this website and putting them up here, now im not doing this just to plagiarise but they gave me a little trouble so im giving you my working ones copy paste the following into the command line
# Change for new version SOURCEPKG=Joomla_1.5.14-Stable-Full_Package.tar.bz2 SOURCEWWW=http://joomlacode.org/gf/download/frsrelease/10785/42653/Joomla_1.5.1 4-Stable-Full_Package.tar.bz2 # Get it mkdir joomla cd joomla wget $SOURCEWWW # Unpack it tar xvjf $SOURCEPKG # Cleanup rm -f $SOURCEPKG # Move cd .. sudo mv joomla /var/www/

Ok what that does is finds, downloads and installs the joomla 1.5.14, joomla is the CMS (content management system) that makes managing a website almost infinitely easier and yes, I know that there is a joomla 1.6 out so this isnt the latest version but almost all my instructions in this article will apply to it aswell. And im using 1.5 because atm more extensions work on it and 1.6 broke backward compatibility.
# A. Quick but less secure. Allow writing in whole joomla subtree sudo chown -R www-data:www-data /var/www/joomla

Ok what that does is gives you access to change files in the joomla folder that Joomla extracted and installed to using the first bunch of code I gave you. Its not overly secure but if you are asking for my help then chances are your not going to be the target of hackers and this guide doesnt even allow external access to the web-server anyway so your all good.
cd /var/www/joomla sudo find . -type f -exec chmod 644 {} \; sudo find . -type d -exec chmod 755 {} \;

I dont really know what the above code does but put it in anyway, (from what I can tell its changing the permissions/way something executes in the Joomla folder now configure MYSQL and Apache according to this website's instructions. That website also tells you how to install through your browser but a slightly more up to date guide of the same thing ill be using here. But dont do anything

yet.

Step five ok prepare yourself, as soon as you get to this screen refer back to this guide

Now follow this guide written by the people at Joomla themselves! And one thing, I dont care if they say its ok that you cant write to your configuration.php file that's not a good thing, that took me A VERY LONG TIME to figure out how to fix. I ended up starting from scratch because I couldnt fix it in that installation, perhaps you will have better luck than I if that's your fate but anyway. Im pretty sure you can use CHMOD to get the file in there somehow. Now you should be up to step 3 of that Joomla guide thing and looking at a very similar screen to the one shown above see where it says Admin password: thats the password you will need to login to your website the username by default is created as admin, and then what you enter int hat field above is the password. Ok now if everything is all peachy so far you should be able to go to the following link http://localhost/joomla if that loads up properly you have done everything correct up until this point in time now go to http://localhost/joomla/administrator if that too loads up, enter in admin for the username and whatever you set as your password as mentioned above. (localhost can and probably should be switched out with the virtual machines local IP instructions on how to do this will be mentioned later on in the guide) If that works Congratulations you now have a working web-server, that so far only your virtual machine and the physical machine its hosted on will be able to see. If thats fine with you then stop reading now because here comes the hard

part. What we need to do from here is set up a static IP address so you can access the machine using the same IP everytime, this is important.

Step six Read this guide by liberian geek, dont do any of it yet, but just try and understand what he is doing, the exact way he did it is not for everyone. Once it all makes sense to you (AGAIN DONT DO ANY OF IT YET) then continue into this guide. First of all, go back into windows and bring up the CMD type in ipconfig look for the network device you are using (i.e. if you are using wireless look for something wireless, if you are using wired look for something wired) as you can see below my IP address is 192.168.0.15 now yours will look similar to that, your DEFINATELY have 192.168. at the start of the address only the last 2 numbers (the 0.15. in my case) could be different to mine. If the second last number in your IP is different to mine (second last in this would be 192.168.y.1) then use that second last number in your virtual machines IP when you type it in, so so far your virtual machines future IP address will be 192.168.y.x. (where y is the same digit as your windows ip address and x will be discussed next)

Now think about what you would like your permanent local IP for your virtual machine to be, (I found using this configuration worked for me 192.168.y.x where x is the number you decide) I recommend a number greater than 50 (i.e. 192.168.0.51) just to be on the safe side then ping whatever address you come up with through that CMD (this HAS to be done in windows) if you dont get a response from the ping/you get request timed out then that means the address is free and you can use it. If you do get a response try the process on a different IP until you find one that is free. Once that is done set your netmask and gateway as liberian geek did it, when it comes to DNS servers run the following command in your virtual machines terminal sudo gedit /etc/resolv.conf A notepad style editor should come up with some name severs on different lines mine looked like this

put all the numbers after the word nameserver into the DNS field of the thing liberian geek was in,

copy paste them all separated by commas (so in my case it would look like 211.29.132.12,198.142.0.51,211.29.153.116 yours will probably look

different but be in the same syntax) once you have done that save and quit everything and reboot the virtual machine. When Ubuntu loads back up right mouse click the little network indicator on the top bar it should look like two arrows one pointing upwards, one point downwards and then click the option that says connection information

that should come up with a screen with your network stats, if the one that says IP address has the IP address you configured then it would seem as if you have done everything up to this point correctly, try accessing your web-server on other computers using the following format YourIpAddress/joomla if that works than you have successfully created a LAMP based web-server on a virtual machine using Ubuntu that you can access using Joomla. And now you can write that on your resume! Step seven ????????????????????????????????????? Step eight PROFIT!

Random Tips and shit to remember if after you restart your virtual machine you are unable to access your website because it could not connect to MYSQL try going to http://localhost/phpadmin, if that also cant connect to MYSQL open up terminal and type the following sudo gedit /etc/mysql/my.cnf Press control + f and type in bind-address if it says anything other than 127.0.0.1 change it to 127.0.0.1 if that doesnt fix it your fucked when joomla wants you to delete your installation folder all it really want/checks if if /var/www/joomla/installation/index.php exists, if it doesnt say because you renamed it instead of deleted it then you can continue on without issue control + alt + t opens terminal in Ubuntu if you accidentally resized the VMware player go into Ubuntu up the top click system then preferences and then monitors and change the resolution to 800x600, this will be its size when not maximised, when its maximised it will use your native resolution I cannot stress this enough MAKE SURE you have set the virtual machine's settings in VMware player for the network adapted to bridged and then replicated like I said in step one

Sources http://www.howtogeek.com/howto/42480/how-to-turn-your-home-ubuntu-pcinto-a-lamp-web-server/ https://help.ubuntu.com/community/Joomla#Download%20Joomla! https://help.ubuntu.com/community/Joomla#Configure%20MySQL https://help.ubuntu.com/community/Joomla http://help.joomla.org/content/view/39/132/ http://www.liberiangeek.net/2010/09/setup-permanent-static-ip-addressubuntu-10-0410-10-maverick-meerkat/ http://www.jonathanmoeller.com/screed/?p=2305

You might also like