Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    NUT as slave, Synology as UPS-server, some different error messages

    Scheduled Pinned Locked Moved pfSense Packages
    15 Posts 3 Posters 17.5k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      Mr. Jingles
      last edited by

      Thanks very much for your reply, Gogol  ;D

      I tested it connecting directly pfSense <-> SmartUPS. NUT recognizes it. But as soon as I point it to the Synology it just comes back with the ERROR: Data Stale, and the errors mentioned previously. I tried every APC-UPS model in the list in the NUT-GUI, but the error remains the same.

      The Synology in itself works fine; this Syno controls two other Synologies also, UPS-wise, and that just works.

      So I have no clue  :'(

      2014-01-08_142449.jpg
      2014-01-08_142449.jpg_thumb
      2014-01-08_143858.jpg
      2014-01-08_143858.jpg_thumb

      6 and a half billion people know that they are stupid, agressive, lower life forms.

      1 Reply Last reply Reply Quote 0
      • M
        Mr. Jingles
        last edited by

        More pics:

        2014-01-08_144021.jpg
        2014-01-08_144021.jpg_thumb
        2014-01-08_144033.jpg
        2014-01-08_144033.jpg_thumb

        6 and a half billion people know that they are stupid, agressive, lower life forms.

        1 Reply Last reply Reply Quote 0
        • G
          gogol
          last edited by

          What is in your  system log (upsmon)?

          1 Reply Last reply Reply Quote 0
          • M
            Mr. Jingles
            last edited by

            Thank you for your reply, Gogol  ;D

            There are several messages for 'upsmon' in Status/System Logs/General:

            Jan 8 14:32:22 upsmon[75026]: UPS [ups@192.168.2.41]: connect failed: Connection failure: Operation not permitted
            Jan 8 14:32:22 upsmon[74937]: Startup successful
            Jan 8 14:32:22 upsmon[66702]: upsmon parent: read
            Jan 8 14:32:00 upsmon[61573]: upsmon parent: read
            Jan 8 14:32:00 upsmon[61900]: Signal 15: exiting
            Jan 8 14:31:41 upsmon[61900]: UPS ups@192.168.2.41 is unavailable
            Jan 8 14:31:36 upsmon[61900]: Communications with UPS ups@192.168.2.41 lost
            Jan 8 14:31:36 upsmon[61900]: UPS [ups@192.168.2.41]: connect failed: Connection failure: Operation not permitted
            Jan 8 14:31:36 upsmon[61573]: Startup successful
            Jan 8 14:31:33 upsmon[21416]: Signal 15: exiting
            Jan 8 14:30:36 upsmon[21416]: Poll UPS [ups@localhost] failed - Data stale
            Jan 8 14:30:31 upsmon[21416]: Poll UPS [ups@localhost] failed - Data stale
            Jan 8 14:30:26 upsmon[21416]: UPS ups@localhost is unavailable
            Jan 8 14:30:26 upsmon[21416]: Poll UPS [ups@localhost] failed - Data stale
            Jan 8 14:25:31 upsmon[21416]: Communications with UPS ups@localhost lost
            Jan 8 14:25:31 upsmon[21416]: Poll UPS [ups@localhost] failed - Data stale
            Jan 8 14:23:36 upsmon[21393]: Startup successful

            (There were lots of these messages, I removed all the duplicates to make it readable).

            I was looking for the ups conf files, but I am still looking where they are  ;D

            6 and a half billion people know that they are stupid, agressive, lower life forms.

            1 Reply Last reply Reply Quote 0
            • G
              gogol
              last edited by

              I have the default settings in Synology NAS for firewall and QOS. Did you made changes there?

              1 Reply Last reply Reply Quote 0
              • M
                Mr. Jingles
                last edited by

                @gogol:

                I have the default settings in Synology NAS for firewall and QOS. Did you made changes there?

                Thanks  ;D

                I don't use QOS, and the firewall is disabled in the Synology. It doesn't matter, it doesn't work. But there is something very strange going on:

                Today I set up Syslog server on the Synology, as I want to see what my switch is doing. I told my switch and pfSense to send the logs there. The switch happily does, but pfSense does not:

                
                Jan 10 15:00:16 syslogd: kernel boot file is /boot/kernel/kernel 
                syslogd: sendto: Operation not permitted 
                
                

                So pfSense NUT can not talk to the Synology, and now syslogd also can't. But the switch can, and so can my desktop-PC's, my HTPC's, my tablet and my smart phone.

                I have no idea how to debug that  :-[

                6 and a half billion people know that they are stupid, agressive, lower life forms.

                1 Reply Last reply Reply Quote 0
                • P
                  P3R
                  last edited by

                  I would start by going through the firewall rules in detail. It sounds as if the Synology is out of the allowed ip address range…

                  1 Reply Last reply Reply Quote 0
                  • G
                    gogol
                    last edited by

                    Yes, I would look also to the firewall rules and network settings on the pfsense box. As I have shown it is possible and I have tested it with cutting off the power to the UPS (without removing the plug from the wall socket). I can get "stale data" also, but that is when they don't see each other.

                    1 Reply Last reply Reply Quote 0
                    • M
                      Mr. Jingles
                      last edited by

                      @P3R:

                      I would start by going through the firewall rules in detail. It sounds as if the Synology is out of the allowed ip address range…

                      @gogol:

                      Yes, I would look also to the firewall rules and network settings on the pfsense box. As I have shown it is possible and I have tested it with cutting off the power to the UPS (without removing the plug from the wall socket). I can get "stale data" also, but that is when they don't see each other.

                      Thank you to the both of you  ;D

                      Well shoot me if you want to, it works now and I have no clue what I have done (I've had an accident with brain damage and suffer from short term memory problems, this is not a joke, so it is hard for me to remember what I do if I don't write it down immediately). I have been doing a lot of things in different packages, cleaning up firewall rules, and so on. And this morning I tried it again. Not only is NUT now working, but surprisingly pfSense now also is sending syslog messages to the Synology syslog-server  :o

                      So once again thank you very much for helping me  ;D

                      Might I ask one final thing: NUT now shows like the attached screenshot. That isn't too much. But I was more wondering: where do you configure when pfSense needs to shut down when it gets a signal from the UPS-server in the Synology NAS?

                      I mean: in the Synologies I can tell each Synology to shut down x seconds/minutes after the main Synology sends its signal, but I don't see where you configure that in NUT? Or don't you? If not, what does it do then? Shutdown immediately after it receives the signal? Because that isn't necessary; I have power outages from time to time, that last seconds. My APC UPS can handle the machines for over an hour, so pfSense should not shut down in the first second, but only if there isn't power again say after 5 minutes.

                      Thank you again  ;D

                      nut_works.jpg
                      nut_works.jpg_thumb

                      6 and a half billion people know that they are stupid, agressive, lower life forms.

                      1 Reply Last reply Reply Quote 0
                      • G
                        gogol
                        last edited by

                        You don't have to do anything. Synology NAS sends a system halt command and waits for pfSense to halt and then shutdown itself and stops the UPS and then when the power comes back both machines startup.
                        I have set mine to shutdown after 5 minutes, because in the Netherlands when we have a power failure it lasts for a minimum of 60-90 minutes.

                        1 Reply Last reply Reply Quote 0
                        • P
                          P3R
                          last edited by

                          @gogol:

                          Synology NAS sends a system halt command…

                          I agree.

                          …and waits for pfSense to halt...

                          To do what? Would it stay up beyond it's configured shutdown time if the halt signal (what kind of signal is that?) from pfSense never arrives?

                          …and then shutdown itself and stops the UPS...

                          I don't think it could happen in that order but more importantly, is there really a shutdown command available from the monitoring system (in this case the Synology) to shut down the UPS (and then with the UPS starting to supply power again when main power is restored I assume)?

                          I would have expected a normal consumer UPS to signal loss of power to the monitoring system but have no means of shutting down the battery power and also not to be able to power the protected systems back up again? If I'm wrong, please explain how that works.

                          I'm not trying to scare anybody or looking for a fight here, I'm only very interested to understand the details so please enlighten me if I have have misunderstood things.

                          1 Reply Last reply Reply Quote 0
                          • G
                            gogol
                            last edited by

                            You are probably right about the order of my words or the order of the events  ;)

                            I thought I have read somewhere on Synology forum or article that a Synology NUT server waits for the other Synology client for shutdown ( maybe by pinging or so or not receiving polls at 5 second interval anymore). So I assume pfsense with NUT behaves the same.

                            I did only tested once with my settings and after cutting the power I watched first my pfsense box receiving a halt command after 5 minutes and then the Synology NAS starting to halt and then the UPS switches off. I know the UPS switched off because a monitor connected to the pfsense box and UPS stayed on with the text that the system has halted while the Synology NAS was halting until the UPS and the NAS and switch switched off.

                            I hope it is more clear now. :)

                            1 Reply Last reply Reply Quote 0
                            • M
                              Mr. Jingles
                              last edited by

                              G'day all lovers of the finest firewall in the world  ;D

                              Would anybody happen to know what this error means:

                              Poll UPS [ups@192.168.4.37] failed - Write error: Operation not permitted
                              

                              The 4.37 is the Synology that acts as the UPS server. Yesterday I was literally flooded with this (a couple of 100 emails about this), and normally I also get these a couple of times a week.

                              Google didn't help me any further. I am trying to understand who is trying to write what to where and who is messing around with that ( :P). In NUT the light is green, the synology also doesn't complain about anything UPS-related, so I am, at least temporary, once again completely lost.

                              Thank you for any help  ;D

                              6 and a half billion people know that they are stupid, agressive, lower life forms.

                              1 Reply Last reply Reply Quote 0
                              • First post
                                Last post
                              Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.