OpenWrt 21.02 default configuration for loopback interface

I upgraded my TP Link Archer C50 v4 router to 21.02 and found following configuration for the loopback interface

config interface 'loopback'
	option device 'lo'
	option proto 'static'
	option ipaddr '127.0.0.1'
	option netmask '255.0.0.0'

The configuration contains option device lo but there is no devicesection in /etc/config/network unlike for the the bridge interface (br-lan).

config interface 'loopback'
	option device 'lo'
	option proto 'static'
	option ipaddr '127.0.0.1'
	option netmask '255.0.0.0'

config globals 'globals'
	option ula_prefix 'fd61:4641:a698::/48'

config device
	option name 'br-lan'
	option type 'bridge'
	list ports 'eth0.1'

config interface 'lan'
	option device 'br-lan'
	option proto 'static'
	option ipaddr '192.168.1.1'
	option netmask '255.255.255.0'
	option ip6assign '60'

config device
	option name 'eth0.2'
	option macaddr 'e4:c3:2a:90:84:98'

config interface 'wan'
	option device 'eth0.2'
	option proto 'dhcp'

config interface 'wan6'
	option device 'eth0.2'
	option proto 'dhcpv6'

config switch
	option name 'switch0'
	option reset '1'
	option enable_vlan '1'

config switch_vlan
	option device 'switch0'
	option vlan '1'
	option ports '1 2 3 4 6t'

config switch_vlan
	option device 'switch0'
	option vlan '2'
	option ports '0 6t'

Shouldn't a device like following needs to be present for option device 'lo' to have any effect?

config device 'device_lo'
    option name 'lo'
  • Is your lo not working or some other issue?
  • Do you see it with ifconfig lo?

That is the correct default config.

1 Like

Mine is exactly the same, everything is working fine on my systems. (checked on a RouterStation Pro with 21.02.2)

1 Like