UPSMON independent shutdown.
-
@gwaitsi said in UPSMON independent shutdown.:
If you install the "Filer" package,
True ! In fact, discovered yesterday that "Filer" wasn't the build-in GUI editor ...
I use the Notes package myself : for every change I made that can't be done with the GUI, thus stored for eternity, I take notes.
This forces me to re read the documentation if I want to implement changes. Not only pfSense changes over time ;)@stephenw10 said in UPSMON independent shutdown.:
ee
I know. nano is just a personal preference, as it exists on all my pfSenses, and linux based servers. I'm trying to limit my have-to-know keyboard short-cut list to a minimum as I'm stilling suffering from the vi syndrome.
-
So it is looking good so far, lost comms are from shutting down the service on truenas. forced shutdown from lost comms works.
Still need to test how long the battery on the dumb ups will last. It should last much longer than the apc ups which gives me about an hour for power to be restored.
i will have on rare occasions a use case when the power is gone for more than an hour and pfsense shuts down, but the battery doesn't die before power is restored. in such a use case, pfsense will need to be manually re-started.
Anyone got any ideas?
Nov 16 06:57:38 upsmon 98032 UPS ups@nas.net.lan: Communications (re-)established. Nov 16 06:57:33 upsmon 98032 UPS [ups@nas.net.lan]: connect failed: Connection failure: Connection refused Nov 16 06:57:28 upsmon 98032 UPS [ups@nas.net.lan]: connect failed: Connection failure: Connection refused Nov 16 06:57:23 upsmon 98032 UPS [ups@nas.net.lan]: connect failed: Connection failure: Connection refused Nov 16 06:57:18 upsmon 98032 UPS [ups@nas.net.lan]: connect failed: Connection failure: Connection refused Nov 16 06:57:13 upsmon 98032 UPS [ups@nas.net.lan]: connect failed: Connection failure: Connection refused Nov 16 06:57:08 upsmon 98032 UPS ups@nas.net.lan: Communications lost. Nov 16 06:57:08 upsmon 98032 Poll UPS [ups@nas.net.lan] failed - Server disconnected Nov 16 06:56:48 upsmon 98032 UPS ups@nas.net.lan: Communications (re-)established. Nov 16 06:56:43 upsmon 98032 UPS ups@nas.net.lan: Communications lost. Nov 16 06:56:43 upsmon 98032 Poll UPS [ups@nas.net.lan] failed - Server disconnected Nov 15 05:34:34 upsmon 98032 UPS ups@nas.net.lan: On line power. Nov 15 05:34:29 upsmon 98032 UPS ups@nas.net.lan: On battery. Nov 14 00:56:34 upssched-cmd UPS on battery too long, forced shutdown
final schedups-cmd
#! /bin/sh # # This script should be called by upssched via the CMDSCRIPT directive. # Here is a quick example to show how to handle a bunch of possible # timer names with the help of the case structure. # This script may be replaced with another program without harm. # The first argument passed to your CMDSCRIPT is the name of the timer # from your AT lines. # upssched-cmd --slave -- case $1 in onbattery) logger -t upssched-cmd "UPS on battery too long, forced shutdown" /usr/local/sbin/upsmon -c fsd ;; lowbattery) logger -t upssched-cmd "UPS on battery critical, forced shutdown" /usr/local/sbin/upsmon -c fsd ;; commbad) logger -t upssched-cmd "UPS communications missing too long, forced shutdown" /usr/local/sbin/upsmon -c fsd ;; powerdown) logger -t upssched-cmd "UPS communications missing too long, forced shutdown" /usr/local/sbin/upsmon -c fsd ;; *) logger -t upssched-cmd "Unrecognized command: $1" ;; esac
-
@gwaitsi said in UPSMON independent shutdown.:
Anyone got any ideas?
What is is the question ?
How to manually restart ?For the "AT ... timer commands", see the upssched.conf file.
-
@Gertjan the ups on the pfsense (Qotom J1900) is like a power adapter with a battery e.g. it is dumb. pfsense is triggered via truenas server which has a apc ups connected to it.
If the power comes back on before the pfsense powers down, all is good. it will run on battery and continue.
If the pfsense shutdowns, but the ups battery doesn't deplete, the J1900 will never see a loss of power and therefore wont know to turn back on, so has to be manually started.
Looking for ideas on how i could solve this scenario.
-
-
Yeah, WoL is probably the only option there without some additional hardware.
Steve
-
sounds like a good idea fellas, just need to figure out how to do that now ;-)
-
If your J-thing is a typical PC device, check the BIOS.
WOL is nothing more a an always-on chip (activated as soon as there is some power) and simulates a press-power-on-the-button as soon as it sees it's own MAC 3 times in a packet load over the/a Ethernet interface, typically the LAN interface.If not : you found yourself yet another Rasberry/PI project ;)
-
does anyone know how to set a netgear switch (GS108Tv3) up to provide the magic packet
-
@gwaitsi said in UPSMON independent shutdown.:
WOL for GS108Tv3
=> They should know it : https://community.netgear.com/t5/Smart-Plus-and-Smart-Pro-Managed/GS108Tv3-how-to-wake-up-pfsense-router/m-p/2007829
If you need a fast answer : look in the Netgear's GUI or go for the manual.Bad start : Google doesn't know about it, so chances are great the router doesn't have WOL capabilities.
-
@Gertjan couldn't find anything in the gui. there is a section on green ethernet, but it is not clear to me whether that causes broadcast magic packets. (i thought the specific mac address had to be used)
-
You can WOL with pfSense.
pfSense, as your switch, should be 'always' on. -
@Gertjan what do i have to do on the pfsense side, as the wake on lan under services is for sending the magic packet. are you saying just need to set the bios and then it should be good
-
pfSense can send = create and put in the wire - these packets to wake up LAN based - or even devices on the Internet. No BIOS setting or dependency is needed here.
pfSense is a router, the one and only equipment that is always on. switches, hubs etc are also always 'on' .
So you wake up devices with pfSense. I do this on a nearly daily basis.What are you actually trying to do ?
-
@Gertjan you didn't read the thread properly. i need to wake up the pfsense box (Qotom J1900) because it could timed shutdown on a dumb ups that may not run out of battery before power is restored.
In this case, the switch would still be up, but not pfsense. so i need to wake pfsense up. -
Oh : you didn't test that by now ? Why not ?
First step : is your 'J1900' WOLlable ? You have the equipment. Do you have the doc ? It's a RTFM thing.
If so - or if you doubt - : take note of the - or all of the - MAC addresses of the all the network connector of the J1900.
Download some WOL generator tool from the net : I used https://www.depicus.com/wake-on-lan/ a lot in the past.
Now, with this tool, broadcast the WOL packet to your J1900. Try every NIC.You'll have your answer in .... 5 minutes ?
edit : Bad news : https://www.win-raid.com/t6767f54-Request-adding-wake-on-lan-feature-to-J-bios.html (if they talk about your board).