You are not logged in.
Hi, awesome archlinux forum.
I have a strange dhcpcd problem that I just can't get my head around.
dhcpcd timeout when connected to a router.
For a time now I only had one computer connected towards internet but I recently got an extra computer, and thus needed a router. Hers the problem at the moment the first computer can't connect to the router but the other one can but when I remove the router the first computer can connect to the internet as usual.
First, I thought that it was a problem with the wire but I tested it with a cable tester and it was fine so that wasn't the problem. Then I started to dig in the terminal and found this.
Connected to the internet directly I get this from systemctl netctl-ifplugd@enp0s25.service
● netctl-ifplugd@enp0s25.service - Automatic wired network connection using netctl profiles
Loaded: loaded (/usr/lib/systemd/system/netctl-ifplugd@.service; enabled; vendor preset: disabled)
Active: active (running) since Wed 2018-09-19 17:24:15 CEST; 1 day 6h ago
Docs: man:netctl.special(7)
Main PID: 1897 (ifplugd)
Status: "online"
Tasks: 2 (limit: 4915)
CGroup: /system.slice/system-netctl\x2difplugd.slice/netctl-ifplugd@enp0s25.service
├─ 1897 /usr/bin/ifplugd -i enp0s25 -r /etc/ifplugd/netctl.action -bfIns
└─12061 dhcpcd -4 -q -t 30 -L enp0s25
Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.
Then connected through the router I got this for systemctl.
● netctl-ifplugd@enp0s25.service - Automatic wired network connection using netctl profiles
Loaded: loaded (/usr/lib/systemd/system/netctl-ifplugd@.service; enabled; vendor preset: disabled)
Active: active (running) since Mon 2018-09-24 22:20:23 CEST; 6min ago
Docs: man:netctl.special(7)
Main PID: 1856 (ifplugd)
Tasks: 1 (limit: 4915)
CGroup: /system.slice/system-netctl\x2difplugd.slice/netctl-ifplugd@enp0s25.service
└─1856 /usr/bin/ifplugd -i enp0s25 -r /etc/ifplugd/netctl.action -bfIns
Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.
As can be observed I'm missing the dhcpcd so then I started the commando from the terminal and got:
dhcpcd-7.0.8 starting
enp0s25: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' PREINIT
enp0s25: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' CARRIER
DUID 00:04:a0:96:9e:1d:84:c4:e3:11:bc:f3:f8:a9:63:0d:d4:fe
enp0s25: IAID 63:0d:d4:fe
enp0s25: delaying IPv4 for 0.2 seconds
enp0s25: reading lease `/var/lib/dhcpcd/enp0s25.lease'
enp0s25: discarding expired lease
enp0s25: soliciting a DHCP lease
enp0s25: sending DISCOVER (xid 0x5b061a4b), next in 3.7 seconds
enp0s25: sending DISCOVER (xid 0x5b061a4b), next in 7.5 seconds
enp0s25: sending DISCOVER (xid 0x5b061a4b), next in 16.5 seconds
enp0s25: sending DISCOVER (xid 0x5b061a4b), next in 32.5 seconds
timed out
dhcpcd exited
In dmesg I get the following message when I connect the router:
[ 91.967028] pci 0000:00:1c.5: bridge window [mem 0x9fd00000-0x9fefffff 64bit pref]
[ 91.967307] pci 0000:00:1c.5: PCI bridge to [bus 02]
[ 91.967317] pci 0000:00:1c.5: bridge window [io 0x4000-0x4fff]
[ 91.967327] pci 0000:00:1c.5: bridge window [mem 0xb0400000-0xb04fffff]
[ 91.967334] pci 0000:00:1c.5: bridge window [mem 0x9fd00000-0x9fefffff 64bit pref]
[ 120.358868] e1000e: enp0s25 NIC Link is Down
[ 120.578832] IPv6: ADDRCONF(NETDEV_UP): enp0s25: link is not ready
[ 122.146106] e1000e: enp0s25 NIC Link is Up 100 Mbps Full Duplex, Flow Control: Rx/Tx
[ 122.146114] e1000e 0000:00:19.0 enp0s25: 10/100 speed: disabling TSO
[ 122.146206] IPv6: ADDRCONF(NETDEV_CHANGE): enp0s25: link becomes ready
While the dmesg reports this while i connect without the router:
[ 91.967334] pci 0000:00:1c.5: bridge window [mem 0x9fd00000-0x9fefffff 64bit pref]
[ 120.358868] e1000e: enp0s25 NIC Link is Down
[ 120.578832] IPv6: ADDRCONF(NETDEV_UP): enp0s25: link is not ready
[ 122.146106] e1000e: enp0s25 NIC Link is Up 100 Mbps Full Duplex, Flow Control: Rx/Tx
[ 122.146114] e1000e 0000:00:19.0 enp0s25: 10/100 speed: disabling TSO
[ 122.146206] IPv6: ADDRCONF(NETDEV_CHANGE): enp0s25: link becomes ready
[ 522.385021] e1000e: enp0s25 NIC Link is Down
[ 535.357767] e1000e: enp0s25 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: None
[ 911.606460] audit: type=1130 audit(1537821330.105:80): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-tmpfiles-clean comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
[ 911.606478] audit: type=1131 audit(1537821330.105:81): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-tmpfiles-clean comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
So anyone knows what's going on?
Thank you in advance.
Edit: Solution was to install dhclient and start that on the connection.
Last edited by r00tr4t (2018-09-27 21:35:11)
Offline
Please edit your thread title to actually describe your issue: https://wiki.archlinux.org/index.php/Co … ow_to_post
Offline
I only had one computer connected towards internet but I recently got an extra computer, and thus needed a router.
Are all 3 MAC and IP addresses unique? They should be.
Offline
Please edit your thread title to actually describe your issue: https://wiki.archlinux.org/index.php/Co … ow_to_post
Better?
Offline
r00tr4t wrote:I only had one computer connected towards internet but I recently got an extra computer, and thus needed a router.
Are all 3 MAC and IP addresses unique? They should be.
Yes. Right now the other computer isn't home but still, the first computer can't connect to the internet.
(my android phone works tho.)
Offline
I only had one computer connected towards internet
What provided the Internet connectivity, when you didn't have a router?
What is the DHCP server? Are there now 2 conflicting DHCP servers?
Tcpdump will help you to debug.
You're providing very little debugging information
Edit: If your router is of low quality, then it might be choking on Explicit Congestion Notification, so try disabling it.
Last edited by brebs (2018-09-25 06:58:20)
Offline
r00tr4t wrote:I only had one computer connected towards internet
What provided the Internet connectivity, when you didn't have a router?
What is the DHCP server? Are there now 2 conflicting DHCP servers?
Tcpdump will help you to debug.
You're providing very little debugging information
Edit: If your router is of low quality, then it might be choking on Explicit Congestion Notification, so try disabling it.
Sorry for a late reply.
Right now I'm connected to the internet directly on my ISP box with a public IP that could be accessed from the internet.
When the router is connected between my computer and the ISP box this computer doesn't get an IP from the router.
Btw the router is an:
Dlink DIR-809 Wireless AC750
lspci -v reported:
00:19.0 Ethernet controller: Intel Corporation Ethernet Connection I218-LM (rev 04)
Subsystem: Acer Incorporated [ALI] Ethernet Connection I218-LM
Flags: bus master, fast devsel, latency 0, IRQ 45
Memory at b0600000 (32-bit, non-prefetchable) [size=128K]
Memory at b063d000 (32-bit, non-prefetchable) [size=4K]
I/O ports at 3080 [size=32]
Capabilities: <access denied>
Kernel driver in use: e1000e
Kernel modules: e1000e
ip addr when I try to connect to the local lan:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp0s25: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
link/ether xx:xx:xx:xx:xx:xx brd ff:ff:ff:ff:ff:ff
inet6 xxxx::xxxx:xxxx:xxxx:xxx/64 scope link
valid_lft forever preferred_lft forever
3: wlp1s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
link/ether 80:86:f2:72:c3:33 brd ff:ff:ff:ff:ff:ff
4: docker0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
link/ether 02:42:63:4c:d4:9a brd ff:ff:ff:ff:ff:ff
inet xxx.xxx.xxx.xxx/16 brd xxx.xxx.xxx.xxx scope global docker0
valid_lft forever preferred_lft forever
But with without the router I get the folowing:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp0s25: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
link/ether xx:xx:xx:xx:xx:xx brd ff:ff:ff:ff:ff:ff
inet xxx.xxx.xxx.xxx/25 brd xxx.xxx.xxx.xxx scope global noprefixroute enp0s25
valid_lft forever preferred_lft forever
inet6 fe80::faa9:63ff:fe0d:d4fe/64 scope link
valid_lft forever preferred_lft forever
3: wlp1s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
link/ether 80:86:f2:72:c3:33 brd ff:ff:ff:ff:ff:ff
4: docker0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
link/ether 02:42:63:4c:d4:9a brd ff:ff:ff:ff:ff:ff
inet xxx.xxx.xxx.xxx/16 brd xxx.xxx.xxx.xxx scope global docker0
valid_lft forever preferred_lft forever
My addresses have been xxx-ed out.
$ uname -r
4.18.8-arch1-1-ARCH
The Explicit Congestion Notification you told me about was set to 1, but changing it to 0 did not seem to do anything. But do I need to make the change persistent on reboot to be able to use it?
$ sudo sysctl net.ipv4.tcp_ecn
net.ipv4.tcp_ecn = 1
Tried to understand the tpcdump tool but the data for my untrained eye was inconclusive.
Can I provide any more information that is relevant to the situation?
Offline
Why did you add a router?
Why not keep with the "one computer" (which already worked), and have that one computer share out its Internet connecction with the 2nd computer.
With a router, you are going from non-NAT to NAT, which is obviously confusing you
Edit: Hiding all the IP addresses, hinders debugging
Last edited by brebs (2018-09-25 20:57:35)
Offline
Why did you add a router?
Why not keep with the "one computer" (which already worked), and have that one computer share out its Internet connecction with the 2nd computer.
With a router, you are going from non-NAT to NAT, which is obviously confusing you
Edit: Hiding all the IP addresses, hinders debugging
Well, there I am in a catch 22 because I need the router to configure the other computer (proxmox).
Sorry for hiding the ip but as long as I don't have a router I don't like to share my ip with the internet.
Offline
Remove the router and run "sudo nmap --script broadcast-dhcp-discover" to check if there's another dhcp server - and where.
If there's none, try whether "dhcpcd -D" or "dhclient" can solicit a lease. (Try both, but not at the same time!)
Also and especially try to get a lease WITHOUT running the proxmox server (or anything else) in the network.
Offline
Remove the router and run "sudo nmap --script broadcast-dhcp-discover" to check if there's another dhcp server - and where.
If there's none, try whether "dhcpcd -D" or "dhclient" can solicit a lease. (Try both, but not at the same time!)
Also and especially try to get a lease WITHOUT running the proxmox server (or anything else) in the network.
Nothing else is currently connected to my network, just my laptop.
I will try those commands when I get home in a few hours.
So until then thanks for replying.
Offline
$ sudo nmap --script broadcast-dhcp-discover -e enp0s25 | tee dlink_nmap.text
Starting Nmap 7.70 ( https://nmap.org ) at 2018-09-26 21:07 CEST
Pre-scan script results:
| broadcast-dhcp-discover:
| Response 1 of 1:
| IP Offered: 192.168.0.107
| DHCP Message Type: DHCPOFFER
| Server Identifier: 192.168.0.1
| Subnet Mask: 255.255.255.0
| IP Address Lease Time: 1s
| Domain Name: dlinkrouter
| Option Overload: 3
| Router: 192.168.0.1
| Domain Name Server: 192.168.0.1
| Renewal Time Value: 0s
|_ Rebinding Time Value: 0s
Nmap done: 0 IP addresses (0 hosts up) scanned in 2.36 seconds
That was interesting. Why isn't my computer accepting the offered ip address from the router but accepts the ip from the isp? o.O?
Offline
Wait, this output is /with/ the router, is it?
In that case, all we learned is that the router has a working dhcp server that is willing to offer your system 192.168.0.107 (which is not necessary the IP you ultimately get on a real request, the router might have MAC/hostname specific rules)
We do not know whether there's maybe a second ("rogue") dhcp server around.
As of the ISPs IP - this IP is usually provided to your router which will provide NAT to the systems behind it.
Ie. if you eg. check https://www.whatismyip.com/ - the external IP is actually your router.
Please do the nmap check *without* the router and the "dhcpcd -D" and "dhclient" approaches *with* the router and only if nmap doesn't reveal another dhcp server in your LAN (ie. any dhcp server that would end up "outside", as of eg. provided by your ISP, is irrelevant)
Offline
I am in a catch 22 because I need the router to configure the other computer (proxmox).
Why is the router needed? What can't be done using the "first" computer?
Offline
Woot. I think I just solved it.
$ dhclient
bash: dhclient: command not found
$ sudo pacman -S dhclient
Then I swapped to the router and tried.
$ dhclient
Then it worked. o.O?
But why. Why does it work without dhclient when I connect to the internet directly?
How do I configure the if-pluged to work with dhclient?
Thank you for the help.
(Will mark this thread as solved in the morning now I need to sleep.)
Offline
It related to the interpretation of the dhcp protocol, specifically by the router.
Try "dhcpcd -D" (consult the manpage on DUID, you can configure dhcpcd tp use it w/o further switches)
Offline