[SOLVED] dhcpcd service not working

Having problems with the Gentoo Handbook? If you're still working your way through it, or just need some info before you start your install, this is the place. All other questions go elsewhere.
Post Reply
corona80
n00b
n00b
Posts: 17
Joined: Wed May 02, 2007 2:36 am

[SOLVED] dhcpcd service not working

Post by corona80 »

I have a new install with a strange dhcp issue. I must be missing some obvious setting, but it's eluded me.

Running rc-service dhcpcd start --verbose:

Code: Select all

...
start-stop-daemon: fopen '/var/run/dhcpcd/pid" No such file or directory
...
no valid interfaces found
But running "dhcpcd eno1" works perfectly.

Contents of /etc/config.d/net:

Code: Select all

net_eno1="dhcp"
Last edited by corona80 on Fri Apr 22, 2022 6:41 pm, edited 1 time in total.
grknight
Retired Dev
Retired Dev
Posts: 2549
Joined: Fri Feb 20, 2015 9:36 pm

Post by grknight »

Are you trying to start both the dhcpcd and net.eno1 services at the same time?

Please do not do this as they conflict and will fight over the interface.

Choose only one and disable the other one.
alamahant
Advocate
Advocate
Posts: 4032
Joined: Sat Mar 23, 2019 12:12 pm

Post by alamahant »

Plz try

Code: Select all

dmesg | grep eno
ip a
Is your iface clearly shown?
Is this a vm?
:)
corona80
n00b
n00b
Posts: 17
Joined: Wed May 02, 2007 2:36 am

Post by corona80 »

grknight wrote:Are you trying to start both the dhcpcd and net.eno1 services at the same time?

Please do not do this as they conflict and will fight over the interface.

Choose only one and disable the other one.
This was the problem. I mistakenly installed dhcpcd, thinking that was needed for dhcp.

Thanks for the help, and unreasonably fast replies.
grknight
Retired Dev
Retired Dev
Posts: 2549
Joined: Fri Feb 20, 2015 9:36 pm

Post by grknight »

corona80 wrote:
grknight wrote:Are you trying to start both the dhcpcd and net.eno1 services at the same time?

Please do not do this as they conflict and will fight over the interface.

Choose only one and disable the other one.
This was the problem. I mistakenly installed dhcpcd, thinking that was needed for dhcp.

Thanks for the help, and unreasonably fast replies.
You can install the package dhcpcd, but don't run 2 services that provide dhcp. netifrc (net.eno1 service here) will use dhcpcd if it exists on startup but do not start the dhcpcd service when using netifrc on the same interface.
corona80
n00b
n00b
Posts: 17
Joined: Wed May 02, 2007 2:36 am

Post by corona80 »

grknight wrote:You can install the package dhcpcd, but don't run 2 services that provide dhcp. netifrc (net.eno1 service here) will use dhcpcd if it exists on startup but do not start the dhcpcd service when using netifrc on the same interface.
Thanks for clarifying. I ended up removing the dhcpcd package. It was starting automatically, even after I removed it from the default runlevel. I did not look to see what was causing that. Perhaps it was another runlevel, or was getting pulled in as a dependency.

Honestly, I'm just coming back to Gentoo after a decade away, and the learning/relearning process is steep. And a lot of fun!
Post Reply