Nebula Graph on Pi

With the ARM64 Docker Image of Nebula Graph, it’s actually quite easy to run it on SBC/Respberry Pi!
1 Background
Recently, after Yee from Nebula Graph Community fixed ARM build on nebula-third-party#37, we could play with Nebula Graph on M1 Chip Macbook. While, I didn’t get the chance to run it on a SBC/Pi.
A couple of weeks before, in a twitter thread with @laixintao and @andelf I decided to purchase a Rock Pi 3A:
And it looks nice!(Even come with a NPU inside)
2 The Guide of running Nebula Graph on a Pi SBC
Actually, since v3.0.0, Nebula comes with a standalone version, which suits the deep edge deployment more, but today, I will only setup the cluster version as the Docker Image is out of box to be used. I will share more on standalone version in upcoming weeks.
I put the Ubuntu Server installation steps in the appendix, and now I assumed we already have an ARM64 Linux up and running on a Pi SBC.
2.1 Step 0, Install Docker-Compose on Pi
I am using debian/ubuntu here, while it should be the same for other distros, referring to https://docs.docker.com/engine/install/.
|
|
After Docker being installed, we install compose here, there could be issues encounterred from the Docker website on Compose installation. While, due to compose is just a python package, let’s do it via python3-pip install:
|
|
2.2 Step 1, bootstrap Nebula Graph Cluster on Pi
We clone the compose file for nebula cluster first:
|
|
Then, let’s download the client: nebula-console, and connect to the GraphD service:
|
|
Activate the storageD services:
|
|
2.3 Step 2, Play Nebula Graph on Pi
WIth the SHOW HOSTS
we should see StorageD services are all ONLINE, then we could run this from the console session to load the test dataset.
Referennce: https://docs.nebula-graph.io/3.0.1/nebula-console/#import_a_testing_dataset
|
|
The test data will be loaded in around 1 minute. Then, we could query something like:
|
|
Check this out and…
Happy Graphing!
3 Appendix: Installing Ubuntu Server on Rock Pi 3A SBC
-
Get the image from https://wiki.radxa.com/Rock3/downloads decompressing the file into
.img
-
Write the image to a micro SD card with etcher
-
Boot it!
feature image credit: @_louisreed