Want to get Lullabot article, videocast, and podcast announcements delivered right to your in-box? Let us know your email address (we won't share it) and we'll let you know when anything exciting happens.

Subscribe to our bi-weekly audio podcast - The Lullabot Drupal Podcast, our daily interview snippets - Drupal Voices, our periodic videocasts, or everything. Just choose your favorite podcast-listening application or service and click away!


Install a Local Web Server on Ubuntu

This video will show you how to set up a local web server on the Ubuntu desktop version. It walks through most of the process using a GUI and uses just a little bit of command line to set some things up. I did it this way to make it the most accessible to even new users of Ubuntu. It walks you through installing the needed packages, setting it up for clean URLs and getting Drupal started.

Comments

The List

Hey Addison, nicely done.... Here's a list of packages you installed for quick future reference:

  • Apache2
  • MySQL Client
  • MySQL Server
  • PHP 5
  • PHP 5 - GD
  • PHP 5 - MySQL
  • PHPMyAdmin (in universe repository)

I also like to install CURL as there are some contributed modules out there that use it. A local mail server sometimes helps too. Great quick tutorial, keep it up!

can find my downloads

I down loaded php and mysql and apache.
Only apache downloaded can find the others php and mysql help

nice one and great stuff

thanks for sharing i love this

Tasksel

I prefer using the 'tasksel' program which installs a prepackaged list of application
the commands would be

> sudo tasksel install lamp-server
> sudo apt-get install phpmyadmin

easy as hell..but that indeed only works if all the necessary 'universe' repositories have been setup like you have explained.

As for the post-installation instructions. They come in very handy because they apply to any method used to set up the lamp-server and plan to build drupal sites.

* edit v00-default -> Allow Overide ALL
* enable rewrite module
* chown www folder

Thanks

If a picture is worth a thousand words videos like this are invaluable to the visual learner.

Thanks, good work!!

Another HOWTO

There is a (more copy and paste command-line oriented) HOWTO on the Drubuntu group on groups.drupal.org - see the development server page, or the HOWTO outline - which links to some of the other things commonly set up at this stage.

That said, it is well worth knowing how to use Synaptic, since it is an invaluable tool for general package work anyway, so this is a great resource (and I'll add a link from the Drubuntu wiki!).

Excellent video - many thanks

This is a great video. Thank you very much for your efforts in producing these. Yes, a picture is worth a thousand words, but a video is worth even more.

Keep up the great work!

Packages

In Ubuntu 7.10, before I could add Apache2 I had to turn on 'Canonical-supported Open Source software' myself, as it wasn't enabled by default.

Also, on 7.10 you probably won't see phpmyadmin in /var/www/, however it's actually still there, see http://ubuntuforums.org/showthread.php?t=591952.

Great screencast by the way. :)

Curiosity

What screen capture app was used for Ubuntu to get this MP4 file? Or was this via VNC or a virtualized system that was recorded with a screen recorder in OSX or Windows?

I cheated

I used Parallels on my Mac to run it and iShowU (Mac-only) screencap software to record.

Thanks Addison

Great job on this video cast (and all your others)! It was a huge help.

Excellent

I used this tutorial to set up drupal on a vm using parallels and it worked perfectly. nicely done.

Screencast on linux

get gtk-rekordmydesktop and cinelerra or gmencoder.

Thanks a bunch, I was mystified by that, but now I know, Thanks.

Thanks a bunch Addi!! You're my hero!!

BTW, if you like music videos, I have a site setup utilizing HTML 3,
and the worst HTML coding you probably have ever seen, but
it requires no login or password and anyone can contribute videos with a
few bookmarklets: http://www.chann3lz.com/

Also I found out that spacemonger will run under wine, so if you need to organize space on your server, you can use that..

...

Kiernan: Thanks, didn't know spacemonger ran under wine. http://www.rapidsixpack.com

Thanks Addi! Just a thought for a future tutorial->optimizing your web server setup for optimum drupal perfomance.

sudo apt-get install drupal5

There is one way more easy :

sudo apt-get install drupal5

~$ sudo apt-get install drupal5
[sudo] password for ******* :
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances      
Lecture des informations d'état... Fait
Les paquets supplémentaires suivants seront installés :
  apache2-mpm-itk apache2-utils apache2.2-common dbconfig-common
  libapache2-mod-php5 libdbd-mysql-perl libdbi-perl libnet-daemon-perl
  libplrpc-perl libt1-5 mysql-client mysql-client-5.0 php5 php5-common php5-gd
  php5-mysql postfix wwwconfig-common
Paquets suggérés :
  apache2-doc php-pear dbishell libcompress-zlib-perl mysql-doc-5.0 procmail
  postfix-mysql postfix-pgsql postfix-ldap postfix-pcre sasl2-bin resolvconf
  postfix-cdb postgresql-client apache apache-ssl
Paquets recommandés :
  mysql-server postgresql-8.2
Les NOUVEAUX paquets suivants seront installés :
  apache2-mpm-itk apache2-utils apache2.2-common dbconfig-common drupal5
  libapache2-mod-php5 libdbd-mysql-perl libdbi-perl libnet-daemon-perl
  libplrpc-perl libt1-5 mysql-client mysql-client-5.0 php5 php5-common php5-gd
  php5-mysql postfix wwwconfig-common
0 mis à jour, 19 nouvellement installés, 0 à enlever et 0 non mis à jour.
Il est nécessaire de prendre 15,4Mo dans les archives.
Après dépaquetage, 40,5Mo d'espace disque supplémentaires seront utilisés.
Souhaitez-vous continuer [O/n] ?

You just have to install phpMyAdmin & imagemagick packet and your new Ubuntu Gutsy Lamp server is ready to work...

Quicktime

Hi
I watched this last time on my pc, now I am trying to watch it again from my ubuntu machine and cant get the video to play, any tips?

VLC.

VLC.

multiple drupal dev installs

I plan on breaking things quite a lot... Anyone have any opinions/preferences regarding multiple drupal installs via sub directories vs. the subdomain method Grugnog mentions here? (requires 'Drubuntu' group subscription for access)

another multi-site method

This HowToForge Multisite CVS Drupal Installation looks interesting as well.

Thanks a lot

Really good work. Thx!

now where

once this installation is done how can i create a webpage and host it from my server?

i am new to the whole ubuntu thing

thanks a bunch

is there another tutorial?

also

i am running server not desktop does this change anything?

i have already run this whole tutorial and everything seems as it should

misconfiguration error

i am unable to open any php pages i.e. when i click on phpmyadmin folder i get a misconfiguration error. i have followed the instructions step by step. (as well as i could anyway because i do not hear any sound on the video - although my sound is working fine otherwise... just followed what was happening on terminal).

localhost is working fine, html pages are working as they should.

im a complete ubuntu/linux newbie. please help!

ps: THANKS A MILLION for this video, ur a star!

PHP5 package can't be authenticated and could be malicious!

Great tutorial on using the GUI, indeed!

However, when I chose php5 from the search results in the package manager, I got a strange and scary message:

"You are about to install software that can't be authenticated! Doing this could allow a malicious individual to damage or take control of your system. The chosen action also affects other required packages."

I tried googling for this message but could not get any concrete advice. What do I do and how should I proceed? Should I install A-M-P using the command line? I would rather prefer the GUI.

Has anyone gotten this message on Ubuntu 7.1?

how would i make mail server on ubuntu???

i have project on installing apache web server on ubuntu and also mail server, i am getting difficulty in preaparing it please help me!
please give step by step solution i am new to ubuntu

Internet routing

I'm using my ubuntu box as an internet router for 2 other pc's. I want to use it as a web and mail server too. After i followed the tutorial and restarted the pc once, the internet sharing stoped working. The other 2 pc's can ping the server, can access the webpage but there's no internet sharing :(. Can anyone tell me how to resolve this problem? (I'm new to linux and this stuff, so be gentle on me :) )

phpmyadmin didn't end up in the right folder

and i can't get into it through localhost. =\ When i try to move it from the etc folder to the apache folder, it tells me i don't have permission.

obviously, I'm new. :) can anyone help?

downloading problem

thank you for the great video!

but for some strange reason i can't download the file, only stream it in ubuntu(firefox+totem).
this drives me _absolutely nuts_ !
the download link gives me only a "waiting for www.lullabot.com"....

maybe something is not working on your side (modules/settings??)?

keep making more of those please :D

fire up a terminal, and

fire up a terminal, and type:

wget http://www.lullabot.com/files/ubuntuLocalhost.mp4

Excellent

Thanks for a great tutorial! been getting stuck on this for a while and now everything's up and running!

great post

this is an excellent video I appresiate your help

thanks for guideline

thank you fir helping to install local webserver

Hardy Heron

This method works fine in Ubuntu Hardy Heron.

Problem: different setting for latest UBUNTU (hardy)

Hi..Thanks to the video, anyway different thing goes to ubuntu 8.04. the problem is the permission..is there anyway i can change the permission of the directory?
i've change the www ownership but when i install drupal and installation goes smooth, the files directory is not found and i make one. but after that, i refresh and it says the files directory is not writable. i installed drupal 5.7. Drupal 6.2 also dont work (this the first one i install)
help me out ok..thanks..

Apache 1.3 ??

Hi, I love his screencast, but how can I go about installing an Apache 1.3 Package on Ubuntu 8? I am very new to Linux and could use a little help. Thanks.

Great Video Cast for folks from Microsoft camp

HI Addison,
Great job, I think your video cast will give me adequate information to transition a web site from IIS to Apache. I am fairly new to LAMP, so far I have been impressed by Ubuntu. I still struggle with the various LAMP terminology, file organization, where and what issues.
I wish there are more targeted and well defined type of video casts like yours out there.
Again thanks.

thank u

I really want to thank u :)

streaming server

can this web server use as a streaming server?

it works

it works for me thanks and make more of these will help newbies like us :P

Nice Work,

Thank you for this nice video.

Thanks

Thanks for taking the time to put this together, this is exactly what I needed spoon fed to me in a 12 minute tutorial! You have a nice voice too.

thanks

thanks

Thank You

Many thanks for the video, it's very useful!

folders missing from www

that's right.
in my /var/www folder, there is only that index.html file
but phpmyadmin folder and the apache one are missing
can anyone help me with this
I've ubuntu 8.04 installed and I'm an absolutely noob

way helpful

this is way helpful. thank you! you have eliminated the entry barrier!
pb

Missing folders

Great tutorial, but after completing all the installations from package manager i go into the folder /var/www and the 2 folders that are suppose to be there as per the video are not, and all i have is an index.html file that says 'It works' when loaded.

Where have i gone wrong, where are the folders?

thanks

Ubuntu 8

for those with a problem with Ubuntu8.04
" /var/www folder, there is only that index.html file
but phpmyadmin folder and the apache are missing"

Take a look at the thread linked below.
It worked for me.

http://ubuntuforums.org/showthread.php?t=591952

wow thanks

it works for me thanks and make more of these will help newbies like me.. thanks alot

Database

Thanks for this great tutorial. Now I just need to know which option to select when setting up my database under the Collation option. There are many choices and I don't know which one to pick???

Jugney

How to check if php and my-sql status

for those having problem with php just go to your http://localhost/phpmyadmin/
or what ever your local server ip is eg 192.168.1.101, if your see the page ur database is install correct other wise you will need to sudo apt-get install phpmyadmin to reinstall or sudo apt-get update so an so

more php memory

great tutorial I just used it and everything worked with ubuntu 8.10.

I think you should advise people to go into php.ini and up the memory limit from 16 to much more (I use 96) since adding some modules will bomb it out ...

sudo gedit /etc/php5/apache2/php.ini

search for memory_limit change from 16M to more ...

Thanks again

Is there a solution to send

Is there a solution to send out the mail? I'm working on a project where I need to test emailing feature. Any help is greatly appreciated. Thank you.

thanks

I was stumped. Your video unstumped me.

work

nice its works

works great

Thanks, the clean URL and permissions chapter helped me

Thank you

Hi

Just want to say this video was very helpful, I had a little problem as some files downloaded in different locations on my system. I ended up messing the whole permissions of my install, but finally founnd a simple symlink that sorted all the problems!

Thanks to this tutorial, the Using Drupal book and alot of very kind people in the Drupal community I've finally finished a Handmade greetings card site this week - Giftuser Handmade Greetings Cards

Great tutorial Thanks Addison

great tutorial

Normally I would just use taskel to install a lamp server but I was looking to get a little bit more into how those packages were actually working together, this tutorial provided me a great opportunity to do that, a lot better than I would have expected.

I got a little caught up trying to get apache configured correctly, but it wasn't something that a quick google search didn't fix up for me, everything was really well put together.

Thanks for the resource,
~http://yelirekim.com

P.S. The video is a little low-q now though, you could update the posting with some better quality sometime, keep with the times!

Still couldn't get PHPmyadmin to load up

This is a great tutorial, but Firefox will not show me the PHP code that appeared when you accessed the folders. Also, PHPmyadmin doesn't show up. It just appears in the gedit screen any ideas?

Skills -->you got 'em

Thanks for the tutorial. Well thought out video. Clear. Very Easy to follow and you have a great voice to boot.

Now I'll see what I can do with your starter help.

Excellent Video Thanks

Very clear and informative guide. Thank you.

Thank you for your helpful

Thank you for your helpful post. If you want to teach your child responsibility, web installing a local web server is a great way to do that.

mail server

i have project on installing apache web server on ubuntu and also mail server, i am getting difficulty in preaparing it please help me!
please give step by step solution i am new to ubuntu
plese replay as soon as possible
i need it fast solution..........plese

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <blockquote> <h2> <h3>
  • Lines and paragraphs break automatically.
  • Use <!--pagebreak--> to create page breaks.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.
  • Web page addresses and e-mail addresses turn into links automatically.

More information about formatting options