Monitoring Raspberry Shake health

I was excited to check my two Raspberry Shakes for the Kamchatka earthquake. Unfortunately, both of them were no recording and we showing offline. One required a new CD card and the other was recoverable after a little tinkering.

With that said, is there any method for monitoring the status of these remotely and getting an alert for various items (offline, SD card full, etc.)?

1 Like

Hello wyohman, and welcome to the community!

I’m sorry to read about these issues. Regarding status monitoring, if your Shakes were online on our network, we send “offline alert” emails twice when the network itself detects that a Shake is no longer transmitting.

Otherwise, if your Shakes are offline, it may be worth considering having SWARM (USGS: Volcano Hazards Program) always open on one computer (even an old one you no longer use), so you can keep an eye on things.

Alternatively, if you’re interested in automating and know a bit of coding, you could set up a local monitoring system that would notify you (by email, Telegram message, or another method) when the Shake stops functioning.

Regarding the microSD card, you can use this to calculate how much data can be saved on the card you have, and set up the Waveform Data Saving parameter in rs.local/ accordingly, so the card will never be filled to the brim.

If you have any other questions, I remain available.

“Alternatively, if you’re interested in automating and know a bit of coding, you could set up a local monitoring system that would notify you (by email, Telegram message, or another method) when the Shake stops functioning.”

I’m looking for something I can automate. Can you give me more info about what commands I can use to check system status?

Sure!

You can use this one:
ping -c1 SHAKE_IP >/dev/null 2>&1 && echo "Reachable" || echo "UNREACHABLE"
to simply ping the Shake and see if it responds

This one:
nc -z -w2 SHAKE_IP 18000 && echo "SeedLink OK" || echo "SeedLink CLOSED"
can be used to check if the Shake data transmission protocol via seedlink (on port 18000) is open and running

This other:
ssh -o ConnectTimeout=5 myshake@SHAKE_IP "df -P /opt/data | awk 'NR==2{print \$5}'"
will tell you how much of the Shake microSD card is being used.

This command:
ssh myshake@SHAKE_IP "find /opt/data/archive -type f -mtime -1"
will print out the files that were modified in the last day, in a list. If you simply want a number, you can use this other command instead:
ssh myshake@SHAKE_IP "find /opt/data/archive -type f -mmin -1440 | wc -l"

An example of all results, executed from an Ubuntu laptop in the same local network as my Shake:

$ping -c1 SHAKE_IP >/dev/null 2>&1 && echo "Reachable" || echo "UNREACHABLE"
Reachable

$ nc -z -w2 SHAKE_IP 18000 && echo "SeedLink OK" || echo "SeedLink CLOSED"
SeedLink OK

$ ssh -o ConnectTimeout=5 myshake@SHAKE_IP "df -P /opt/data | awk 'NR==2{print \$5}'"
myshake@SHAKE_IP's password:
63%

$ ssh myshake@SHAKE_IP "find /opt/data/archive -type f -mtime -1"
myshake@SHAKE_IP's password:
/opt/data/archive/2025/AM/...00.EHZ.D.2025.224
/opt/data/archive/2025/AM/...00.EHZ.D.2025.223
/opt/data/archive/2025/AM/...00.ENN.D.2025.223
/opt/data/archive/2025/AM/...00.ENN.D.2025.224
/opt/data/archive/2025/AM/...00.ENE.D.2025.224
/opt/data/archive/2025/AM/...00.ENE.D.2025.223
/opt/data/archive/2025/AM/...00.ENZ.D.2025.224
/opt/data/archive/2025/AM/...00.ENZ.D.2025.223

$ ssh myshake@SHAKE_IP "find /opt/data/archive -type f -mmin -1440 | wc -l"
myshake@SHAKE_IP's password:
8

You could combine all these in a simple script that would present you a report of sorts and give you an always-updated overview of your Shake(s) status.

1 Like

Thanks again for the info. Is “SeedLink” the same as one of these from the Shake GUI?

Data Forwarding : ON
Server Connection : Connected

No trouble at all wyohman.

No, SeedLink is an internal protocol and software system used for the real-time acquisition and distribution of seismological and other geophysical data.

Those two values in the GUI represent, in order:

  1. forwarding data to our servers
  2. status of server connection

Regarding SeedLink, if you see:

Data Producer	:	ON
Data Consumer	:	ON

then the protocol will also be ON.