Navigation

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

    Clear out all old config from package

    pfSense Packages
    4
    9
    2346
    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.
    • T
      Trel last edited by

      Is there any way to clear out all asscociated config from a package?
      Removal and reinstallation doesn't help as the settings and config persist.

      Right now the only thing I can see that might work is backing up the config, stripping out all reference and restoring to a fresh install.
      Is there any other way?

      If needed: syslog-ng is an example of a package that has the config persist through uninstalls with no option to not.

      1 Reply Last reply Reply Quote 0
      • KOM
        KOM last edited by

        SSH in and manually delete the folders?

        1 Reply Last reply Reply Quote 0
        • T
          Trel last edited by

          @KOM:

          SSH in and manually delete the folders?

          That's definitely an option.
          Do you know offhand the location where these folders would be?

          I can't seem to install locate with the pkg commands.

          1 Reply Last reply Reply Quote 0
          • marcelloc
            marcelloc last edited by

            @KOM:

            SSH in and manually delete the folders?

            package folder should be removed during package uninstall.

            The package gui config stays on xml.

            If you know how to deal with xml, you can do it using viconfig or editing a backup.xml file instead.

            Treinamentos de Elite: http://sys-squad.com

            Help a community developer! ;D

            1 Reply Last reply Reply Quote 0
            • T
              Trel last edited by

              @marcelloc:

              @KOM:

              SSH in and manually delete the folders?

              package folder should be removed during package uninstall.

              The package gui config stays on xml.

              If you know how to deal with xml, you can do it using viconfig or editing a backup.xml file instead.

              Ok, then just "two" other questions.

              What is the file for the active config and what do I need to do after editing it to make it active (reboot or something else)?

              and

              If I edit a backup xml file, and remove the appropriate settings, and then restore it, does anything I removed get wiped off of pfsense or would the package gui config persist still?

              1 Reply Last reply Reply Quote 0
              • KOM
                KOM last edited by

                Do you know offhand the location where these folders would be?

                For the odd one or two.  Some detective work usually gets it figured out.  I don't know where syslog-ng is.

                package folder should be removed during package uninstall.

                There always seems to be cruft left behind on the system in some form or another.

                1 Reply Last reply Reply Quote 0
                • marcelloc
                  marcelloc last edited by

                  @Trel:

                  If I edit a backup xml file, and remove the appropriate settings, and then restore it, does anything I removed get wiped off of pfsense or would the package gui config persist still?

                  Will be removed. Keep in mid that full config restore forces a reboot and package reinstall.

                  Treinamentos de Elite: http://sys-squad.com

                  Help a community developer! ;D

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

                    This is one way you can do it but you will need to know the package name that is used under 'installedpackages' in the xml.

                    Under Diagnostics: Command Prompt
                    PHP Execute

                    
                    unset($config['installedpackages'][insertpackagename]);
                    write_config();
                    
                    

                    use at your own risk and back a backup

                    so for syslog-ng (i dont have it installed so you will need to check the xml for the correct name its using

                    
                    unset($config['installedpackages'][syslog-ng]);
                    write_config();
                    
                    
                    1 Reply Last reply Reply Quote 1
                    • T
                      Trel last edited by

                      @marcelloc:

                      @Trel:

                      If I edit a backup xml file, and remove the appropriate settings, and then restore it, does anything I removed get wiped off of pfsense or would the package gui config persist still?

                      Will be removed. Keep in mid that full config restore forces a reboot and package reinstall.

                      Ok, this looks like the best option anyway.  I should be good then.

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post