Problem with UPS : auto shutdown and email don't work

Status
Not open for further replies.

djoole

Contributor
Joined
Oct 3, 2011
Messages
158
Hi,

I've plugged and APC Back-UPS 550 ES on my NAS.
Communication seems to be ok, but FreeNAS doesn't trigger shutdown when timer is finished.
Also, it doesn't send an email as configured.

Config is :
FreeNAS-8.0.1-RELEASE-amd64 (8081)
Identifier : ups
Driver : APC Back-UPS Pro USB USB (usbhid-ups)
Port : /dev/ugen3.3
Shutdown mode : UPS goes on battery
Shutdown timer : 300
UPS Master User Password : fixmepass
Send Email Status Updates : checked
To email : my email
Email Subject : UPS report generated by %h

Log when UPS goes on battery and on line again :

Apr 22 15:18:22 nas upsmon[2970]: UPS ups on battery
Apr 22 15:18:22 nas upssched[19846]: Timer daemon started
Apr 22 15:18:22 nas upssched[19846]: New timer: ONBATT (300 seconds)
Apr 22 15:18:22 nas upssched[19845]: Executing command: EMAIL
Apr 22 15:18:22 nas upssched[19845]: exec_cmd(/usr/local/bin/custom-upssched-cmd EMAIL) returned 127

Apr 22 15:23:22 nas upssched[19846]: Event: ONBATT
Apr 22 15:23:22 nas upssched[19846]: exec_cmd(/usr/local/bin/custom-upssched-cmd ONBATT) returned 127
Apr 22 15:23:37 nas upssched[19846]: Timer queue empty, exiting

Apr 22 15:28:57 nas upsmon[2970]: UPS ups on line power
Apr 22 15:28:57 nas upssched[20429]: Timer daemon started
Apr 22 15:28:57 nas upssched[20429]: Cancel ONBATT, event: ONLINE
Apr 22 15:28:57 nas upssched[20429]: exec_cmd(/usr/local/bin/custom-upssched-cmd ONLINE) returned 127
Apr 22 15:28:57 nas upssched[20429]: Cancel LOWBATT, event: ONLINE
Apr 22 15:28:57 nas upssched[20429]: exec_cmd(/usr/local/bin/custom-upssched-cmd ONLINE) returned 127
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
There were LOTS of UPS fixes and upgrades done between 8.01 and 8.03-p1, I'd suggest upgrading.
 

djoole

Contributor
Joined
Oct 3, 2011
Messages
158
Er... i'm a bit afraid of upgrading, i've done quite a few modifications in the system files, i think i will loose them on upgrading, or worse, could these mods prevent the upgrade process to go well??
I would like to make a "ghost" of the SD card before upgrading so that i can return to 8.0.1 if needed, how could i achieve that?
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
Er... i'm a bit afraid of upgrading, i've done quite a few modifications in the system files, i think i will loose them on upgrading, or worse, could these mods prevent the upgrade process to go well??
I would like to make a "ghost" of the SD card before upgrading so that i can return to 8.0.1 if needed, how could i achieve that?

If you want to do that, you would be better to just get a new USB key and install 8.04-p1 on that and test it. Ghosting an SD or USB drive doesn't always work properly.

I would make a copy of all the files you modded and put them in a folder on your NAS and call it "mods" or "upgrade" and copy your stuff there. After you upgrade, copy those things back, reboot, and you should be done.

If you want the UPS stuff to work, you need to upgrade. There we lots of bugs and changes made to the UPS stuff in 8.03.
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
Heheheh, yes, but remembering now is much better than after something happens! ;)
 

djoole

Contributor
Joined
Oct 3, 2011
Messages
158
A quick post to let you know that i'm finally ready to upgrade my freenas from 8.0.1-Release to 8.2.0-RC1 !!

I found all my mods and backed up them.

Maybe the method will be useful for someone so i wanted to share that.

Command find helped me to find modded files, just had to try with different mtime values
Code:
find /conf/ /root/ -name '*' -mtime -287 -type f -exec cp {} /mnt/zepool/apps/modding/ \;


I hope the upgrade will go smoothly, and hoepfully with 8.2 I won't have to apply all my mods and use some plugins instead!
 
Status
Not open for further replies.
Top