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

    Problems upgrading from 2.4.5 to 2.5.0

    Scheduled Pinned Locked Moved Problems Installing or Upgrading pfSense Software
    28 Posts 5 Posters 2.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.
    • P
      powerextreme
      last edited by

      Hello,

      Upgrading to 2.5.0 has not been successful on my APU.

      I tried to do an upgrade from the GUI and it said it was done. After reboot no traffic was being passed and I could not access GUI.

      I did a fresh install of 2.5.0 and it worked. However, when I tried to restore a backup config it would come back up. When I consoled into it if saw these errors:

      Fatal error: Uncaught Error: Cannot unset string offsets in /etc/inc/upgrade_config.inc:6361
      Stack trace:
      #0 /etc/inc/config.lib.inc(482): upgrade_212_to_213()
      #1 /etc/rc.bootup(126): convert_config()
      #2 {main}
        thrown in /etc/inc/upgrade_config.inc on line 6361
      PHP ERROR: Type: 1, File: /etc/inc/upgrade_config.inc, Line: 6361, Message: Uncaught Error: Cannot unset string offsets in /etc/inc/upgrade_config.inc:6361
      

      If I reinstall 2.4.5 and upload the same config it works fine. It seems like the 2.5.0 won't work with the old config file.

      So in summary the upgrade was not successful if:

      1. The upgrade was not operational if I upgraded from 2.4.5 to 2.5.0.
      2. A fresh install of 2.5.0 worked. However, if I restored a backup file from 2.4.5 it would no longer boot and had the errors above.

      Thanks!

      GertjanG 2 Replies Last reply Reply Quote 0
      • GertjanG
        Gertjan @powerextreme
        last edited by

        @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

        Message: Uncaught Error: Cannot unset string offsets in /etc/inc/upgrade_config.inc:6361

        Some ipsec parameters are getting ironed straight - as there could be some crinkles.
        If your not using ipsec, these messages are meaningless and can be ignored.
        If you were using ipsec : these messages are meaningless and can be ignored.

        No "help me" PM's please. Use the forum, the community will thank you.
        Edit : and where are the logs ??

        P 1 Reply Last reply Reply Quote 0
        • P
          powerextreme @Gertjan
          last edited by

          @gertjan
          I am not using IPSEC. I don't have any IPSEC setting set. I played with it earlier in the year but didn't use it. I just checked an there are no settings configured for IPSEC.

          There are other error that showed up. That was at the top.

          Any other ideas? Should I post the other errors?

          1 Reply Last reply Reply Quote 0
          • GertjanG
            Gertjan @powerextreme
            last edited by

            @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

            I am not using IPSEC. I don't have any IPSEC setting set.

            That's why you see these messages :

            @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

            Cannot unset string

            so, as said, you can neglect them.
            And before you ask : I agree, these lines could have been wrapped in a test so they execute when needed, and do not try to 'convert' a config setting that doesn't exist.

            @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

            Should I post the other errors?

            I guess we all saw the same (error) messages during upgrade.

            No "help me" PM's please. Use the forum, the community will thank you.
            Edit : and where are the logs ??

            P 1 Reply Last reply Reply Quote 0
            • P
              powerextreme @Gertjan
              last edited by

              @gertjan

              I attempted the upgrade from 2.4.5 with my backup config restored. I consoled into the APU and was able to watch the process. It looked like the system upgraded completed but I cannot access it via the webgui.
              Typically the console starts up with Screen Shot 2021-04-10 at 8.58.38 AM.png

              However, when the upgrade finished it showed up with:
              Screen Shot 2021-04-10 at 9.00.56 AM.png

              Any thoughts? If I do a fresh 2.4.5 install and upgrade it to 2.5.0 it works. It seems like problems occur when I try to restore my config.

              P 1 Reply Last reply Reply Quote 0
              • P
                powerextreme @powerextreme
                last edited by

                @powerextreme

                I reboot the device and these are the messages after pfsense logo appears:

                Screen Shot 2021-04-10 at 9.06.03 AM.png

                Any thoughts?

                P S 2 Replies Last reply Reply Quote 0
                • P
                  palesius @powerextreme
                  last edited by

                  I'm having EXACTLY the same issue.
                  Upgrade from 2.4.5 to 21.01 (which I believe is the pfSense Plus counterpart to 2.5.0).

                  Same messages about "cannot unset string offsets" and ending with a # prompt, but the firewall doesn't seem to actually come up.

                  1 Reply Last reply Reply Quote 0
                  • S
                    SteveITS Galactic Empire @powerextreme
                    last edited by

                    It's starting packages...are you uninstalling packages before upgrade as recommended?

                    Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                    When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                    Upvote 👍 helpful posts!

                    P 1 Reply Last reply Reply Quote 0
                    • P
                      powerextreme @SteveITS
                      last edited by

                      @steveits
                      Steve, thanks for the response. I don't understand. Prior to upgrading I am to uninstall all the packages I use?

                      P S 2 Replies Last reply Reply Quote 0
                      • P
                        palesius @powerextreme
                        last edited by

                        @powerextreme YMMV but this worked for me (having a similar issue):

                        find the line:

                        unset($ph1ent['reauth_enable'], $ph1ent['rekey_enable'], $ph1ent['margintime'], $ph1ent['over_time']);
                        

                        in /etc/inc/upgrade_config.inc

                        and replace with

                        		if (isset($ph1ent['reauth_enable'])) {
                        			unset($ph1ent['reauth_enable']);
                        		}
                        		if (isset($ph1ent['rekey_enable'])) {
                        			unset($ph1ent['rekey_enable']);
                        		}
                        		if (isset($ph1ent['margintime'])) {
                        			unset($ph1ent['margintime']);
                        		}
                        		if (isset($ph1ent['over_time'])) {
                        			unset($ph1ent['over_time']);
                        		}
                        

                        PHP isn't my 1st language, or even my 2nd/3rd, so there is undoubtedly a more concise way of doing this, but it got it past the upgrade and working again.

                        Basically it is now only doing the unset if it is actually necessary for each of those variables.

                        1 Reply Last reply Reply Quote 0
                        • S
                          SteveITS Galactic Empire @powerextreme
                          last edited by

                          @powerextreme Yes, uninstall packages first. I’m not saying that is the cause of your problems, just that it’s recommended. Packages I’ve used expect this and have a checkbox (default on) to keep settings after an uninstall.

                          Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                          When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                          Upvote 👍 helpful posts!

                          P 1 Reply Last reply Reply Quote 0
                          • P
                            powerextreme @SteveITS
                            last edited by

                            @steveits
                            So I reinstalled 2.4.5 and then restored my config. I see these messages in the console:

                            Screen Shot 2021-04-11 at 12.20.36 PM.png

                            I got a message saying that if re-installing packages is still taking a few hours then do a 'clear package lock'.

                            I went to check packages and pfblockerNG and an explanation mark next to it. I removed it. But the package removal screen says "Please wait while the update system initializes" and hangs there.

                            Seems to be an issue with packages. I can't really remove them...well at least pfblockerNG.

                            S GertjanG 2 Replies Last reply Reply Quote 0
                            • S
                              SteveITS Galactic Empire @powerextreme
                              last edited by

                              @powerextreme not sure about the messages. However did you change to “previous stable version” before installing packages (see my sig).

                              Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                              When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                              Upvote 👍 helpful posts!

                              1 Reply Last reply Reply Quote 0
                              • GertjanG
                                Gertjan @powerextreme
                                last edited by Gertjan

                                @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

                                So I reinstalled 2.4.5

                                That insures a clean setup.

                                @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

                                and then restored my config.

                                And that is the one that is good for a :

                                d07dba91-8de0-4354-9f4c-7def1ed36f45-image.png

                                @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

                                I got a message saying that if re-installing packages is still taking a few hours then do a 'clear package lock'.

                                Normally, it goes much faster then that.
                                But what about this method :
                                Before you load your own config, think, and ask yourself : "what packages had I installed ?". If you can't remember, look in your config.xml file : it lists them all.
                                Now, before doing anything else, install this list manually, one by one. No need to set them up.
                                When they are all installed, now load you config, and have it reboot.

                                You system comes up, totally ready.

                                No "help me" PM's please. Use the forum, the community will thank you.
                                Edit : and where are the logs ??

                                P 1 Reply Last reply Reply Quote 0
                                • P
                                  powerextreme @Gertjan
                                  last edited by

                                  @gertjan @SteveITS

                                  I am still having issues getting it to successfully upgrade. I did

                                  • list fresh install of 2.4.5.

                                  • Set the 'Settings->Update->Update Settings to Previous Stable Version (2.4.5 Deprecated)

                                  • Installed my packages (NTOP, pfBlockerNG, Iperf) and restored my config.
                                    [This setup worked once but not subsequent time]

                                  • Upgraded to 2.5.1. It would boot up and then end at the command prompt. The GUI was unavailable.

                                  My second idea was to install a fresh 2.5.1. and then install all those packages before restoring my config.
                                  I did the following:

                                  • Set the 'Settings->Update->Update Settings to Previous Stable Version (2.4.5 Deprecated)
                                  • Went to install Ntop and go an error:

                                  "WARNING: Current pkg repository has a new pHP major version. pfSense should be upgraded before installing any new Package"

                                  Could this a cause of my issues with upgrading? Is there a way to remove the references to these packages in my config files so they don't try to install them?

                                  S 1 Reply Last reply Reply Quote 0
                                  • P
                                    powerextreme
                                    last edited by

                                    I also tried a fresh install of 2.5.1 and installed all the packages. It worked fine. But when I restored my config it looks like it came up on the console but I can't access the GUI. The DHCP server isn't up. Packet captures show no responses to DHCP queries. The WAN isn't obtaining an address (via DHCP).

                                    I am really perplexed.

                                    P 1 Reply Last reply Reply Quote 0
                                    • S
                                      SteveITS Galactic Empire @powerextreme
                                      last edited by

                                      @powerextreme One must install packages for the version of pfSense in use. Netgate recommends uninstalling packages before upgrade, then reinstall. Many have an option to save or delete settings when uninstalling. It should work to install fresh and restore your configuration though.

                                      Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                                      When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                                      Upvote 👍 helpful posts!

                                      1 Reply Last reply Reply Quote 0
                                      • P
                                        palesius @powerextreme
                                        last edited by palesius

                                        @powerextreme Have you tried the changes to /etc/inc/upgrade_config.inc I suggested earlier?

                                        If you are seeing the Fatal error: Uncaught Error message, that may fix it.
                                        I had the same issue and no extra packages, and it fixed it for me. While it could be an issue with a package as well, it certainly looks like the same problem I was having, which had nothing to do with my packages.

                                        Simplest way would be to load 2.5.1 without your config (just use the default and get to the point where you can access it from the lan).

                                        download /etc/inc/upgrade_config.inc
                                        from diagnostics -> command line
                                        make your edits locally
                                        upload the changed file from that same page.
                                        run something like:

                                        mv /tmp/upgrade_config.inc /etc/inc/
                                        

                                        I think when you upload it that will be the path, I know it definitely tells you where it was uploaded once you upload, so if it didn't go into /tmp then you would need to change that command a tiny bit.

                                        P 1 Reply Last reply Reply Quote 0
                                        • P
                                          powerextreme @palesius
                                          last edited by

                                          @palesius

                                          I tried your fix and it worked! Thanks a lot for that!
                                          I have two more remote pfsense boxes at 2.4.5. Will I have to do the same thing for these two boxes?

                                          What did I do wrong? I was told is hold have removed all packages before an upgrade. Does this include point releases? On my own pfsense I have 2.5.0 and its asking to upgrade to 2.5.1. Should I uninstall all my packages for this upgrade?

                                          S 1 Reply Last reply Reply Quote 0
                                          • S
                                            SteveITS Galactic Empire @powerextreme
                                            last edited by

                                            @powerextreme said in Problems upgrading from 2.4.5 to 2.5.0:

                                            removed all packages before an upgrade. Does this include point releases?

                                            I asked this question before a few years ago and got some conflicting answers as I recall. I generally have uninstalled/reinstalled packages, to be safe.

                                            Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                                            When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                                            Upvote 👍 helpful posts!

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