Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Gentoo turns off ethernet link ligth during late boot
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Thu Dec 28, 2017 11:11 pm    Post subject: Gentoo turns off ethernet link ligth during late boot Reply with quote

Trying to switch to a new Internet connection. When the Gentoo laptop boots with the Ethernet cable of the new Internet connection, the link light at the laptop's Ethernet port is on. But during late boot (something after the kernel), it is turned off. If the cable is inserted when the system is already fully booted, no light is turned on.

When the cable of the old Internet connection is connected, there is light and everything works.

When the cable of the new Internet connection is connected to a borrowed laptop, there is light and everything works.

Why is the link light turned off during late boot? I use dhcpcd because it is easiest.
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5937

PostPosted: Fri Dec 29, 2017 2:47 am    Post subject: Reply with quote

could this be a 100mbit vs 1gbps thing?
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Fri Dec 29, 2017 3:53 pm    Post subject: Reply with quote

I rebuilt the kernel with QCOM_EMAC as a Yes instead of a Module and installed it. After boot it still turns off the link light.
Code:
dmesg|grep r8169
[    2.542205] r8169 Gigabit Ethernet driver 2.3LK-NAPI loaded
[    2.542606] r8169 0000:08:00.0 eth0: RTL8168d/8111d at 0xffffc900000e1000, 00:24:e8:ea:ad:d2, XID 081000c0 IRQ 17
[    2.542623] r8169 0000:08:00.0 eth0: jumbo features [frames: 9200 bytes, tx checksumming: ko]
[    9.529909] r8169 0000:08:00.0 enp8s0: renamed from eth0
[   21.468505] r8169 0000:08:00.0 enp8s0: link down
[   21.468514] r8169 0000:08:00.0 enp8s0: link down
Why is the link reported as down twice with only 9 microseconds between? Is the kernel OK? Should I try something other than dhcpcd?
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 4:01 pm    Post subject: Reply with quote

What ethtool tells about status of the connection?
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Fri Dec 29, 2017 4:27 pm    Post subject: Reply with quote

Code:
# ethtool enp8s0
Settings for enp8s0:
        Supported ports: [ TP MII ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Supported pause frame use: No
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Advertised pause frame use: Symmetric Receive-only
        Advertised auto-negotiation: Yes
        Speed: 10Mb/s
        Duplex: Half
        Port: MII
        PHYAD: 0
        Transceiver: internal
        Auto-negotiation: on
        Supports Wake-on: pumbg
        Wake-on: g
        Current message level: 0x00000033 (51)
                               drv probe ifdown ifup
        Link detected: no
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 4:30 pm    Post subject: Reply with quote

Code:
Link detected: no

Bad cable? Bad switch port at the other end?
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Fri Dec 29, 2017 4:44 pm    Post subject: Reply with quote

Unlikely that the cable breaks at the same time every boot of the Gentoo laptop while it works with the borrowed laptop.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 4:50 pm    Post subject: Reply with quote

But then again it works with old connection, something must be different with new connection because it cannot sense the physical connection. You could compare with ethtool output with working connection, maybe there is some clue.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Fri Dec 29, 2017 4:55 pm    Post subject: Reply with quote

Code:
# ethtool enp8s0
Settings for enp8s0:
        Supported ports: [ TP MII ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Supported pause frame use: No
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Advertised pause frame use: Symmetric Receive-only
        Advertised auto-negotiation: Yes
        Link partner advertised link modes:  10baseT/Half 10baseT/Full
                                             100baseT/Half 100baseT/Full
        Link partner advertised pause frame use: Symmetric
        Link partner advertised auto-negotiation: Yes
        Speed: 100Mb/s
        Duplex: Full
        Port: MII
        PHYAD: 0
        Transceiver: internal
        Auto-negotiation: on
        Supports Wake-on: pumbg
        Wake-on: g
        Current message level: 0x00000033 (51)
                               drv probe ifdown ifup
        Link detected: yes
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 4:58 pm    Post subject: Reply with quote

OK, it runs at 100 Mbit/s with old connection. Does the borrowed laptop show 100 Mbit/s also with new connection?
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Fri Dec 29, 2017 5:40 pm    Post subject: Reply with quote

There is no ethtool on the borrowed laptop, but I tested with www.bredbandskollen.se and it reported 118,20 Mbit/s download and 17,42 Mbit/s upload. So the Ethernet link must be more than 100 Mbit/s.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 6:01 pm    Post subject: Reply with quote

It is Gbit connection then. Here's what we know. Gentoo laptop works with 100 Mbit/s connection, but does not sense Gbit connection. What you make out of that. Bad laptop ethernet port, dirty or damaged connector pins? Have you tried to force 100 Mbit/s connection with new internet?
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
1clue
Advocate
Advocate


Joined: 05 Feb 2006
Posts: 2569

PostPosted: Fri Dec 29, 2017 6:37 pm    Post subject: Reply with quote

Probably a nothing point, but gigabit ethernet is full duplex only. Your supported modes says half duplex, which is not a standard ethernet mode. Maybe one nic is insisting on gigabit/half and the other side rejects it?

So where is the cable change?

  1. Do you have 2 separate routers/switches, two cables going to your laptop and then switch cables at the laptop port?
  2. Do you have 1 cable going to 2 separate switches/routers, switching the same cable between devices at the end opposite of Gentoo?
  3. Do you have a consistent connection from Gentoo to switch/router, and some other cable swap upstream?


What I'm getting at is this could be a bad cable or a bad port on a remote device.
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Fri Dec 29, 2017 6:58 pm    Post subject: Reply with quote

I have 1 cable, 102 meter, now covered by a lot of snow, frozen soil and a public road. Thankfully, it works. I even tried to put the router of the old Internet connection at one end and the Gentoo laptop at the other end. It worked. So it seems that the Gentoo laptop does not work with the router/switch of the new Internet connection.

I just succeeded to get an old discontinued dovado router connected to the new Internet connection after upgrading it to the final firmware version. The Gentoo laptop can connect to it, so I can use it with the new Internet connection. So I can now terminate the old Internet connection.

I suppose that it works because the old dovado can only do 100 Mbit/s. When I get a new router I may have to find out how to force the Gentoo laptop to not try 1 Gbit/s, which does not work for some reason.

Thans for all the help so far.
Back to top
View user's profile Send private message
1clue
Advocate
Advocate


Joined: 05 Feb 2006
Posts: 2569

PostPosted: Fri Dec 29, 2017 7:47 pm    Post subject: Reply with quote

OK can you tell me what cable spec your 102m cable is? Cat5? Cat5e? Cables have maximum throughput, and while it may not make much difference with a 2m cable it will certainly matter for 100m cable.

Have you actually tested that cable at gigabit speeds with a device at the other end? It's possible for a cable to be marginal -- good enough for 100 mbps but not good enough for gigabit. What sort of error count do you get from the connection when you do a speed test with the other system? Barring that, get a decent cable tester to make sure there are no broken wires in that long cable.

Try a speed test between your Gentoo laptop and some other device in your home, with cat5e cable or better. You should be able to get close to wire speed, 995 mbps or so.

Edit: You could also have water somewhere in that long cable, especially if it's barried without some sort of conduit.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 8:06 pm    Post subject: Reply with quote

1clue,

did you notice another laptop worked with this cable at Gbit speed. It would be interesting to see if there is packet loss, though.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
1clue
Advocate
Advocate


Joined: 05 Feb 2006
Posts: 2569

PostPosted: Fri Dec 29, 2017 8:47 pm    Post subject: Reply with quote

Sorry for being a pain.

What is at the other end of the link? Is it a WAN connection with a roughly 100 mbps contract? Or is it a LAN over there, with some other piece of gigabit-capable equipment you can test against? What is the stated speed of the device you're connected to? If your endpoint is only supposed to be 100mbps then I'll accept that and move on.

If I saw 118 mbps across that link and it was a switch at the other end with another group of equipment, I would not call that gigabit performance. It may or may not be better than 100mbps hardware can do, but as far as gigabit is concerned that is a distinctly poor transfer rate which needs to be addressed unless there is some data rate contract or piece of substandard hardware that can explain it. I wouldn't rule the cable speed out as a potential contributing factor for the connectivity issues.

Your cable's performance could be degraded by any number of things:

  1. A cat5 cable (100 mbps) instead of cat5e (gigabit) may work slightly better than rated speed over that distance, or it may be slower.
  2. Water in the cable will degrade speed
  3. Burying an indoor cable will eventually lead to a degraded connection.
  4. A kink in the cable
  5. A single broken wire can give gigabit in one direction and only 100mbps in the other.
  6. A smashed cable, where the insulators were flattened but not pierced, with wires pressed together, will change the capacitance briefly which translates to an attenuated signal. That would matter over that distance.
  7. Oxidized connectors, oxidized cables.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Fri Dec 29, 2017 9:26 pm    Post subject: Reply with quote

Yeah my bad, somehow I failed to notice the real speed. Cable is almost certainly the culprit here and the whole issue has nothing to do with software or operating system, hardware handshake is failing. The other laptop somehow manages to do it, but there must be huge packet loss, thus the actual speed is miserable.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54596
Location: 56N 3W

PostPosted: Fri Dec 29, 2017 9:56 pm    Post subject: Reply with quote

sigra,

Can you take the Gentoo laptop to the other end of your long cable and connect it with a short cable, just for testing.
Connect it to the same port as the long cable.

A 102 meter ethernet cable is over the maximum specification limit. It will need to be in pristine condition.
No kinks or other damage to cause reflections.

1G and 100Mbit both use the same symbol rate on the wire. 1G packs in more data per symbol and uses all eight wires but the clock speeds are identical.
10Mb and 100Mbit only use 4 of the eight wires. pins 1,2 3 and 6.

You mention snow on the cable. That will increase the transmission losses.

Use ethertool on the Gentoo system to force 10Mbit, then 100Mbit, with full and half duplex.
Keep an eye on the error rate at these low speeds.

If this is the first time that 1G has been attempted on the long cable, you no nothing about the 4 wires that have been lying unused.

At 10Mb and 100Mbit, you might get away with 4 random wires in use.
With 1G, the pairing is important, there is a lot more crosstalk when pairing is not honoured and !G has twice as many signals.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5937

PostPosted: Sun Dec 31, 2017 2:05 am    Post subject: Reply with quote

Try turning off auto negotiation for your switch as well.
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Sun Jan 07, 2018 5:24 pm    Post subject: Reply with quote

1clue wrote:
OK can you tell me what cable spec your 102m cable is? Cat5? Cat5e?
Code:
GIGAMEDIA - CATECORY 6 U/UTP LS0H Dca 4 PAIR 23AWG-EIA/TIA 568-C.2 CAT6 3P VERIFIED
Back to top
View user's profile Send private message
sigra
Tux's lil' helper
Tux's lil' helper


Joined: 03 Feb 2006
Posts: 137

PostPosted: Sun Jan 07, 2018 5:27 pm    Post subject: Reply with quote

1clue wrote:
Is it a WAN connection with a roughly 100 mbps contract?
100 Mbit/s download and 10 Mbit/s upload.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54596
Location: 56N 3W

PostPosted: Sun Jan 07, 2018 7:47 pm    Post subject: Reply with quote

sigra,

Your 100 Mbit/s download and 10 Mbit/s upload service can be terminated in a box that gives a 1G link to the 102m cable.
What does the equipment at the far end of the 102m cable provide?

If its a 1 Gbit link, it will use all 8 wires. If its only 100Mbit/10Mbit, it will only use wires 1,2 3 and 6.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum