How to use LAMP for PHP development for UBUNTU

Shelldon

Active Member
Joined
May 30, 2012
Messages
53
Reaction score
0
Hi guys. I'm busy banging my head against a wall here.

I've installed UBUNTU 16.04 LTS off a disk and replaced Windows on a Compaq laptop; everything works as advertised and no complaints. Except...

I'm busy developing a website on a 2nd laptop (Windows and xampp) and would like to move development to Ubuntu. Here's the problem... loads of tutorials about installing LAMP onto a Ubuntu machine, but nothing much on how to actually develop.

I followed instructions and installed LAMP, but for the life of me cannot get anything running (php, mysql etc). Does anyone here develop websites (php) using LAMP?

Perhaps someone knows or a tutorial online that gets a "hello world" up and running.

Thanks
 
sudo apt-get install apache2
sudo apt-get install mysql

Alternatively, on the initial install, just select LAMP server (or webserver, can't remember now) then it's all setup automagically.
To do that, download ubuntu server and if you want a GUI later:

sudo apt-get install lubuntu-desktop

You can choose your preferred desktop, there are a few but lubuntu is nice and lightweight for just a pure dev machine.
You'll need a decent terminal like Guake or something.

Edit: If you've done something like the above, your configs are wonky and you'll need to dive into logs.
 
Last edited:
Depends on which tutorials you followed boet

And we can't help you develop. You have to do that yourself. So I'd say use Nano?

It's piss easy getting these things up and running (flippakitten forgot to mention to include PHP in the install). You'd have to start the web server manually (unless whatever tutorial you followed showed you how to start/enable on boot it)
 
Depends on which tutorials you followed boet

And we can't help you develop. You have to do that yourself. So I'd say use Nano?

It's piss easy getting these things up and running (flippakitten forgot to mention to include PHP in the install). You'd have to start the web server manually (unless whatever tutorial you followed showed you how to start/enable on boot it)

Good point.

Probably better then to download uBuntu Server Edition, there is an install option for LAMP which works off the bat, no issues.

When I say no issues, what I mean is you're going to have to patch all the security holes but if it's only local, no need to worry about that.
 
Hi guys. I'm busy banging my head against a wall here.

I've installed UBUNTU 16.04 LTS off a disk and replaced Windows on a Compaq laptop; everything works as advertised and no complaints. Except...

I'm busy developing a website on a 2nd laptop (Windows and xampp) and would like to move development to Ubuntu. Here's the problem... loads of tutorials about installing LAMP onto a Ubuntu machine, but nothing much on how to actually develop.

I followed instructions and installed LAMP, but for the life of me cannot get anything running (php, mysql etc). Does anyone here develop websites (php) using LAMP?

Perhaps someone knows or a tutorial online that gets a "hello world" up and running.

Thanks

You just gotta love geeks. Guy ask a simple question...and now they want him to download ubuntu server edition.

Sheldon: I 'm no geek but is easy by just following this.

Remove everything that you installed.
Download simple lamp installer from here --> https://bitnami.com/stack/lamp
Install it and start your servers (just like in windows) from your lampstack folder in /home. Click on manager-linux
Put your stuff in apache2 - htdocs

done.
 
If you're not comfortable with manually installing the packages then simply do the following at the terminal:

sudo tasksel
Select LAMP

Setup your sites in /etc/apache2/sites-available/
Enable your site with a2ensite yoursitename (as used in the sites-available folder)
 
Thanks for everyones replies.

@jsheed_sa when I use the command "sudo tasksel" I get the error command not found. Does that mean I've installed something incorrectly? I did install using "sudo apt-get install lamp"
 
You just gotta love geeks. Guy ask a simple question...and now they want him to download ubuntu server edition.

Sheldon: I 'm no geek but is easy by just following this.

Remove everything that you installed.
Download simple lamp installer from here --> https://bitnami.com/stack/lamp
Install it and start your servers (just like in windows) from your lampstack folder in /home. Click on manager-linux
Put your stuff in apache2 - htdocs

done.

you Sir, are a star! I've downloaded and installed it. Haven't had a chance to test it just yet, will do so tomorrow. But I'm certainly further now than I have been! Thank you!
 
My favourite is still Vagrant Homestead. I've messed up Linux so many times installing LAMP. Vagrant Homestead basically runs little ubuntu SSH Virtual Machines on your computer (supports Windows/Linux/MacOS) for development. Think it's got both Nginx and Apache.
Will save you headaches in the long run. :)
 
My favourite is still Vagrant Homestead. I've messed up Linux so many times installing LAMP. Vagrant Homestead basically runs little ubuntu SSH Virtual Machines on your computer (supports Windows/Linux/MacOS) for development. Think it's got both Nginx and Apache.
Will save you headaches in the long run. :)
+ one for vagrant.


On the other hand op.

Download wampserver on windows easy easy.
 
Otherwise install apache mysql and php you already have the L


Then in the www folder will be local host where you save everything website related.
 
My favorite is Turnkey Linux

https://www.turnkeylinux.org/
basically LAMP or whatever your desire: drupal, joomla, all the common PHP frameworks, set up for you in separate appliances ultimately to run as Virtual Machines. So no need to brick your host OS.
 
Top
Sign up to the MyBroadband newsletter
X