Safely Shutdown a Netgate 1100 Automatically
-
I have a situation where I am using a Netgate 1100 as a Site-to-Site VPN client in the car, it is connected to a 5G CPE. The problem is that when I want to turn the car off, I have to pull up my phone and halt the system (sometimes I forgot to do that too). so, my question is:
- In the case that I forgot to turn it off, what are the chances of a file system corruption, rendering the device unbootable?
- Are there any easy options to shut down the device automatically with the power from the car's battery after I turn the ignition off?
-
@siwatsirichai said in Safely Shutdown a Netgate 1100 Automatically:
in the car
I don't have a solution for you - but man you got my curiosity kat meowing at me.. What are using this vpn for in a car?
-
@siwatsirichai said in Safely Shutdown a Netgate 1100 Automatically:
Are there any easy options to shut down the device automatically with the power from the car's battery after I turn the ignition off?
No. Even if you could trigger a halt, via a gpio or similar, the 1100 does not actually have a standby mode so you would still need to de-power it.
I would use ZFS and probably RAM disks too (in 22.05) which will effectively prevent unexpected power loss being a problem.
Steve
-
@johnpoz said in Safely Shutdown a Netgate 1100 Automatically:
@siwatsirichai said in Safely Shutdown a Netgate 1100 Automatically:
in the car
I don't have a solution for you - but man you got my curiosity kat meowing at me.. What are using this vpn for in a car?
Ah, I have a little Raspberry Pi Rig Setup in the car as my dashcam and entertainment stuff, but it also communicates to my home server to trigger home automation and report the data from the car's OBD-II (CAN Bus) to MQTT, it also remotely uploads dashcam footage when it gets full, additionally, I sometimes work with my laptop with my car parked, it's really nice just having a high-speed internal network (because the laptop can communicate with the domain controller). also, it has an unifi ap which is configured to talk to the controller using internal IP address.
It also does remote desktop in the case that I want to use a car-puter for some reason.
And I mean I could probably pull it off if I forward a bunch of port or install OpenVPN on the Pi. But since I already got a VPN-capable router, It's more of a why not rather than a why.
I'm overhauling it at the moment, it used to run on a Mikrotik Hex-S@stephenw10 said in Safely Shutdown a Netgate 1100 Automatically:
@siwatsirichai said in Safely Shutdown a Netgate 1100 Automatically:
Are there any easy options to shut down the device automatically with the power from the car's battery after I turn the ignition off?
No. Even if you could trigger a halt, via a gpio or similar, the 1100 does not actually have a standby mode so you would still need to de-power it.
I would use ZFS and probably RAM disks too (in 22.05) which will effectively prevent unexpected power loss being a problem.
Steve
Interesting, That would be a very ideal solution. Thank you very much
-
A better solution would be a dc-dc ups/psu but I don't see any on the NUT hardware list so you might have to do something custom if you went that route.
Steve
-
Just another idea: if you are using a raspberry Pi in car, is there any way to monitor the "turn off ignition" from Pi and sent a shutdown command via CLI?
I know that an interactive SSH session ends up in a menu in which you can enter the SSH shell, but is it also possible to send a SSH command directly?
Never investigated in this...!?Regards
-
Another idea: You could use a baby UPS and configure for shutdown immediately upon power loss. With most UPS units, this would also give you automatic start-up as soon as the car is started. Assuming that you want that.
-
Yeah, that's what I was thinking but really you want a DC-DC device for in car and I can't see anything that NUT supports.
Steve
-
@stephenw10 said in Safely Shutdown a Netgate 1100 Automatically:
Yeah, that's what I was thinking but really you want a DC-DC device for in car and I can't see anything that NUT supports.
Steve
Interesting, I suppose I can make a board that emulates a NUT end device, that could be an interesting project!
https://create.arduino.cc/projecthub/abratchik/hid-compliant-ups-with-arduino-75198c
https://github.com/xm381/Raspberry-Pi-UPS
I suppose this might works