Above: A picture of the server you are viewing this Page on. Not a whole lot of wires there. Power and Ethernet is all. The other cable is an USB from the hub. It back-powers the RasPi through the lower USB port.
What is installed on this server:
This server is a standard LAMP install
- Raspbian, Full, Linux
- WP Fast Cache
- Ban hammer
Additional installed packages:
- fail2ban ; login failure bans
- php-apc ; php cache
- xrdp ; Remote desktop package.
- Raspberry Pi Rev. 1.0 board modified. Pin headers at USB polyfuse F3 replaced with 1.1A. F2 jumper, F1 replaced with 500ma. Back-powered.
- 16GB SanDisk class 10 SD card.
- Adafruit power Adapter. Modified USB removed wired to pin connector. 110V power cord soldered to board.
- Leviton inline rocker switch in 110V cord.
- 512MB USB stick as dedicated swap disk.
- RadioShack project enclosure.
- Adafruit board edge mounts (7).
There have been several things I have learned about WordPress when used on a Raspberry Pi.
- There is no difference in performance between a 256MB and a 512MB
- Administrative functions were real slow, much better after php-apc installed!
- Updating to the latest distribution improves performance.
- Overclocking helps some.
- You can use a WordPress RasPi in X, but you have the stop Apache2. X works in RDP just fine.
- A faster SD card does help performance.
- WP Fast Cache improved performance. converts pages to static.
- Moving rootfs to a USB stick did not help performance.
- Actually MySQL does not seem to be the problem. Splitting the database away from the webserver provided very little performance advantage. I only gained .2 seconds page serves and .3 seconds for page updates. Might be worth the speed if you need every little bit.
- Use only the WordPress widgets that you need.
Themes can cause their own problems. My current theme does not work perfect on my iPad. Recent theme update did help some what.
Some things that I might try to gain performance:
1. Move WordPress to a USB HDD or a USB stick.
My Lapdock which runs from a USB HDD appears to have better performance than SD based RasPi. OpenElec also seems to perform better when ran from a USB stick. So I believe it might well be worth the move.
2. Separate the Database onto another RasPi.
This would allow one RasPi to process database requests while the other handles the website. I have looked into this but frankly I am not certain I can separate the database successfully. It might be easier to build a new OS with the database separated. There might also be a benefit in moving MySQL over to a stick and leave the rest on SD card. Same reservations as above.
3. Move to a stripped down, server Raspian.
Reduce the number of files that are on the SD card for better access times.
First Steps: 7/16/13;
Hardware complete. I have two RasPii assembled in to a VESA Stack. Both of these Ver. 1.0 boards have been modified to use Back-power through USB Both have had their USB ports removed and replaced with pin headers. Both have had F@, the lower port, polyfuses bridge with a solid wire. they will both be placed onto a switch Ethernet hub together.
The Lower RasPi is powered by the USB Hub upstream port. The upper RasPi is powered from a port on the hub. They have been tested, to make sure that both RasPii, will complete boot simultaneously without causing a power issue.
The 512MB RasPi will be carrying the server while I am testing out splitting the database onto the second RasPi.
I will most likely start fresh with both SD cards. I will load MySQL onto the upper RasPi. And everything else onto the lower RasPi. Then I will have to rebuild the WordPress Pages from copies. Then I will have to load the pictures for those pages back into the database. I will also have to rebuild the user DB but there are only 6 Users in there anyway. Most people look but do not join the blog. The lower RasPi will be the one at port 80. The upper board will be at a static internal address So I am basically combining #2 and #3 above. We will see if it has any real benefit! So a lot of work to do!
I still am trying to get SQLite to talk to WordPress. I just have not got PDO to work, so I will try one of the other SQLite plugins next.
I was able to get WP Fast Cache up and working on this site. I do see an improvement in page serve speed. I cleaned out my internet cache and still see the speed. WP Super Cache just did not want to work. Now that I have WP Fast Cache working maybe I have cleared up what appeared to be similar issues with it. The problem I see with both of these is that they create static pages from the WordPress dynamic pages. This means that when I update a page I will have to remember to update the Cache also.
I created a copy of my WordPress site on my Panda Board.
The install experience was not as easy as installing a WordPress site on the Raspberry Pi. After downloading the Ubuntu server for OMAP, I had to dig around and find my USB to RS232. After I connected my Netbook to the Panda Board I then had to remember how to get minicom to talk to the board. Then use a text only install to get the Ubuntu server installed onto the 8GB SD card. At this point there was one time savings. Ubuntu asked if I wanted a full LAMP install. I said yes and entered whatever user names and passwords it asked for. I also had to install openssh as SSH is not installed or enabled in Ubuntu. This is only necessary if you want to use SSH to work from your primary PC rather than over serial or directly on the Panda board with a monitor and a keyboard.
The WordPress install was exactly the same as on the Raspberry Pi. I actually used the same directions and commands. I also had exactly the same problems as on the RasPi. MySQL permission errors that had to be cleared up and permissions in /var/www/wordpress so I could install or delete themes. I expect I will have trouble enabling WP-Cache as well due to .htaccess.
The page publishing is about one second versus 3.5 seconds for the RasPi. Page serves are also about one second versus 3 to 4 seconds on the RasPi. I have not added the pictures to the copy yet, so I only tested pages that were text only. The difference is 1/3 time or less on all operations. I might have to buy a Beagle Bone Black and see where it falls, since it is more a competitor, than a board that costs 5 times more. The operation of these servers depends only on the ARM processor and the memory. The GPU’s are not used at all to operate a web site.
Note: I have not turned on WP Cache as yet either!
I thought the Panda Board would use more wattage than the Raspberry Pi. This turned out to be not true. Now remember that I use a back-powered RasPi as my web server, so that hub uses up a little extra wattage on its own. The RasPi uses 6 watts and the Panda was at about 5 to 6 watts at boot and operation. very nearly the same power usage for the same job.
NOTE: I use a kill-a-watt meter and test the power supply and the board as a unit. This meter does not show tenths of a watt.
You get 1/3 the page serve speed with the Panda Board versus the Raspberry Pi. But this really is an apples to oranges comparison. The goal was not to see if the Panda Board would beat the Raspberry Pi in a processor to processor shootout, That was a forgone fact. The test was if a dual core 1GHz board with 1GB of memory (really only uses 740MB) was really worth the 5x price.
If you were running a moderate traffic site and could afford the Panda Board as a low wattage server board, then yes it does have the performance. For a low traffic site, like I have, there really is no need to blow the extra money. I suspect the Beagle Bone Black would also be a good alternative if you need a low cost, low wattage server package. I also suspect it is about midline between the RasPi and Panda for server performance. And it fits in your pocket just like a RasPi. The Panda Board doesn’t.
The Panda Board takes a little more experience to setup as there is nowhere near as much information available to get you through the process. If I had not already set up a RasPi as a WordPress server (several different times(and ways) now!) I would have really been struggling to get it done. In fact there were no direct tutorials that I could find. To setup WordPress on the Panda Board, I used tutorials for the Raspberry Pi! I did find a tutorial for installing Ubuntu, so that along with the RasPi tutorials got the job done. I think this would be the same for the Beagle Bone Black.
The RPi “community” does make a real difference in the success in carrying out this type of project!
Just turned on WP Fast Cache Now page serves on the Panda Board are about 1/2 to 3/4 of a second. Real fast.
Converted my server to 110V power. Basically installed the server and the PSU into the same box, then ran a 100V cord into it. Here
Copied the web site to a USB stick. The results of testing showed the same if not slower page serves. Then I installed php-apc a caching utility for php. It appears to have cut my page load times to about 1/2 of what they were.
Installed Synaptic package manager. Used along with xrdp it is easy to use remote desktop to remove and install packages onto the server. Used Synaptic to remove some unnecessary pages. This slightly reduced the memory usage of the server. Total memory usage is 211MB with little or no swap used. So the 256MB RasPi is still just as fast as the 512MB for the Web Server. The only real gain I might see with the 512MB is that they Over-clock better than my Rev. 1.0 board. Page serve times are now down to about 1.5 seconds average. I am very happy with the performance of WordPress now.