PHP warning
-
Fiddling with the QoS and this warning popped up afterward:
amd64 11.3-STABLE FreeBSD 11.3-STABLE #107 c3869060b4f(RELENG_2_4_5): Sat Feb 15 17:18:34 EST 2020 root@buildbot2-nyi.netgate.com:/build/ce-crossbuild-245/obj/amd64/IuZS8Bew/build/ce-crossbuild-245/sources/FreeBSD-src/sys/pfSense Crash report details: PHP Errors: [16-Feb-2020 17:22:17 America/Denver] PHP Warning: Use of undefined constant HFSC - assumed 'HFSC' (this will throw an Error in a future version of PHP) in /usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc on line 1111 [16-Feb-2020 17:22:17 America/Denver] PHP Warning: Invalid argument supplied for foreach() in /usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc on line 1554
-
That first error was definitely a problem in the source. The second I'm not quite sure how you might have triggered. I added a safety belt to prevent it from causing an error in the future at least.
https://github.com/pfsense/pfsense/commit/9d141b4de6a5760b88b94100aa216e0559a102fc
Do you remember exactly what options were chosen in the wizard when that second error showed up? Specifically, which options were selected on the VoIP screen, but if you have them all, I'd be curious to know what happened along the way there. I'd like to be able to reproduce the error here.
-
While I can't remember exactly what I did, I can output the applicable section from the backup xml. I think it is just php being a little more picky than it used to be in the older versions.
<shaper> <queue> <interface>wan</interface> <name>wan</name> <scheduler>HFSC</scheduler> <bandwidth>5.9</bandwidth> <bandwidthtype>Mb</bandwidthtype> <enabled>on</enabled> <queue> <name>qInternet</name> <interface>wan</interface> <bandwidth>5.9</bandwidth> <bandwidthtype>Mb</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>5.9Mb</linkshare3> <linkshare>on</linkshare> <upperlimit3>5.9Mb</upperlimit3> <upperlimit>on</upperlimit> <queue> <name>qACK</name> <interface>wan</interface> <priority>6</priority> <bandwidth>19.834</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>19.834%</linkshare3> <linkshare>on</linkshare> </queue> <queue> <name>qDefault</name> <interface>wan</interface> <priority>3</priority> <bandwidth>9.917</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <default>on</default> <ecn>on</ecn> </queue> <queue> <name>qP2P</name> <interface>wan</interface> <priority>1</priority> <bandwidth>4.9585</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>4.9585%</linkshare3> <linkshare>on</linkshare> <upperlimit3>4.9585%</upperlimit3> <upperlimit>on</upperlimit> </queue> <queue> <name>qVoIP</name> <interface>wan</interface> <priority>7</priority> <bandwidth>32</bandwidth> <bandwidthtype>Kb</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <realtime3>50Kb</realtime3> <realtime>on</realtime> </queue> <queue> <name>qGames</name> <interface>wan</interface> <priority>5</priority> <bandwidth>19.834</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>19.834%</linkshare3> <linkshare>on</linkshare> </queue> <queue> <name>qOthersHigh</name> <interface>wan</interface> <priority>4</priority> <bandwidth>9.917</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>9.917%</linkshare3> <linkshare>on</linkshare> </queue> <queue> <name>qOthersLow</name> <interface>wan</interface> <priority>2</priority> <bandwidth>4.9585</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>4.9585%</linkshare3> <linkshare>on</linkshare> </queue> </queue> </queue> <queue> <interface>lan</interface> <name>lan</name> <scheduler>HFSC</scheduler> <bandwidth>89128.96</bandwidth> <bandwidthtype>Kb</bandwidthtype> <enabled>on</enabled> <queue> <name>qLink</name> <interface>lan</interface> <qlimit>500</qlimit> <priority>2</priority> <bandwidth>20</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <default>on</default> <ecn>on</ecn> </queue> <queue> <name>qInternet</name> <interface>lan</interface> <bandwidth>71303.168</bandwidth> <bandwidthtype>Kb</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>71303.168Kb</linkshare3> <linkshare>on</linkshare> <upperlimit3>71303.168Kb</upperlimit3> <upperlimit>on</upperlimit> <queue> <name>qACK</name> <interface>lan</interface> <priority>6</priority> <bandwidth>19.992</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>19.992%</linkshare3> <linkshare>on</linkshare> </queue> <queue> <name>qP2P</name> <interface>lan</interface> <priority>1</priority> <bandwidth>4.998</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>4.998%</linkshare3> <linkshare>on</linkshare> <upperlimit3>4.998%</upperlimit3> <upperlimit>on</upperlimit> </queue> <queue> <name>qVoIP</name> <interface>lan</interface> <priority>7</priority> <bandwidth>32</bandwidth> <bandwidthtype>Kb</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <realtime3>50Kb</realtime3> <realtime>on</realtime> </queue> <queue> <name>qGames</name> <interface>lan</interface> <priority>5</priority> <bandwidth>19.992</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>19.992%</linkshare3> <linkshare>on</linkshare> </queue> <queue> <name>qOthersHigh</name> <interface>lan</interface> <priority>4</priority> <bandwidth>9.996</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>9.996%</linkshare3> <linkshare>on</linkshare> </queue> <queue> <name>qOthersLow</name> <interface>lan</interface> <priority>3</priority> <bandwidth>4.998</bandwidth> <bandwidthtype>%</bandwidthtype> <enabled>on</enabled> <ecn>on</ecn> <linkshare3>4.998%</linkshare3> <linkshare>on</linkshare> </queue> </queue> </queue> </shaper>
-
At any rate you seem to have fixed it up in the latest snapshot.
Also confirm that it doesn't trigger with PRIQ or CBQ on current.The behavior of going from E_NOTICE to E_WARNING for unquoted non-global strings is a noted feature of 7.2.x on the way toward deprecating the naked non-declared string entirely in the next version.
Now I'm curious if there are more undeclared in there or if I've found the needle in the haystack.
-
I think we found/fixed most of those unquoted strings some time ago, but there is always a possibility that more are lurking.
The
<shaper>
section wouldn't show what the wizard had in it that led to the original error, but if you look in<ezshaper>
that holds the wizard data.