Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan1" } (Permission denied)

Run shell command:

echo "2c7c 0125" >> /sys/bus/usb-serial/drivers/option1/new_id

After echo qmi usb options to /sys/bus/usb-serial/drivers/option1/new_id, the warnning message:

Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan1" } (Permission denied)

system log as follow:

Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.264033] usb 1-1: USB disconnect, device number 6
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.276225] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.294733] option 1-1:1.0: device disconnected
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.306801] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.325053] option 1-1:1.1: device disconnected
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.337204] option1 ttyUSB2: GSM modem (1-port) converter now disconnected from ttyUSB2
Sun Oct  8 04:28:10 [ 3632.541003] qmi_wwan 1-1:1.4 wwan0: unregister 'qmi_wwan' usb-101c0000.ehci-1, WWAN/QMI device
2023 kern.info kernel: [ 3632.355466] option 1-1:1.2: device disconnected
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.367602] option1 ttyUSB3: GSM modem (1-port) converter now disconnected from ttyUSB3
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.385856] option 1-1:1.3: device disconnected
Sun Oct  8 04:28:10 2023 daemon.notice netifd: Network device 'wwan0' link is down
Sun Oct  8 04:28:10 2023 daemon.notice netifd: Interface 'wan1' has link connectivity loss
Sun Oct  8 04:28:10 2023 kern.info kernel: [ 3632.541003] qmi_wwan 1-1:1.4 wwan0: unregister 'qmi_wwan' usb-101c0000.ehci-1, WWAN/QMI device
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: SIOCGIFINDEX: No such device
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: received SIGTERM
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: unicasting a release of 10.173.111.246 to 10.173.111.245
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: sending release
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: can't bind to interface wwan0: No such device
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: bindtodevice: No such device
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): udhcpc: entering released state
Sun Oct  8 04:28:11 2023 daemon.notice netifd: wan1 (6659): Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan1" } (Permission denied)

The system information:

OpenWrt 22.03.4
Linux OpenWrt 5.10.176 #0 Sun Apr 9 12:27:46 2023 mips GNU/Linux

Is it a bug in netifd? How to solve this problem?

Noticed I get the same error message in my logs when I plugged and unplugged my WAN port.


Tue Oct 17 22:57:09 2023 daemon.notice netifd: wan6 (2320): Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan6" } (Permission denied)

Tue Oct 17 22:57:09 2023 daemon.notice netifd: wan (2322): Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan" } (Permission denied)

root@DJ-OpenWRT:~# cat /etc/openwrt_release
DISTRIB_ID='OpenWrt'
DISTRIB_RELEASE='22.03.5'
DISTRIB_REVISION='r20134-5f15225c1e'
DISTRIB_TARGET='mediatek/mt7622'
DISTRIB_ARCH='aarch64_cortex-a53'
DISTRIB_DESCRIPTION='OpenWrt 22.03.5 r20134-5f15225c1e'
DISTRIB_TAINTS=''

Yes I think it is some sort of bug - I see this:

Tue Jan  9 17:40:46 2024 daemon.notice netifd: Network device 'wwan0' link is down
Tue Jan  9 17:40:46 2024 daemon.notice netifd: wan (17636): stopping network
Tue Jan  9 17:40:46 2024 daemon.notice netifd: wan (17636): running disconnection (common)
Tue Jan  9 17:40:46 2024 daemon.notice netifd: wan (17636): Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan" } (Permission denied)
Tue Jan  9 17:40:46 2024 daemon.notice netifd: wan (17636): successfully disconnected all bearers in the modem
Tue Jan  9 17:40:46 2024 daemon.notice netifd: wan (17636): Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan" } (Permission denied)
Tue Jan  9 17:40:46 2024 daemon.notice netifd: Interface 'wan' is now down

It has been flagged several times by several different users for some time now. It is not so easy to work out what is going wrong as the netifd code seems a little challenging to decipher.

2 Likes