In 2014 I watched new single-board-computers enter the market. I am very fond of the Raspberry Pi project and I am using RPi for quite some time now as you can see from my previous posts. Now I am curious how it compares to Banana Pi. I am currently looking for a base station for my home automation project. I wouldn't call this a server since this term is in most cases used for different hardware. In this context reliability, cost of operation running 24/7, ease of use are the most important factors for me. I am going to write a series of blog posts on benchmarks of the different models in this context. So stay tuned!
Banana Pi is another interesting single-board-computer in the 45$ price range from SinoVoip. It has a Dual 1GHz ARM Cortex CPU. What really distinguishes the Banana Pi board from the competition is 1GB SDRAM and 10/100/1000 Ethernet.
I downloaded and unpacked the Archlinux for BananaPi image (see resources). Then I put a sdcard into my laptop (Ubuntu) and transferred the image:
sudo dd if=./ArchLinux_For_BananaPi_v1412.img of=/dev/mmcblk0
Then I booted the BaPi from that sdcard and initiated sync and update:
$ pacman -Syyu
$ pacman-db-upgrade
An optional step is to configure a suitable hostname for your new BBB based docker machine. I choose "kujira03" for that.
$ hostnamectl set-hostname kujira03
And now the installation of the docker package itself:
$ pacman -S docker systemd
Enable docker to run as a service:
$ systemctl enable docker.service
Done! Now we will reboot the BaPi and check if everything worked as expected:
$ shutdown -r now
Check that the docker service is running:
$ ifconfig
...
docker0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 172.17.42.1 netmask 255.255.0.0 broadcast 0.0.0.0
inet6 fe80::bd01:3011:3b12:b866 prefixlen 64 scopeid 0x20<link>
inet6 fe80::5484:7aff:fefe:9799 prefixlen 64 scopeid 0x20<link>
ether 56:84:7a:fe:97:99 txqueuelen 0 (Ethernet)
RX packets 5 bytes 308 (308.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 45 bytes 6171 (6.0 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
...
I am now able to use arm specific docker containers (as a convention they are usually prefixed with "armhf-"). In this example I start my "armhf-bench" container from docker hub and use it.
$ docker run -t -i finklabs/armhf-bench
107.8239s
879.7Kb/sec
578.979 MiB/s
That's it. Here my benchmark results for the Banana Pi:
Board | Banana Pi |
---|---|
CPU* | 107.8 sec |
FileIO | 0.87 MB/sec |
MEM | 579.0 MiB/sec |
Wattage | 2.62 Watt |
* for the CPU measurement: lower is better
If you are interested in this work let me know.
Best, Mark
Resources
- http://en.wikipedia.org/wiki/Banana_Pi
- http://www.bananapi.com
- IBM Docker benchmarking research paper