Hello, when I run service network restart
, I get the following error:
# service network restart
Command failed: Not found
How can I troubleshoot it?
Hello, when I run service network restart
, I get the following error:
# service network restart
Command failed: Not found
How can I troubleshoot it?
How about running this command:
/etc/init.d/network restart
I get:
$ /etc/init.d/network restart
Command failed: Not found
What is the output of
ubus call system board
I believe it's a common issue for all PROCD-based init scripts which do not have real daemon.
I've asked a few times how this can be fixed, as it affects a few of my packages too.
{
"kernel": "5.15.147",
"hostname": "OpenWrt",
"system": "ARMv8 Processor rev 4",
"model": "Zyxel EX5601-T0 ubootmod",
"board_name": "zyxel,ex5601-t0-ubootmod",
"rootfs_type": "squashfs",
"release": {
"distribution": "OpenWrt",
"version": "SNAPSHOT",
"revision": "r24936-60ffcfdabc",
"target": "mediatek/filogic",
"description": "OpenWrt SNAPSHOT r24936-60ffcfdabc"
}
}
Is there a reason you want or need to run a snapshot? You might consider running a stable release instead -- the latest is 23.05.2
https://firmware-selector.openwrt.org/?version=23.05.2&target=mediatek%2Ffilogic&id=zyxel_ex5601-t0-stock
Not really. Is it something that isn’t expected to happen into the stable release?
Well, something isn't right in your current setup... I can't say if there is a bug that is unique to that snapshot, or if it is some other misconfiguration, but by upgrading to the stable release, we would expect that the init.d command should run as expected
I don't recall exactly but service
became an actual command certainly after 19.07.x
You can test its existance by typing type service
.
You should get:
/bin/service
[Edit -- I was wrong, see the conversation velow]
Where did the current firmware come from? I'm actually becoming quite confident that it is not from the OpenWrt project.
My reasoning is this... unless something went seriously corrupt or the ash shell has been replaced...
service
doesn't exist, but it should./etc/init.d/network restart
also doesn't seem to exist, and it should.compare that against:
root@openwrt:~#
Here, I'll intentionally misspell a the 'service' command as 'servicce' to get a not found error... see the difference?
root@openwrt:~# servicce
-ash: servicce: not found
For these reasons, I am wondering about the origin or contents of this particular installation.
I think the best action is to install the latest official stable release (do not keep settings) and configure from scratch.
I've been seeing a similar issue on my OpenWrt switches with snapshot, where restarting network complains about the 'wifi' command not being present. First time I'm seeing this as well. The ubus call system board
output looks squeaky clean to me.
What the error in the OP suggests is not that the service network restart
command failed; what it does suggest is that some subcommand did.
The u-boot mod variant only exists in main/master, not in 23.05.
I confirm that this firmware comes from the official OpenWRT stream. To be more detailed, I installed this release via the Attended Sysupgrade (ASU). I confirm that the prompt is root@OpenWrt:~#
in my case as well. In previous posts, I simply summarized it with $
or #
, sorry for the confusion.
I'd like to add a few details about the error, because the problem seems not caused by a "classic" not found error about the restart
. Please, note what happens with WiFi switched off:
root@OpenWrt:~# service network restart
'radio0' is disabled
'radio1' is disabled
Command failed: Not found
root@OpenWrt:~# /etc/init.d/network restart
'radio0' is disabled
'radio1' is disabled
Command failed: Not found
The command starts its execution, it hangs, and later it fails. Moreover, note that it takes a while before the message Command failed: Not found
shows up. It looks like the problem is related to one of the underlying operations triggered by the restart command.
Currently, ASU is experiencing a major issue and it can't be used for any upgrade. Moreover, in the FW selector I can't see the u-boot mod variant anymore. Pretty odd. However, I'm not sure that this issue is related to a problem with my snapshot release.
That message is usually harmless, it means that it tried to stop something that was not actually running.
Thanks. That's what I thought, but at the same time I was having trouble rectifying the specific responses from the OS.
Yes! this is what was missing from the OP's description... and you're right. I was mistaken.
Makes sense. Although if the OP doesn't need the u-boot mod version, they could go to stable.... but maybe that's not an option (or at least not a good one; I'm not familiar with this particular device so cannot speak to the necessity of the mod).
Thanks. My apologies for doubting that.
This view is much more helpful insofar as we can see that it is a subcommand that failed (per @Borromini's comment). I had been (mistakenly) under the impression that the entire command failed as not found.
Apologies all for the confusion I just caused. I edited my post above with strikethrough because it was wrong.
@psherman Nobody will fault you for removing it if you'd prefer so.
I am totally fine owning my mistakes, but also happy to remove. My reason for leaving it there is to maintain the context (although incorrect on my part) of the subsequent comments (I find that the strikethrough helps make it clear that it's wrong, but still maintains the logical flow of the conversation).
No worries, it was my fault!
Do you know what/how to use as a fake daemon in the daemon-less PROCD scripts to avoid this message?