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

PHP Fatal error: Uncaught ValueError: array_combine(): Argument #1 ($keys) and argument #2 ($values) must have the same number of elements in /usr/local/www/includes/functions.inc.php:93

Scheduled Pinned Locked Moved General pfSense Questions
12 Posts 2 Posters 1.4k 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.
  • D
    dopeytree
    last edited by Oct 23, 2023, 12:01 PM

    Took a few days to get a bug but getting this error:

    Crash report begins.  Anonymous machine information:
    
    amd64
    14.0-CURRENT
    FreeBSD 14.0-CURRENT #1 plus-RELENG_23_05_1-n256108-459fc493a87: Wed Jun 28 04:26:04 UTC 2023     root@freebsd:/var/jenkins/workspace/pfSense-Plus-snapshots-23_05_1-main/obj/amd64/f2Em2w3l/var/jenkins/workspace/pfSense-Plus-snapshots-23_05_1-main/sources/
    
    Crash report details:
    
    PHP Errors:
    [22-Oct-2023 23:58:30 Europe/London] PHP Fatal error:  Uncaught ValueError: array_combine(): Argument #1 ($keys) and argument #2 ($values) must have the same number of elements in /usr/local/www/includes/functions.inc.php:93
    Stack trace:
    #0 /usr/local/www/includes/functions.inc.php(93): array_combine(Array, Array)
    #1 /usr/local/www/xmlrpc.php(147) : eval()'d code(46): cpu_usage()
    #2 /usr/local/www/xmlrpc.php(147): eval()
    #3 /usr/local/share/pear/XML/RPC2/Server/CallHandler/Instance.php(141): pfsense_xmlrpc_server->exec_php('\nini_set('displ...')
    #4 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(135): XML_RPC2_Server_Callhandler_Instance->__call('pfsense.exec_ph...', Array)
    #5 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(99): XML_RPC2_Backend_Php_Server->getResponse()
    #6 /usr/local/www/xmlrpc.php(987): XML_RPC2_Backend_Php_Server->handleCall()
    #7 {main}
      thrown in /usr/local/www/includes/functions.inc.php on line 93
    [23-Oct-2023 12:14:28 Europe/London] PHP Fatal error:  Uncaught ValueError: array_combine(): Argument #1 ($keys) and argument #2 ($values) must have the same number of elements in /usr/local/www/includes/functions.inc.php:93
    Stack trace:
    #0 /usr/local/www/includes/functions.inc.php(93): array_combine(Array, Array)
    #1 /usr/local/www/xmlrpc.php(147) : eval()'d code(46): cpu_usage()
    #2 /usr/local/www/xmlrpc.php(147): eval()
    #3 /usr/local/share/pear/XML/RPC2/Server/CallHandler/Instance.php(141): pfsense_xmlrpc_server->exec_php('\nini_set('displ...')
    #4 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(135): XML_RPC2_Server_Callhandler_Instance->__call('pfsense.exec_ph...', Array)
    #5 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(99): XML_RPC2_Backend_Php_Server->getResponse()
    #6 /usr/local/www/xmlrpc.php(987): XML_RPC2_Backend_Php_Server->handleCall()
    #7 {main}
      thrown in /usr/local/www/includes/functions.inc.php on line 93
    
    
    
    No FreeBSD crash data found.
    
    1 Reply Last reply Reply Quote 0
    • S
      stephenw10 Netgate Administrator
      last edited by Oct 23, 2023, 1:03 PM

      That error is reported here but only along with others which more closely related to that bug: https://redmine.pfsense.org/issues/14648

      Is that the only php error you saw? Is that the only time you've seen it? What were you doing at the time?

      Steve

      D 1 Reply Last reply Oct 23, 2023, 4:35 PM Reply Quote 0
      • D
        dopeytree @stephenw10
        last edited by Oct 23, 2023, 4:35 PM

        @stephenw10

        Thanks.

        Before I was getting a memory php bug which is fixed with patching.
        https://forum.netgate.com/topic/183547/uncaught-divisionbyzeroerror/4?_=1698078621847

        I run PFblockerNG & NtoPNG so it could be caused by those?

        Not doing anything in particular just when I log in to check every few days it has these reports.

        No major system crashes.

        It just I didn't get these on the old machine which was this: https://www.jetwaycomputer.com/NF9HG.html
        vs this for new intel n100 machine: https://www.aliexpress.us/item/3256804950570517.html?spm=a2g0o.order_list.order_list_main.10.9ad21802DJB14L&gatewayAdapt=glo2usa4itemAdapt

        23.05.1-RELEASE (amd64)

        1 Reply Last reply Reply Quote 0
        • S
          stephenw10 Netgate Administrator
          last edited by Oct 23, 2023, 4:56 PM

          No it looks like the same issue with sysclts returning null values for some reason.

          Looking at all the report though it does look like it might be related to the CPU type. Everyone who has reported it seems to be using an Intel Nxxx CPU based system. 🤔

          D 1 Reply Last reply Oct 23, 2023, 9:59 PM Reply Quote 1
          • D
            dopeytree @stephenw10
            last edited by Oct 23, 2023, 9:59 PM

            @stephenw10

            Would it be helpful to most more logs or is there any other data I can help collect?

            1 Reply Last reply Reply Quote 0
            • S
              stephenw10 Netgate Administrator
              last edited by Oct 23, 2023, 10:49 PM

              I'm not sure there is anything more logged there right now.

              As with the other errors there I would try to replicate what's being called via sysctl there. However when we have previously done that it always returns the expected value.
              https://github.com/pfsense/pfsense/blob/master/src/usr/local/www/includes/functions.inc.php#L93

              So:

              [23.09-BETA][admin@6100.stevew.lan]/root: sysctl kern.cp_time
              kern.cp_time: 196916 11346 126361 1410 4276799
              

              Are you also running an Alder Lake-N CPU?

              D 1 Reply Last reply Oct 24, 2023, 2:32 PM Reply Quote 0
              • D
                dopeytree @stephenw10
                last edited by Oct 24, 2023, 2:32 PM

                @stephenw10 yes intel n100 is alder-lake.
                https://ark.intel.com/content/www/us/en/ark/products/231803/intel-processor-n100-6m-cache-up-to-3-40-ghz.html

                1 Reply Last reply Reply Quote 0
                • S
                  stephenw10 Netgate Administrator
                  last edited by Oct 24, 2023, 2:41 PM

                  Gah too many threads! I thought I'd seen you were running anN100 but failed to find it last night. We are investigating...

                  D 1 Reply Last reply Oct 24, 2023, 3:34 PM Reply Quote 1
                  • D
                    dopeytree @stephenw10
                    last edited by dopeytree Oct 24, 2023, 3:34 PM Oct 24, 2023, 3:34 PM

                    @stephenw10 No worries.

                    Got this one just now.

                    The odd thing is there is no 'opt1'.

                    This machine has 'igc0' - 'igc3'.

                    PHP ERROR: Type: 1, File: /etc/inc/pfsense-utils.inc, Line: 1730, Message: Uncaught TypeError: Unsupported operand types: string + null in /etc/inc/pfsense-utils.inc:1730
                    Stack trace:
                    #0 /usr/local/www/widgets/widgets/interfaces.widget.php(101): get_interface_info('opt1')
                    #1 /usr/local/www/index.php(430): include('/usr/local/www/...')
                    #2 {main}
                    thrown @ 2023-10-24 16:27:29
                    
                    1 Reply Last reply Reply Quote 0
                    • S
                      stephenw10 Netgate Administrator
                      last edited by Oct 24, 2023, 3:43 PM

                      @dopeytree said in PHP Fatal error: Uncaught ValueError: array_combine(): Argument #1 ($keys) and argument #2 ($values) must have the same number of elements in /usr/local/www/includes/functions.inc.php:93:

                      pfsense-utils.inc:1730

                      Hmm, that seems unrelated. No sysctls involved there that I can see: https://github.com/pfsense/pfsense/blob/master/src/etc/inc/pfsense-utils.inc#L1730

                      opt1 is the internal name, the first interface after wan and lan.

                      D 1 Reply Last reply Oct 26, 2023, 11:37 AM Reply Quote 0
                      • D
                        dopeytree @stephenw10
                        last edited by dopeytree Oct 26, 2023, 11:38 AM Oct 26, 2023, 11:37 AM

                        @stephenw10 Also for the record the n100 device came with opnsense preinstalled.

                        I chose to install pfsenseplus (as we were encouraged as a free upgrade to pfsenseCE) and this is was I had been running on the previous self build box. I'll probably now go to opnsense or another brand of firewall as can't afford $399 yearly for support on a home box (not commercial).

                        Although CE still exists as a 'free' option the drivers are or were behind especially 2.5GB drivers. and I highly expect it will be killed off in the future.

                        Would love to see negate update the hardware offerings with a small 4x port 2.5GB box at around $399-£599.
                        Or a new $129 yearly subscription like had been planned. This would then support the pfsenseplus brand too.

                        1 Reply Last reply Reply Quote 0
                        • S
                          stephenw10 Netgate Administrator
                          last edited by Oct 26, 2023, 12:29 PM

                          I understand. Thanks for the feedback.

                          1 Reply Last reply Reply Quote 0
                          12 out of 12
                          • First post
                            12/12
                            Last post
                          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
                            This community forum collects and processes your personal information.
                            consent.not_received