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

    Saving config.xml from crashed USB stick

    Scheduled Pinned Locked Moved General pfSense Questions
    7 Posts 5 Posters 1.2k 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
      creepwood
      last edited by

      I'm wondering if it's possible to save my configuration file to load it into a fresh install. I had a crash yesterday where my usb stick where pfsense were running. From what I could gather in the messages rushing through the screen while pfsense booted I assume the usb stick had started to have a bunch of bad sectors. I should've known better that the stick would run out of r/w cycles.

      What I'm wondering now, how do I get a hold of my config file fromt he old stick. I'm having trouble mounting it in my debian station. It might be because of the bad sectors but I thought it would weird since it actually booted from that stick.

      I tried with mounting with the -t u2fs and -t ufs but I might be wrong on what kind of filesystem it is. In my dmesg I get

      WARNING<<< Wrong ufstype may corrupt your filesystem, default is ufstype=old
      [63157.636738] ufs_read_super: bad magic number

      1 Reply Last reply Reply Quote 0
      • ?
        Guest
        last edited by

        I'm wondering if it's possible to save my configuration file to load it into a fresh install.

        Boot a PC or Laptop from a Linux LiveCD and then connect the USB pen drive there and then try out to
        copy this xml file over to the Linux OS. And then you should try out storing and reading it from the new
        medium it was stored on.

        1 Reply Last reply Reply Quote 0
        • C
          creepwood
          last edited by

          @BlueKobold:

          I'm wondering if it's possible to save my configuration file to load it into a fresh install.

          Boot a PC or Laptop from a Linux LiveCD and then connect the USB pen drive there and then try out to
          copy this xml file over to the Linux OS. And then you should try out storing and reading it from the new
          medium it was stored on.

          I already have the usb drive connected to Debian, I have trouble mounting it.

          1 Reply Last reply Reply Quote 0
          • D
            divsys
            last edited by

            You might do better with a FreeBSD live cd, else you'll need to make sure you can mount a UFS under Debian.

            You're trying to get to the /cf/conf/ folder on the USB stick if it's still readable.
            The /cf/conf/backup folder may have a slightly older version of your config if you can't get to config.xml (the last live version)

            -jfp

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

              @divsys:

              You might do better with a FreeBSD live cd

              That'd be my suggestion. UFS support in Linux tends to be hit and miss, or at least it used to be, been a while since I've tried. On a drive that's questionable, it's possibly more miss than hit.

              1 Reply Last reply Reply Quote 0
              • 2
                2chemlud Banned
                last edited by

                …if you prefer a GUI, take PC-BSD, works fine with pfSense media for me...

                1 Reply Last reply Reply Quote 0
                • C
                  creepwood
                  last edited by

                  Thank you so much for your help. I tried with a live CD running FSCK on the drive but it ended up being beyond help. It'll be way more easy to redo the settings than actually put way too much energy in saving broken data.

                  I've learned something.

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