lido
March 7, 2018, 5:55pm
1
Hello. I wanted to change my router hostname, so I checked https://openwrt.org/docs/guide-user/base-system/system_configuration and did as told there, that is, to change the /etc/config/system
file. After saving, I noticed the previous name was still in use, and the new name was not. So I did as told on https://forum.openwrt.org/viewtopic.php?id=14620 and did uci commit
and uci commit system
. However, the previous name is still in use.
The Open-WRT forum topic doesn't tell how to apply the new hostname without the need to restart the system. Is it possible? How can I do that?
1 Like
mikma
March 7, 2018, 6:46pm
3
This works for me:
uci set system.@system[0].hostname='insert-hostname'
uci commit system
/etc/init.d/system reload
3 Likes
I found your commands on a site that says:
Note: this paragraph is meant for routers with old firmware, that may not have 'pretty-hostname', yet.
@lido , please let us know how it works.
mk24
March 7, 2018, 9:59pm
5
/etc/init.d/system restart should apply the new name. You should see the new name immediately in the next prompt. This is not a reboot.
3 Likes
lido
March 7, 2018, 10:21pm
6
Exactly what I needed! Thank you, problem solved.
By the name of the command (restart) I would indeed believe it would be a reboot. But it's not. It's as you said.
1 Like
tmomas
Closed
March 12, 2018, 5:00pm
7
This topic was automatically closed after 4 days. New replies are no longer allowed.