Earlier today we got an email from a user attempting to install the TICK stack on a Raspberry Pi. I thought it might be useful for others so I’ll repost my answer here.
What you will need is to use the ARM architecture install instructions:
wget https://dl.influxdata.com/influxdb/releases/influxdb-1.3.4_linux_armhf.tar.gz tar xvfz influxdb-1.3.4_linux_armhf.tar.gz
The other 4 Linux binaries are for x86/x64 architecture and won’t run on a Raspberry Pi (ARM-based) machine.
That being said, that tar file is not actually a full package that you can then use a package manager to install from. I wrote up some instructions at https://davidgs.com/2017/influxdb-on-artik-520-redux/ for doing this on an ARTIK-520 which is also ARM-based, so the same instructions will work for the Raspberry Pi. Here are the important bits from that post:
All the downloads for InfluxDB, Chronograf, Telegraf and Kapacitor contain a directory structure with /usr
, /var
and /etc
directories, so here’s what I did after I untar’ed all the downloads:
[root@localhost ~]# cd influxdb-1.2.4-1 ; cp -rp usr/* /usr ; cp -rp etc/* /etc ; cp -rp var/* /var
That gets everything in the right places for influxDB. Now just to the same thing for the kapacitor, telegraf, and chronograf directories.
Everything may be in the right place, but they won’t automatically start at boot time because raspian is a systemd based OS, so it’s important to get each one of those set up as a systemd service. Luckily, this isn’t hard. You just need to create the files in the /etc/systemd/system
directory, and I’m going to make it even easier for you by giving you those files.
[root@localhost system]# cat influxdb.service
[Unit]
Description=InlfuxDB service
[Service]
ExecStart=/usr/bin/influxd
NotifyAccess=main
#WatchdogSec=10
Restart=on-failure
LimitNPROC=1
ProtectHome=true
ProtectSystem=full
I then created one for each of the other services as well:
[root@localhost system]# cat telegraf.service
[Unit]
Description=Telegraf service
[Service]
ExecStart=/usr/bin/telegraf -config /etc/telegraf/telegraf.conf
NotifyAccess=main
#WatchdogSec=10
Restart=on-failure
ProtectHome=true
ProtectSystem=full
[root@localhost system]# cat chronograf.service
[Unit]
Description=Chronograf service
[Service]
ExecStart=/usr/bin/chronograf -b /var/lib/chronograf/chronograf-v1.db >/dev/null 2>&1
NotifyAccess=main
#WatchdogSec=10
Restart=on-failure
ProtectHome=true
ProtectSystem=full
Finally, I just had to make sure that systemd knew about these new services, and start them:
[root@localhost system]# systemctl enable influxdb.service; systemctl start influxdb.service
[root@localhost system]# systemctl enable telegraf.service ; systemctl start telegraf.service
[root@localhost system]# systemctl enable chronograf.service ; systemctl start chronograf.service
Then a quick check with:
[root@localhost system]# systemctl
...
influxdb.service loaded active running InlfuxDB service
...
telegraf.service loaded active running Telegraf service
...
chronograf.service loaded active running Chronograf service
And I can see that they are all up and running, and that systemd will make sure that they stay that way, even across reboots.
That should get everything up and running, and recovering after a reboot.