Timeline for disable dhcpcd.service for static ip?
Current License: CC BY-SA 3.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jan 6, 2020 at 8:49 | comment | added | Ingo |
In /etc/dhcpcd.conf you configure dhcpcd to use a static ip address for eth0 and then you disable dhcpcd. This cannot work.
|
|
Jan 29, 2018 at 15:55 | comment | added | AlexOnLinux | I would not recommend to disable dhcpcd and do it manually. To do it manually you have to write a script.sh with the command that you want to be executed, one by one. The scrip.sh needs to be executed (oneshot) from systemd. How to do that you will find explained here in detail: unix.stackexchange.com/questions/47695/… | |
Jan 29, 2018 at 15:46 | comment | added | user3216577 | It seems dhcpcld.conf is not read when dhcpcd is disabled. Running the ip link, ip add and ip route commands manually does bring up eth0. Where can i add these so there are run at boot? (i'm still kind if new to systemd) | |
Jan 29, 2018 at 15:30 | comment | added | AlexOnLinux |
Have you tried to leave dhcpd enabled and checked the time it takes you to boot when you have a static ip assigned? To enable it sudo systemctl enable dhcpd . If you check goldilocks answer you will see, that he brings up eth0 manually. You could try the same with sudo ip link set eth0 up , but i am not sure if your dhcpd.conf will be read doing it this way.
|
|
Jan 29, 2018 at 15:23 | comment | added | user3216577 | Thanks for your answer. But now eth0 doesn't come 'up' after booting. | |
Jan 29, 2018 at 15:08 | history | answered | AlexOnLinux | CC BY-SA 3.0 |