Bug #12539
openChanging VLAN ID for LAN interface in assignments silently fails.
0%
Description
Hi
Recently I changed my VLAN ID that I use for my LAN interface, this was to follow advice given to me a long time ago on the community forum for a unrelated issue.
The process I followed was.
1 - Add the new VLAN tag in VLAN interfaces.
2 - Go to the assignments screen.
3 - Change the LAN interface to the new Virtual Interface.
4 - Click save
5 - Click apply
This proceeds but on page reload the actual VLAN doesnt change without an error present.
I also tried to do this in the console using the built in assign interfaces option, this also did not present an error warning but just silently failed.
After scratching my head for a while I checked the logs and this revealed the reason it failed was because the interface was still been referenced in other parts of configuration such as firewall and route configuration. I cannot remember the specific sorry, as it was two weeks ago and I delayed doing the bug report.
The solution was for me to manually disable the LAN interface, make the change, then enable it again.
So I suspect some kind of sanity check needs adding to prevent this and to show the warning in the GUI (and command interface), or to change the process so it disables the interface, reconfigures and then enables again.
If you need the specifics, I will retest it and get you the specific log output.
Updated by Viktor Gurov about 3 years ago
I saw the same issue on 22.01.a.20211119.0600, with the same workaround, but couldn't reproduce again
I think something wrong with this part of code:
https://github.com/pfsense/pfsense/blob/master/src/usr/local/www/interfaces_vlan_edit.php#L131-L145
Updated by Viktor Gurov about 3 years ago
Chris Collins wrote:
If you need the specifics, I will retest it and get you the specific log output.
Please try to reproduce and provide `tail -n 50 /var/log/system.log` output