loader.conf.local entry gets removed
-
On the device I run pfSense+ 24.08-DEV on I added the following lines to get serial working:
console="efi" hw.uart.console="mm:0xfedc9000,rs:2"
'hw.uart.console ...' get's removed and therefore after a reboot I don't have any serial output.
In the file /etc/inc/pfsense-utils.inc I see that it's one of the entries getting removed by pfSense:
1155 function load_loader_conf($loader_conf = NULL, $local = false) { ... 1173 /* These values should be removed from loader.conf and loader.conf.local 1174 * As they will be replaced when necessary. */ 1175 $remove = array( ... 1184 "hw.uart.console",
In pfSense CE 2.7.2 it doesn't get remove, don't know about other pfSense+ version.
Any chance that pfSense could leave that setting alone?
-
Try this patch:
diff --git a/src/etc/inc/pfsense-utils.inc b/src/etc/inc/pfsense-utils.inc index 0b2d666210..f7b3302955 100644 --- a/src/etc/inc/pfsense-utils.inc +++ b/src/etc/inc/pfsense-utils.inc @@ -1181,7 +1181,6 @@ function load_loader_conf($loader_conf = NULL, $local = false) { "hw.e6000sw.default_disabled", "hw.hn.vf_transparent", "hw.hn.use_if_start", - "hw.uart.console", "hw.usb.no_pf", "net.pf.request_maxcount", "vm.pmap.pti", @@ -1208,6 +1207,7 @@ function load_loader_conf($loader_conf = NULL, $local = false) { "comconsole_speed", "comconsole_port", "console", + "hw.uart.console", "debug.ddb.capture.bufsize", "hint.uart.0.flags", "hint.uart.1.flags",
Edit:
Issue has been addressed in 24.08. -
@marcosm Thanks a lot for the quick reply and patch!
The patch applied cleanly and I will remove the immutable flag from loader.conf.local and reboot. But only after the football/soccer matches today :)
-
I have it a go between the two matches and it works excellent.
With the patch it is handled as I would like it to be: to remove it from loader.conf but not touch it if found in loader.conf.local.
Thanks again @marcosm.