The Raspberry Pi is small sized computer based on ARM architecture, nowadays is becoming very popular due to it's low price (25USD) and performant design.
Monkey is known as a lightweight HTTP web server and stack which hits a huge performance due to it architecture and carefully design. On these benchmarking series we are testing Monkey on different platforms against other web solutions available.
The Raspberry Pi card it's a very interesting card as it provide a low cost board powered by the ARM architecture, overcloaked it can run at 800MHz of CPU, it supports SD cards and the common networking interfaces for LAN connectivity.
The Raspberry PI - Linux OS have the following details:
The target HTTP servers are:
The benchmarking tool used is Siege, it uses asyncrhonous sockets to perform the tests so it have a low latency compared with Apache Benchmark, so it provide more accurate results. The test is performed with the following command:
$ siege -b -t10S -c200 http://localhost:PORT/linux.jpgWe set the benchmarking mode and during 10 seconds, Siege will scale up to 200 concurrent clients which will perform as many request as it can over the file linux.jpg (200KB jpeg image).
Monkey and NginX have been configured and compiled from sources in the Raspberry PI board, also the configuration for each service is the one that comes by default, with the only exception that we have set NginX to work with five workers as Monkey is doing by default.
After the test over each HTTP server, Siege have provided the following results:
Transactions: 973 hits Availability: 100.00 % Elapsed time: 9.55 secs Data transferred: 187.80 MB Response time: 1.59 secs Transaction rate: 101.88 trans/sec Throughput: 19.66 MB/sec Concurrency: 162.37 Successful transactions: 974 Failed transactions: 0 Longest transaction: 2.36 Shortest transaction: 0.19
Transactions: 840 hits Availability: 100.00 % Elapsed time: 9.81 secs Data transferred: 161.96 MB Response time: 1.66 secs Transaction rate: 85.63 trans/sec Throughput: 16.51 MB/sec Concurrency: 141.88 Successful transactions: 840 Failed transactions: 0 Longest transaction: 8.87 Shortest transaction: 0.27
Monkey was capable to serve the linux.jpg file 101.88 times per second and NginX only 85.63, that means that Monkey is ~16% faster serving static content than NginX in a Raspberry PI board. We can also see that NginX did not scale so well as it longest transaction was 8.87 v/s Monkey which was 2.36:
The test was made in localhost mode, which does not reflect a real internet environment, so under different circumstances re results could be different. The localhost test helps to determinate how the server perform over a high load as it reduces the TCP and networking overhead in general.
If you have a Raspberry PI board, we encourage you that you perform your own tests, feel free to contact us about the results in question to our mailing list.