You are not logged in.

#1 2016-07-04 10:32:50

michael_e
Member
Registered: 2016-07-04
Posts: 8

[SOLVED] netctl cannot establish wired connection

Hi there,

I've just installed Arch for the first time and it was easier than I thought it would be. However, I did not manage to  establish an internet connection via the netctl service.
When I boot up the system I cannot ping google or even my router. I am connected via ethernet to it. I copied the ethernet-dhcp from the examples folder to /etc/netctl.
The service config file look like this:

Interface=eno1
Connection=ethernet
IP=dhcp
#DHCPClient=dhcpcd
#DHCPReleaseOnStop=no
## for DHCPv6
#IP6=dhcp
#DHCP6Client=dhclient
## for IPv6 autoconfiguration
#IP6=stateless

when I try to start the service with netctl start ethernet-dhcp it does return an error:

Job for netctl@ethernet\x2ddhcp.service failed because the control process exited with error code.
See "systemctl status "netctl@ethernet\\x2ddhcp.service"" and "journalctl -xe" for details.

so I did, what the output told me to do and I typed in: systemctl status "netctl@ethernet\\x2ddhcp.service"
which gives me that:

● netctl@ethernet\x2ddhcp.service - Networking for netctl profile ethernet-dhcp
   Loaded: loaded (/etc/systemd/system/netctl@ethernet\x2ddhcp.service; enabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Mo 2016-07-04 13:53:59 CEST; 1min 49s ago
     Docs: man:netctl.profile(5)
  Process: 584 ExecStart=/usr/lib/network/network start %I (code=exited, status=1/FAILURE)
 Main PID: 584 (code=exited, status=1/FAILURE)

Jul 04 13:53:54 dagobah systemd[1]: Starting Networking for netctl profile ethernet-dhcp...
Jul 04 13:53:54 dagobah network[584]: Starting network profile 'ethernet-dhcp'...
Jul 04 13:53:59 dagobah network[584]: No connection found on interface 'eno1' (timeout)
Jul 04 13:53:59 dagobah network[584]: Failed to bring the network up for profile 'ethernet-dhcp'
Jul 04 13:53:59 dagobah systemd[1]: netctl@ethernet\x2ddhcp.service: Main process exited, code=exited, status=1/FAILURE
Jul 04 13:53:59 dagobah systemd[1]: Failed to start Networking for netctl profile ethernet-dhcp.
Jul 04 13:53:59 dagobah systemd[1]: netctl@ethernet\x2ddhcp.service: Unit entered failed state.
Jul 04 13:53:59 dagobah systemd[1]: netctl@ethernet\x2ddhcp.service: Failed with result 'exit-code'.

However I can use: dhcpcd eno1
which establishes a connection and I am able to surf the internet without any issues so my interface seems to work, also the other
components seem to be physically working smile I also enabled and reenabled the service  but then I see on startup a
red error message that netctl failed to do its job properly.

Any further advice would be very helpful! Thank you!

Last edited by michael_e (2016-07-07 15:40:48)

Offline

#2 2016-07-04 15:19:59

tmp-meteque
Member
Registered: 2015-12-11
Posts: 30

Re: [SOLVED] netctl cannot establish wired connection

You need dhcpd to stablish a working connection with netctl. Start and enable it with systemd.


IBM Lenovo T430

Offline

#3 2016-07-04 16:14:08

Starfish
Member
From: Germany
Registered: 2015-10-21
Posts: 134

Re: [SOLVED] netctl cannot establish wired connection

You shouldn't use dhcpcd and netctl simultaneously, but stick with one.
Could you paste the output of

ip link

?


"Yesterday is history, tomorrow is a mystery, but today is a gift. That is why it is called the present." - Master Oogway

Offline

#4 2016-07-04 21:38:54

Head_on_a_Stick
Member
From: The Wirral
Registered: 2014-02-20
Posts: 9,003
Website

Re: [SOLVED] netctl cannot establish wired connection

tmp-meteque wrote:

You need dhcpd to stablish a working connection with netctl.

This is not correct, netctl will call up dhcpcd as needed.

@OP: Please also post the output of:

systemctl list-unit-files --state=enabled

Jin, Jîyan, Azadî

Offline

#5 2016-07-05 08:26:39

michael_e
Member
Registered: 2016-07-04
Posts: 8

Re: [SOLVED] netctl cannot establish wired connection

Starfish wrote:

You shouldn't use dhcpcd and netctl simultaneously, but stick with one.
Could you paste the output of

ip link

?

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp11s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/ether 10:c3:7b:6d:a4:23 brd ff:ff:ff:ff:ff:ff
3: eno1: <BROADCAST,MULTICAST> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000
    link/ether 10:c3:7b:6d:a3:54 brd ff:ff:ff:ff:ff:ff

Output of

 systemctl list-unit-files --state=enabled 
UNIT FILE                          STATE  
org.cups.cupsd.path                enabled
acpid.service                      enabled
autovt@.service                    enabled
avahi-daemon.service               enabled
cronie.service                     enabled
dbus-org.freedesktop.Avahi.service enabled
getty@.service                     enabled
netctl@ethernet\x2ddhcp.service    enabled
netctl@ethernet\x2dstatic.service  enabled
ntpd.service                       enabled
org.cups.cupsd.service             enabled
avahi-daemon.socket                enabled
org.cups.cupsd.socket              enabled
remote-fs.target                   enabled

14 unit files listed.

Offline

#6 2016-07-05 09:13:58

Starfish
Member
From: Germany
Registered: 2015-10-21
Posts: 134

Re: [SOLVED] netctl cannot establish wired connection

michael_e wrote:
netctl@ethernet\x2ddhcp.service    enabled
netctl@ethernet\x2dstatic.service  enabled

That looks suspicious. You apparently have two services for the same connection, one being dynamic (dhcp) and one static. I could imagine that this causes collisions.
Try to stop and disable both and then retry to connect with the configuration file you posted on top.


"Yesterday is history, tomorrow is a mystery, but today is a gift. That is why it is called the present." - Master Oogway

Offline

#7 2016-07-05 09:40:25

michael_e
Member
Registered: 2016-07-04
Posts: 8

Re: [SOLVED] netctl cannot establish wired connection

Starfish wrote:
michael_e wrote:
netctl@ethernet\x2ddhcp.service    enabled
netctl@ethernet\x2dstatic.service  enabled

That looks suspicious. You apparently have two services for the same connection, one being dynamic (dhcp) and one static. I could imagine that this causes collisions.
Try to stop and disable both and then retry to connect with the configuration file you posted on top.

I tried that:

[michi@dagobah ~]$ sudo systemctl stop netctl@ethernet\x2ddhcp.service
[michi@dagobah ~]$ sudo systemctl stop netctl@ethernet\x2dstatic.service
[michi@dagobah ~]$ sudo systemctl disable netctl@ethernet\x2dstatic.service
[michi@dagobah ~]$ sudo systemctl disable netctl@ethernet\x2ddhcp.service

but

systemctl list-unit-files --state=enabled

gives me:

UNIT FILE                          STATE  
org.cups.cupsd.path                enabled
acpid.service                      enabled
autovt@.service                    enabled
avahi-daemon.service               enabled
cronie.service                     enabled
dbus-org.freedesktop.Avahi.service enabled
getty@.service                     enabled
netctl@ethernet\x2ddhcp.service    enabled
netctl@ethernet\x2dstatic.service  enabled
ntpd.service                       enabled
org.cups.cupsd.service             enabled
avahi-daemon.socket                enabled
org.cups.cupsd.socket              enabled
remote-fs.target                   enabled

14 unit files listed.

Offline

#8 2016-07-05 10:00:32

Starfish
Member
From: Germany
Registered: 2015-10-21
Posts: 134

Re: [SOLVED] netctl cannot establish wired connection

I remember having a similar problem, I think it was the stupid special characters.

michael_e wrote:
[michi@dagobah ~]$ sudo systemctl stop netctl@ethernet\x2ddhcp.service
[michi@dagobah ~]$ sudo systemctl stop netctl@ethernet\x2dstatic.service
[michi@dagobah ~]$ sudo systemctl disable netctl@ethernet\x2dstatic.service
[michi@dagobah ~]$ sudo systemctl disable netctl@ethernet\x2ddhcp.service

Could you try that again with "\\" instead of "\" and "\@" instead of "@"?


"Yesterday is history, tomorrow is a mystery, but today is a gift. That is why it is called the present." - Master Oogway

Offline

#9 2016-07-05 10:09:33

michael_e
Member
Registered: 2016-07-04
Posts: 8

Re: [SOLVED] netctl cannot establish wired connection

Starfish wrote:

I remember having a similar problem, I think it was the stupid special characters.

michael_e wrote:
[michi@dagobah ~]$ sudo systemctl stop netctl@ethernet\x2ddhcp.service
[michi@dagobah ~]$ sudo systemctl stop netctl@ethernet\x2dstatic.service
[michi@dagobah ~]$ sudo systemctl disable netctl@ethernet\x2dstatic.service
[michi@dagobah ~]$ sudo systemctl disable netctl@ethernet\x2ddhcp.service

Could you try that again with "\\" instead of "\" and "\@" instead of "@"?

That worked. I tried

netctl start ethernet-dhcp

right after that but still the same error.

Offline

#10 2016-07-05 10:41:13

Steef435
Member
Registered: 2013-08-29
Posts: 577
Website

Re: [SOLVED] netctl cannot establish wired connection

Did you stop dhcpcd before trying to start the netctl profile? If not, that could be the issue.

What's the output of "netctl status ethernet-dhcp" after you tried starting it? It may be a bit more verbose.

By the way, if dhcpcd works, you can also just use that. Using netctl to start it is not really a bonus here, you can simply use dhcpcd as a systemd service.

Offline

#11 2016-07-05 11:27:54

demaio
Member
From: Germany
Registered: 2012-09-02
Posts: 102
Website

Re: [SOLVED] netctl cannot establish wired connection

I recently had the same problem on my laptop (HP Elitebook 2560p). The solution was to add those two lines to /etc/netctl/ethernet-dhcp :

TimeoutUp=30
TimeoutCarrier=30

Offline

#12 2016-07-05 11:52:51

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

Re: [SOLVED] netctl cannot establish wired connection

Do you have the correct interface name in your netcfg config? The output of ip link suggests you have 2 wired interfaces, enp11s0 and eno1.


No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

#13 2016-07-05 14:48:40

michael_e
Member
Registered: 2016-07-04
Posts: 8

Re: [SOLVED] netctl cannot establish wired connection

demaio wrote:

I recently had the same problem on my laptop (HP Elitebook 2560p). The solution was to add those two lines to /etc/netctl/ethernet-dhcp :

TimeoutUp=30
TimeoutCarrier=30

That fixed it! Thank you!

What I also found out that adding (only) the following works, too:

 SkipNoCarrier=yes 

Apparently the program does not like unplugged interfaces??. As @Steef435 said I have those two interfaces, one intel, one realtek ethernet adapter.
Thank you all for your help smile

Offline

#14 2016-07-05 14:49:55

michael_e
Member
Registered: 2016-07-04
Posts: 8

Re: [SOLVED] netctl cannot establish wired connection

slithery wrote:

Do you have the correct interface name in your netcfg config? The output of ip link suggests you have 2 wired interfaces, enp11s0 and eno1.

Yes, common error, but in that case I always doublechecked wink

Offline

Board footer

Powered by FluxBB