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

    Unbound stopped and won't start

    Scheduled Pinned Locked Moved DHCP and DNS
    14 Posts 3 Posters 3.7k 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.
    • C Offline
      cmb
      last edited by

      You make note of the contents of root.key before deleting it?

      1 Reply Last reply Reply Quote 0
      • K Offline
        kejianshi
        last edited by

        I'm sorry - I didn't.

        The nearest reason I can guess this may have happened is a write to the file interrupted by power flicker/outage.

        The ups is currently needing a battery swap.

        1 Reply Last reply Reply Quote 0
        • C Offline
          cmb
          last edited by

          Was hoping to get a lead on the root cause there. Seems it's happened to roughly a half dozen people, but none have reported what the contents of root.key were before deleting it.

          If you happen to see it again (seems unlikely), or anyone else that happens upon this thread in the future seeing it, please note the contents of the file. Diag>Command, run:

          cat /var/unbound/root.key
          

          Or download /var/unbound/root.key from same page or via scp. The contents should be text, so cat should suffice.

          1 Reply Last reply Reply Quote 0
          • D Offline
            doktornotor Banned
            last edited by

            @cmb:

            but none have reported what the contents of root.key were before deleting it.

            You mean like this one? https://forum.pfsense.org/index.php?topic=87357.msg479617#msg479617 - there's some inetd nonsense in there.

            1 Reply Last reply Reply Quote 0
            • K Offline
              kejianshi
              last edited by

              CMB - I have a few of these running here and there so if it happens again I will take a look at whats inside the file before I send it to bit heaven.

              doktornotor - Yep - Thats exactly the errors it was throwing out.

              1 Reply Last reply Reply Quote 0
              • C Offline
                cmb
                last edited by

                Thanks, I looked through all those threads and missed the contents in that one. Looks like it's ending up with contents of other files in /var/ which would indicate the file wasn't fsynced by unbound after being written out. unbound-anchor also fails to create/update root.key if has invalid contents.

                Should be fixed.
                https://redmine.pfsense.org/issues/5334

                Also reporting upstream to unbound as it should be doing that fsync and doesn't appear to be.

                1 Reply Last reply Reply Quote 0
                • K Offline
                  kejianshi
                  last edited by

                  That is cool.  I like fixed things (-:

                  1 Reply Last reply Reply Quote 0
                  • C Offline
                    cmb
                    last edited by

                    Unbound fixed the missing fsync for a future release.
                    https://www.nlnetlabs.nl/bugs-script/show_bug.cgi?id=712

                    The fsync I added should fix it in the mean time.

                    1 Reply Last reply Reply Quote 0
                    • K Offline
                      kejianshi
                      last edited by

                      Even better…

                      So I guess my bad batteries were less of a curse than I thought.

                      Now I need to replace them...  From 8k miles away...

                      1 Reply Last reply Reply Quote 0
                      • D Offline
                        doktornotor Banned
                        last edited by

                        @cmb:

                        Should be fixed.
                        https://redmine.pfsense.org/issues/5334

                        Cannot reproduce the original issue (ZFS on the test rigs doesn't seem to suffer from any of similar "features") but intentionally screwing the anchors file gets recovered just fine now…

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