Hello to All! It might be not exactly NUT question but implementation. I have a rack with one UPS and several servers getting power from this device. One server is a master and other are slaves. All systems are running Debian 4.15.3 kernel and APC UPS. Everything works fine but what I need is to make an order for shutting down servers as they have different roles. Is it possible to configure SQL and VM servers to go down first, then mail server, then NAS and UPS master as the last one after all of them? I see that in case of power outage all servers receive signal from master simultaneously. May I change the order somehow? Best regards, Kirill. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20200917/599f8c07/attachment.html>
On Thu, 17 Sep 2020, Kirill Nikonorov wrote:> Hello to All! > It might be not exactly NUT question but implementation. > I have a rack with one UPS and several servers getting power from this device. One server is a master and other are slaves. All systems are running Debian > 4.15.3 kernel and APC UPS. Everything works fine but what I need is to make an order for shutting down servers as they have different roles. > Is it possible to configure SQL and VM servers to go down first, then mail server, then NAS and UPS master as the last one after all of them? > I see that in case of power outage all servers receive signal from master simultaneously. May I change the order somehow?Nut provides a directive HOSTSYNC [1] in upsmon.conf : HOSTSYNC seconds upsmon will wait up to this many seconds in master mode for the slaves to disconnect during a shutdown situation. By default, this is 15 seconds. But this looks as if it is not a sufficiently staged approach for your needs. If you need something more sequenced, it will be necessary to use upssched to drive a script which does what you want. Roger [1] https://networkupstools.org/docs/man/upsmon.conf.html
On September 17, 2020 6:09:18 PM GMT+03:00, Kirill Nikonorov <knikonor at gmail.com> wrote:>Hello to All! >It might be not exactly NUT question but implementation. >I have a rack with one UPS and several servers getting power from this >device. One server is a master and other are slaves. All systems are >running Debian 4.15.3 kernel and APC UPS. Everything works fine but >what I >need is to make an order for shutting down servers as they have >different >roles. >Is it possible to configure SQL and VM servers to go down first, then >mail >server, then NAS and UPS master as the last one after all of them? >I see that in case of power outage all servers receive signal from >master >simultaneously. May I change the order somehow?Yes, you xan do that.. You will need to write a specific script on each aerver and run it via nut's client upssched directive Wolfy> >Best regards, >Kirill.
Hi Manuel, thank you for pointing this. I know about upsshed but I have no idea how to let dependable server to discover that another server was shut down. Any examples of such scripts? чт, 17 сент. 2020 г. в 21:00, Manuel Wolfshant <wolfy at nobugconsulting.ro>:> On September 17, 2020 6:09:18 PM GMT+03:00, Kirill Nikonorov < > knikonor at gmail.com> wrote: > >Hello to All! > >It might be not exactly NUT question but implementation. > >I have a rack with one UPS and several servers getting power from this > >device. One server is a master and other are slaves. All systems are > >running Debian 4.15.3 kernel and APC UPS. Everything works fine but > >what I > >need is to make an order for shutting down servers as they have > >different > >roles. > >Is it possible to configure SQL and VM servers to go down first, then > >mail > >server, then NAS and UPS master as the last one after all of them? > >I see that in case of power outage all servers receive signal from > >master > >simultaneously. May I change the order somehow? > > > Yes, you xan do that.. You will need to write a specific script on each > aerver and run it via nut's client upssched directive > > Wolfy > > > >Best regards, > >Kirill. > > > _______________________________________________ > Nut-upsuser mailing list > Nut-upsuser at alioth-lists.debian.net > https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20200918/05781836/attachment.html>