raspberry pi

Topics: PHP, IP address, Linux Pages: 13 (2869 words) Published: November 30, 2013
Creating a LAMP server (web server - Linux Apache Mysql PHP) on the Raspberry Pi - Linux tutorial from PenguinTutor

A website of the Watkiss Online Group. Also see the First Aid Quiz Website.


Learn Linux
Learn Electronics
News & Reviews
Learn Linux : 

Raspberry Pi

LPI certification

Linux Tutorials

Creating a LAMP server (web
server – Linux Apache Mysql
PHP) with the Raspberry Pi

Home > Linux tutorials

This provides details of how to configure a Raspberry Pi as a webserver. This is similar to the guide to using Xubuntu as a LAMP webserver, but adds some of the things that need to be handled differently for the Raspberry Pi.

It is termed a LAMP server which is one of the most common configuration for webservers which standard for:
Linux – operating system
Apache – webserver (http) software
Mysql – database server
PHP or Perl – programming languages
This setup is probably overkill for most uses of the Raspberry Pi, but it is the setup that most users will be familiar with and is a good way to learn about setting up a webserver. I’ll be looking at setting up a lightweight setup in future. All this configuration is done at the command line. This may not be quite as easy as clicking a few icons, but it has many advantages, including the ability to remotely manage and install the server. It also means that the computer can spend more of it’s time server up web pages and less processor time drawing a GUI, which is after all the whole point of a webserver.

Why use the Pi?
Avoiding the geeking answer of “because I can” I think
there are some good reasons for doing this.
Learn Linux The main aim of this site is to teach Linux
skills. The best way to do that is to actually do

http://www.penguintutor.com/linux/raspberrypi-webserver[11/30/2013 1:43:50 AM]

Creating a LAMP server (web server - Linux Apache Mysql PHP) on the Raspberry Pi - Linux tutorial from PenguinTutor

something. This is as good a place as any to start.
Learn web programming The aim of the Raspberry Pi
Foundation is to teach programming to children. Learning
to program web based applications can be a useful skill to learn. It’s debatable whether it’s better to learn to program a desktop application before web programming or vice versa, but it’s certainly something that is a useful skill to learn.

As an interface The Raspberry Pi is useful as a device for collecting information from various sensors. A web server can be a good way of accessing that information.
Dedicated network device You could use it as a dedicated network service for the home. Perhaps streaming videos / media etc. .
As a test or development server When creating a web application it is useful to have a dedicated server to test the application on. Ideally this should be identical hardware and software to the production, but if that is not possible then the Raspberry Pi could be an inexpensive alternative.

As a real web server At first I was going to put that it would be silly to run this as a production webserver. Then I thought back to the server I was running my personal blog website on, prior to going hosted in 2007, was not much more powerful than the Raspberry Pi is. It did have a little more memory, but my server was running a full WordPress site as well as some CGI scripts. These days websites tend to include more dynamic content and larger files, but if you are using it for a personal website then it may be sufficient.

Debian Linux
This is based on the Debian Raspberry Pi image from Raspberry Pi download page. To follow this then the Raspberry Pi will need to have an Internet connection. These instructions assume that it is physically connected to a home router.

The first priority is to make the Raspberry Pi a little more secure. The image includes a default username and password, which once connected to the Internet would allow anyone to login and have free roam of the device. To change the...
Continue Reading

Please join StudyMode to read the full document

You May Also Find These Documents Helpful

  • The Cruel Conclusion of Reality in ‘Araby’ and ‘The Raspberry Bush’ Essay
  • Pi in Mathematics Essay
  • The History of Pi Essay
  • History of Pi Essay
  • History of Pi Essay
  • The Number Pi Essay
  • Essay on Pi and Zero
  • Essay on life of Pi: Survival

Become a StudyMode Member

Sign Up - It's Free