UPS cuts power to the outlets when power returns

  • Hello everyone, I'm new to OMV and just starting out with Linux.


    I’ve installed OMV 7 on a Ugreen 2800, connected my APC UPS PRO BR650MI via USB cable, installed the openmediavault-nut plugin version 7.0.8-1, and the NAS auto-shutdown feature after X seconds of UPS battery takeover works correctly.


    The issue is that when power returns the UPS cuts power to the outlets and all devices connected to the NAS shut down.


    I’ve left the plugin settings at their defaults:

    • driver = usbhid-ups
    • port = auto

    Is there any additional parameter I should add to prevent the UPS from shutting off when I restart the NAS?


    Thanks everyone.

    Linux & OMV 7.x beginner - NAS UGREEN DXP2800

    Edited once, last by mtto71 ().

  • votdev

    Approved the thread.
  • mtto71

    Changed the title of the thread from “UPS cuts power to the outlets when power returns and I manually turn the NAS back on” to “UPS cuts power to the outlets when power returns”.
  • Are you sure the outlets are dead or the cpu not self starting after a power outage. Plug something else into the outlets like a lamp and test the UPS.

  • The router is also connected to the UPS. What happens is that when power returns, the UPS turns off its outlets, and both the NAS and the router obviously shut down abruptly. But this only happens if NUT had previously shut down the NAS via OMV. It's very strange—I thought there might be some parameter to pass to NUT...

    Linux & OMV 7.x beginner - NAS UGREEN DXP2800

  • I tried to comment the lline


    # POWERDOWNFLAG /etc/killpower


    in /etc/nut/upsmon.conf


    and it worked! UPS do not shut down when power returns.


    The problem is that the file is autogenerated by OMV and there is apparently no way to give this directive on the nut plugin gui. This means that i need to manually edit upsmon.conf every time OMV touches it.

    Linux & OMV 7.x beginner - NAS UGREEN DXP2800

  • Thank you votdev.

    i am a complete beginner so using your hint I asked to AI a step by step procedure, is it correct? I would like to be pretty sure i won't damage anything...


    Code
    ssh root@indirizzo-ip-omv
    omv-env set -- OMV_NUT_UPSMON_POWERDOWNFLAG "/dev/null"
    omv-env get OMV_NUT_UPSMON_POWERDOWNFLAG
    monit restart omv-engined
    omv-salt stage run prepare
    omv-salt deploy run nut
    cat /etc/nut/upsmon.conf | grep POWERDOWNFLAG

    Linux & OMV 7.x beginner - NAS UGREEN DXP2800

    Edited once, last by mtto71 ().

    • Official Post

    Thank you votdev.

    i am a complete beginner so using your hint I asked to AI a step by step procedure, is it correct? I would like to be pretty sure i won't damage anything...


    Code
    ssh root@indirizzo-ip-omv
    omv-env set -- OMV_NUT_UPSMON_POWERDOWNFLAG "/dev/null"
    omv-env get OMV_NUT_UPSMON_POWERDOWNFLAG
    monit restart omv-engined
    omv-salt stage run prepare
    omv-salt deploy run nut
    cat /etc/nut/upsmon.conf | grep POWERDOWNFLAG

    Looks ok. But i don't know how the POWERDOWNFLAG is interpreted/used by NUT; if it checks for the existence of a file /dev/null isn't a good choice.

  • Looks ok. But i don't know how the POWERDOWNFLAG is interpreted/used by NUT; if it checks for the existence of a file /dev/null isn't a good choice.

    I have really no idea, the AI says that 'This is the correct technical solution because /dev/null is a special device that 'swallows' everything, so the flag file is never actually created, preventing the system from ordering the UPS shutdown.'

    Linux & OMV 7.x beginner - NAS UGREEN DXP2800

  • mtto71

    Added the Label resolved

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!