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

    PHP Errors after latest update (amd64) built on Thu Jun 11 13:02:15 EDT 2020

    2.5 Development Snapshots (Retired)
    4
    22
    1.5k
    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.
    • R
      rpsmith
      last edited by rpsmith

      amd64
      12.1-STABLE
      FreeBSD 12.1-STABLE f1de4082be8(devel-12) pfSense

      Crash report details:

      PHP Errors:
      [11-Jun-2020 15:54:13 America/Chicago] PHP Warning: Invalid argument supplied for foreach() in /etc/rc.dyndns.update on line 52

      No FreeBSD crash data found.

      Update: Found "Default Check IP Service" was enabled (not by me). Error stopped after I disabled the service as I'm not using a dyndns service.
      Update2: I just rebooted the firewall and the same error is back.
      Update3: Thu Jun 11 19:03:16 EDT 2020 build has the same problem!

      1 Reply Last reply Reply Quote 0
      • R
        rpsmith
        last edited by

        Fri Jun 12 07:05:10 EDT 2020 build seems to have eliminated the error message. Thanks!

        1 Reply Last reply Reply Quote 0
        • NollipfSenseN
          NollipfSense
          last edited by

          No change for me ... for the last four or five days, including today after upgrade.

          Screen Shot 2020-06-12 at 8.05.13 PM.png

          pfSense+ 23.09 Lenovo Thinkcentre M93P SFF Quadcore i7 dual Raid-ZFS 128GB-SSD 32GB-RAM PCI-Intel i350-t4 NIC, -Intel QAT 8950.
          pfSense+ 23.09 VM-Proxmox, Dell Precision Xeon-W2155 Nvme 500GB-ZFS 128GB-RAM PCIe-Intel i350-t4, Intel QAT-8950, P-cloud.

          1 Reply Last reply Reply Quote 1
          • R
            rpsmith
            last edited by

            amd64
            12.1-STABLE
            FreeBSD 12.1-STABLE 06bf794ac10(devel-12) pfSense

            Crash report details:

            PHP Errors:
            [13-Jun-2020 00:03:00 America/Chicago] PHP Warning: Invalid argument supplied for foreach() in /etc/rc.dyndns.update on line 52

            I'm still getting the error with the latest build also. Doesn't seem like they are in any hurry to address it.

            1 Reply Last reply Reply Quote 0
            • R
              rpsmith
              last edited by

              amd64
              12.1-STABLE
              FreeBSD 12.1-STABLE 06bf794ac10(devel-12) pfSense

              Crash report details:

              PHP Errors:
              [13-Jun-2020 06:26:10 America/Chicago] PHP Warning: Invalid argument supplied for foreach() in /etc/rc.dyndns.update on line 52

              No FreeBSD crash data found.

              Do any of the real developers even check this forum?

              1 Reply Last reply Reply Quote 0
              • R
                rpsmith
                last edited by

                amd64
                12.1-STABLE
                FreeBSD 12.1-STABLE 06bf794ac10(devel-12) pfSense

                Crash report details:

                PHP Errors:
                [13-Jun-2020 14:24:07 America/Chicago] PHP Warning: Invalid argument supplied for foreach() in /etc/rc.dyndns.update on line 52

                built on Sat Jun 13 07:04:25 EDT 2020

                1 Reply Last reply Reply Quote 0
                • R
                  rpsmith
                  last edited by

                  2.5.0.a.20200613.1250

                  PHP Errors:
                  [13-Jun-2020 17:39:20 America/Chicago] PHP Warning: Invalid argument supplied for foreach() in /etc/rc.dyndns.update on line 52

                  1 Reply Last reply Reply Quote 0
                  • bmeeksB
                    bmeeks
                    last edited by

                    You guys will likely get more traction with these error reports if you open a Redmine Bug Report here: https://redmine.pfsense.org/. There is no guarantee that a pfSense developer closely follows this forum on a daily basis. They do look in from time to time, but the Redmine Bug site is the offical reporting and tracking mechanism for pfSense bugs.

                    1 Reply Last reply Reply Quote 1
                    • R
                      rpsmith
                      last edited by

                      Thanks! I was beginning to wonder if this was the correct place to report bugs. Regards, Roy...

                      1 Reply Last reply Reply Quote 0
                      • R
                        rpsmith
                        last edited by

                        No more PHP Errors after the last 2 updates! Many Thanks to the Coders! Regards, Roy...

                        ? NollipfSenseN 2 Replies Last reply Reply Quote 0
                        • ?
                          A Former User @rpsmith
                          last edited by

                          Added a comment to Issue #9435 which created the offending code, whether it should be a new Issue or reopening #9435 I'll leave to pfSense developers.

                          ? 1 Reply Last reply Reply Quote 1
                          • NollipfSenseN
                            NollipfSense @rpsmith
                            last edited by

                            @rpsmith said in PHP Errors after latest update (amd64) built on Thu Jun 11 13:02:15 EDT 2020:

                            No more PHP Errors after the last 2 updates! Many Thanks to the Coders! Regards, Roy...

                            Still getting it here!

                            Screen Shot 2020-06-13 at 11.33.24 PM.png

                            pfSense+ 23.09 Lenovo Thinkcentre M93P SFF Quadcore i7 dual Raid-ZFS 128GB-SSD 32GB-RAM PCI-Intel i350-t4 NIC, -Intel QAT 8950.
                            pfSense+ 23.09 VM-Proxmox, Dell Precision Xeon-W2155 Nvme 500GB-ZFS 128GB-RAM PCIe-Intel i350-t4, Intel QAT-8950, P-cloud.

                            1 Reply Last reply Reply Quote 1
                            • bmeeksB
                              bmeeks
                              last edited by bmeeks

                              This particular error you guys are receiving is actually a PHP Warning and is non-fatal. It is due to changes in PHP made in version 7.x that came out quite some time back. Trying to iterate an uninitialized PHP array is what generates this warning message. Older versions of PHP would, when presented with an uninitialized array, initialize an empty array on-the-fly for you and then iterate it (returning zero items because the array was empty, but key for us now was it would return no warning message either). For some reason the PHP crew upstream decided the new method from 7.x forward would be to throw a warning (and in later versions a fatal error) when this condition was encountered. So instead of creating an empty uninitialized array for you, the new PHP would throw this warning message for now. And in later PHP versions the plan is to make the error fatal.

                              There are many instances in the pfSense GUI code where PHP arrays are created and iterated. There was a concentrated effort right as PHP 7.x was being included in pfSense to find all of the potential problem areas with access of uninitialized arrays and fix them. Some of the problem areas still managed to slip through, though. There is also the case where it is a result of a particular user's config.xml file content that triggers the error. Explaining how and why gets a little deep into the weeds, but the short version is this particular warning message/error is hard to totally stamp out.

                              Report your findings on the Redmine site I linked in my ealier post and give any potentially relevant information such as "I once had a dynamic DNS client configured, but deleted it", or "I had a dynamic DNS cilent configured and changed/edited it", or whatever. It will help the developers track down the cause faster the more information you can give them.

                              NollipfSenseN 1 Reply Last reply Reply Quote 1
                              • R
                                rpsmith
                                last edited by

                                Thank you Sir! It's frustrating when you post about the same error over many days and no one takes the time to acknowledge the problem or point you in the proper direction.

                                Thanks again bmeeks! Roy...

                                1 Reply Last reply Reply Quote 0
                                • ?
                                  A Former User @A Former User
                                  last edited by

                                  @rschell said in PHP Errors after latest update (amd64) built on Thu Jun 11 13:02:15 EDT 2020:

                                  Added a comment to Issue #9435 which created the offending code, whether it should be a new Issue or reopening #9435 I'll leave to pfSense developers.

                                  @vktg revised the commit to #9435. I manually updated rc.dyndns.update and the crash no longer occurs for me.

                                  1 Reply Last reply Reply Quote 1
                                  • R
                                    rpsmith
                                    last edited by

                                    updated it with what?

                                    1 Reply Last reply Reply Quote 0
                                    • ?
                                      A Former User
                                      last edited by

                                      Pull Request #4356

                                      744d1d8b-647f-44e7-9ffb-9dc5452a1b93-image.png

                                      1 Reply Last reply Reply Quote 1
                                      • R
                                        rpsmith
                                        last edited by

                                        I guess what you're saying is remove the old line 52, 53 and 54 and replace them with the new lines that start with a + (i guess you can tell I'm not a programmer).

                                        Why would I not get an updated version of this file when I do a normal update from the dashboard? Roy...

                                        bmeeksB 1 Reply Last reply Reply Quote 0
                                        • bmeeksB
                                          bmeeks @rpsmith
                                          last edited by bmeeks

                                          @rpsmith said in PHP Errors after latest update (amd64) built on Thu Jun 11 13:02:15 EDT 2020:

                                          I guess what you're saying is remove the old line 52, 53 and 54 and replace them with the new lines that start with a + (i guess you can tell I'm not a programmer).

                                          Why would I not get an updated version of this file when I do a normal update from the dashboard? Roy...

                                          What @rschell posted is called a diff patch. It shows what lines of code are to be deleted and what new lines are to be added in their place.

                                          Specifically, what is shown in his post is the Pull Request from Viktor. A Pull Request is a formal code edit that is submitted by a developer to the "keeper" of the official code for review and eventual approval and inclusion in the master code base. So this Pull Request is awaiting approval. Once approved, it will be "merged" into the master code branch for pfSense-2.5 and will appear in the next snapshot published after the Pull Request is accepted by the code maintainer. At that point, when you install that new snapshot update, you will get the "fixed" file on your system.

                                          In the meantime, you can perform your own edits if you desire. But if you are not a seasoned programmer and familiar with diff patches and PHP in particular, I would suggest waiting for the publication of the official snapshot release that contains that fix. A wrong edit saved to the file can quickly turn a non-fatal warning message into a fatal PHP error that breaks the firewall GUI.

                                          1 Reply Last reply Reply Quote 2
                                          • R
                                            rpsmith
                                            last edited by

                                            It doesn't seem to be causing any real problem other than the warning message so I think I'll take your advice and just wait for it to be included in a future snapshot.

                                            Thanks bmeeks! Roy...

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