People are doing a lot of cool things with the Raspberry Pi. One of the first things I thought to do was to see if I could make a Raspberry Pi web server. Being a web developer and overall geek I figured it might be kind of fun to do, and as I found out it’s really easy.
Getting Started
The first thing you want to do is get the Raspian Wheezy Image from here. As you probably guessed this is a custom Debian image for the Pi. Once you install it and boot up, you’ll come to a configuration screen that looks like this:Setting up a Web Server on this device really isn’t much different from any other Linux machine, but there are a couple things you’ll want to do in order to get it working right.
The Raspberry Pi has a “memory_split” option that divides the memory between the CPU and GPU (Graphics). Since we’re using this a webserver we don’t need that much GPU memory so change it to 16M:
You may want to also enable the SSH server if that’s how you’re going to be accessing the device. There are other options there you can adjust, including overclocking.
Note: You can overclock this device, but I wouldn’t recommend it. With a web server setup like this you’re not going to see any real gains, but you’ll be reducing the life of the CPU and creating instability. It’s not worth doing for this setup.
After you’ve saved your settings reboot the device. Now you’ll want to update your firmware and software. The first thing you’ll want to do is get Debian up to date:
Next we’re going to do a firmware upgrade, we need to install git:
then download the firmware update and run it:
After the firmware update completes, you should see something like the following:
If you didn’t see any errors, reboot the device.
Change the default password, especially if you’re going to be connecting this to the internet:
Install the web server software
Now that everything is up to date we’re ready to install the LAMP stack. This is really no different from any other Debian web server setup:
Install Apache and PHP:
Install MySQL:
Then make any changes you need to the Apache configuration and restart:
If you want to take a look at your PHP configuration, create the following file:
Inside that file put the following code:
Save it, and load it up in your browser, it should look something like this:
You’re ready to go!
Summary
This isn’t too much different from any other web server install with a few minor tweaks, and updating the device. But I thought I’d share it for those willing to try it out. This is for hacker fun only, I wouldn’t recommend using this for any real commercial website but there’s plenty you could do with this as a webserver just to experiment and play.
On the other hand I haven’t really tested it thoroughly it might be a decent option for hosting smaller sites for all I know. It might be a fun experiment to set up one as a web server, one MySQL, one Varnish, etc. and throw some traffic at it. I’ll be doing some other cool experiments with this device and documenting it here. I love hearing feedback so if you have any questions or comments send them my way!
I was searching for loan to sort out my bills& debts, then i saw comments about Blank ATM Credit Card that can be hacked to withdraw money from any ATM machines around you . I doubted thus but decided to give it a try by contacting {skylinktechnes@yahoo.com} they responded with their guidelines on how the card works. I was assured that the card can withdraw $5,000 instant per day & was credited with $50,000 so i requested for one & paid the delivery fee to obtain the card, i was shock to see the UPS agent in my resident with a parcel{card} i signed and went back inside and confirmed the card work's after the agent left. This is no doubts because i have the card & has made used of the card. This hackers are USA based hackers set out to help people with financial freedom!! Contact these email if you wants to get rich with this Via email skylinktechnes@yahoo.com whatsapp/t: +1(213)785-1553
ReplyDelete