You are not logged in.

#1 2021-01-04 04:08:11

grininmonkey
Member
Registered: 2018-09-29
Posts: 34

Gigabit Ethernet only in 100MB/s Mode

# lspci | grep Ethernet
02:00.0 Ethernet controller: Qualcomm Atheros Killer E2400 Gigabit Ethernet Controller (rev 10)
# dmesg | grep enp2s0
[    5.829055] alx 0000:02:00.0 enp2s0: renamed from eth0
[   17.818452] alx 0000:02:00.0 enp2s0: NIC Up: 100 Mbps Full
# ethtool enp2s0
Settings for enp2s0:
	Supported ports: [ TP ]
	Supported link modes:   10baseT/Half 10baseT/Full
	                        100baseT/Half 100baseT/Full
	                        1000baseT/Full
	Supported pause frame use: Symmetric Receive-only
	Supports auto-negotiation: Yes
	Supported FEC modes: Not reported
	Advertised link modes:  10baseT/Half 10baseT/Full
	                        100baseT/Half 100baseT/Full
	                        1000baseT/Full
	Advertised pause frame use: Symmetric
	Advertised auto-negotiation: Yes
	Advertised FEC modes: Not reported
	Speed: 100Mb/s
	Duplex: Full
	Auto-negotiation: on
	Port: Twisted Pair
	PHYAD: 0
	Transceiver: internal
	MDI-X: Unknown
        Current message level: 0x000060e4 (24804)
                               link ifup rx_err tx_err hw wol
	Link detected: yes

I tried swaping patch cables with another box off same switch, same cable works fine for other box in full 1000Mb/s but not the box with my issue so I can rule out faulty cable.

When I try to manually set it... it get the following...

# ethtool -s enp2s0 speed 1000 duplex full
netlink error: link settings update failed
netlink error: Invalid argument

Its a dumb switch, and I power cycled, etc... 4 other boxes are in 1000Mb/s mode just fine off the switch so... I am a bit stumped with this one...

Offline

#2 2021-01-04 09:09:23

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

Auto-negotiation: on

First ensure to bring the NIC down, then try

# ethtool -s enp2s0 autoneg offf speed 1000 duplex full

Online

#3 2021-01-04 12:50:41

grininmonkey
Member
Registered: 2018-09-29
Posts: 34

Re: Gigabit Ethernet only in 100MB/s Mode

I tried that via this first....

ip link set dev enp2s0 down

Then attempting any form / combination of ethtool -s results in the same message

# ethtool -s enp2s0 speed 1000 duplex full autoneg off
netlink error: link settings update failed
netlink error: Invalid argument

....

# ethtool -s enp2s0 speed 10 duplex full autoneg off
netlink error: link settings update failed
netlink error: Invalid argument

I also tried creating a NetworkManager system-connections for the named connection... which seems to have "NO" effect as well...

[connection]
id=Wired connection 1
uuid=4462661f-a2b5-3105-bd77-2d06938f770d
type=ethernet
autoconnect-priority=-999
interface-name=enp2s0
permissions=
timestamp=1609735993

[ethernet]
auto-negotiate=false
duplex=full
speed=1000
mac-address-blacklist=

[ipv4]
dns-search=
method=auto

[ipv6]
addr-gen-mode=stable-privacy
dns-search=
method=auto

Offline

#4 2021-01-04 13:40:24

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

creating a NetworkManager system-connections

If NM is still running, attempts to bring the NIC down will likely fail.
=> First stop NM and ensure no other NIC controlling service is running - in doubt post the output of

find /etc/systemd -type l -exec test -f {} \; -print | awk -F'/' '{ printf ("%-40s | %s\n", $(NF-0), $(NF-1)) }' | sort -f

to list enabled ones

Online

#5 2021-01-04 14:33:51

grininmonkey
Member
Registered: 2018-09-29
Posts: 34

Re: Gigabit Ethernet only in 100MB/s Mode

I disabled NetworkManager, rebooted and captured the following outputs

# dmesg | grep enp2s0
[    5.596209] alx 0000:02:00.0 enp2s0: renamed from eth0

# find /etc/systemd -type l -exec test -f {} \; -print | awk -F'/' '{ printf ("%-40s | %s\n", $(NF-0), $(NF-1)) }' | sort -f
dirmngr.socket                           | sockets.target.wants
getty@tty1.service                       | getty.target.wants
gpg-agent-browser.socket                 | sockets.target.wants
gpg-agent-extra.socket                   | sockets.target.wants
gpg-agent.socket                         | sockets.target.wants
gpg-agent-ssh.socket                     | sockets.target.wants
mssql-server.service                     | multi-user.target.wants
nginx.service                            | multi-user.target.wants
p11-kit-server.socket                    | sockets.target.wants
php-fpm.service                          | multi-user.target.wants
remote-fs.target                         | multi-user.target.wants
smb.service                              | multi-user.target.wants
sshd.service                             | multi-user.target.wants
wsdd.service                             | multi-user.target.wants

# ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp2s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/ether d8:cb:8a:9f:46:7a brd ff:ff:ff:ff:ff:ff

# ethtool -s enp2s0 speed 1000 duplex full autoneg off
netlink error: link settings update failed
netlink error: Invalid argument

Offline

#6 2021-01-04 14:45:33

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

Didn't completely read the thread, but seems related, https://www.mail-archive.com/netdev@vge … 58204.html

Did you try the lts kernel?

Online

#7 2021-01-04 14:58:03

grininmonkey
Member
Registered: 2018-09-29
Posts: 34

Re: Gigabit Ethernet only in 100MB/s Mode

have not tried lts... but another odd behavior I am getting is that I realized by accident when I logged in via a sudoer account vs root.... ethtool -s seems to work as long as I do not specify speed 1000... meaning I can sudo ethtool -s enp2s0 speed 10 duplex full autoneg off etc... but gets the error if I try to specify speed 1000...

But when logged in as root at tty1... ethtool returns the invalid argument "period" no matter what.

Offline

#8 2021-01-04 15:16:38

grininmonkey
Member
Registered: 2018-09-29
Posts: 34

Re: Gigabit Ethernet only in 100MB/s Mode

I installed lts and get the same end result, however the error response from ethtool/netlink is formatted differently ...

# ethtool -s enp2s0 speed 1000 duplex full autoneg off
Cannot set new settings: Invalid argument
   not setting speed
   not setting duplex
   not setting autoneg

under lts.... I also tried this

# ethtool -s enp2s0 speed 1000 
Cannot advertise speed 1000
Cannot set new settings: Invalid argument
  not setting speed

better verbose under lts.... anyway.....

Last edited by grininmonkey (2021-01-04 15:27:52)

Offline

#9 2021-01-04 15:55:11

grininmonkey
Member
Registered: 2018-09-29
Posts: 34

Re: Gigabit Ethernet only in 100MB/s Mode

Ok... I am both happy and puzzled...

Settings for enp2s0:
	Supported ports: [ TP ]
	Supported link modes:   10baseT/Half 10baseT/Full 
	                        100baseT/Half 100baseT/Full 
	                        1000baseT/Full 
	Supported pause frame use: Symmetric Receive-only
	Supports auto-negotiation: Yes
	Supported FEC modes: Not reported
	Advertised link modes:  10baseT/Half 10baseT/Full 
	                        100baseT/Half 100baseT/Full 
	                        1000baseT/Full 
	Advertised pause frame use: Symmetric
	Advertised auto-negotiation: Yes
	Advertised FEC modes: Not reported
	Speed: 1000Mb/s
	Duplex: Full
	Port: Twisted Pair
	PHYAD: 0
	Transceiver: internal
	Auto-negotiation: on
	MDI-X: Unknown
	Current message level: 0x000060e4 (24804)
			       link ifup rx_err tx_err hw wol
	Link detected: yes

I repeated the following with consistent results and I don't understand it.... my only assumption is that the NIC on the MB is simply a cable snob of some sorts and is extremely picky.

I have 5 devices with 1G nics plugged into my dumb switch... all using 6ft 5e patch cables. 4 ( original ) have had no issue linking at 1000, never once messed with this. The new box is a repurpose older MB/CPU that I originally ran Arch on more than a year ago before new hardware... just dusted it off and decided to do something with it...

So anyway... I was unplugging from my main computer and plugging that cable into this box with this issue and same with others... after just trying lts I thought... hey.. I do have a Cat6 cable... let me try for giggles and why not.... [ pow ] it linked @ 1000... so I then decided to reboot into mainline kernel... [ rut row ] will only link @ 100 with new Cat6 cable... reboot into lts and it links @ 1000 with Cat6 cable.... plug in any of the other 4 in use and working fine @ 1000 Cat5e cables... and nope.. only links @ 100...

This is the oddest network experience I have had so far.... its a 2016 MB i7 6700K and going to be a dev LEMP box.. so LTS is fine... but very weird none the less..

Last edited by grininmonkey (2021-01-04 16:01:05)

Offline

#10 2021-03-05 03:00:05

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

I have the same issue with the same driver.

I do not believe it's a cable issue, I've been using the same Cat7 cable for 2 years.

After some time, the adapter resets and the speed is stuck at 100mbs. No changes in the software can reset it, the only way I can reset it is to unplug the cable and plug it back in.

There's nothing obvious in dmesg:

[    8.495117] alx 0000:05:00.0 eth0: Qualcomm Atheros AR816x/AR817x Ethernet [e0:d5:5e:23:6c:9f]
[    8.510285] alx 0000:05:00.0 enp5s0: renamed from eth0
[   11.989920] alx 0000:05:00.0 enp5s0: NIC Up: 1 Gbps Full
[ 2453.620391] alx 0000:05:00.0 enp5s0: Link Down
[ 2473.519550] alx 0000:05:00.0 enp5s0: NIC Up: 100 Mbps Full
[ 3023.145846] alx 0000:05:00.0 enp5s0: Link Down
[ 3028.845658] alx 0000:05:00.0 enp5s0: NIC Up: 1 Gbps Full

On boot I got 1Gb, then after nearly an hour the adapter reset and changed to 100mbit. The second 1gb connection is me disconnecting and reconnecting the cable.

grininmonkey, have you noticed the same problem reoccur?

Offline

#11 2021-03-05 08:09:53

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

Full ethtool output under all circumstances (right after boot, after being dropped to 100MB and after the re-plug gets you back to 1GB)?
nb. that
- #1 it's always the cable (the plugs are part of the cable ;-)
- the link can fail or be reset on the other side as well (check the router log)

alx doesn't provide any parameters for power saving and I assume this isn't a notebook?

Online

#12 2021-03-09 19:48:00

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

alx doesn't provide any parameters for power saving and I assume this isn't a notebook?

It's a desktop.

alx 0000:05:00.0 eth0: Qualcomm Atheros AR816x/AR817x Ethernet [e0:d5:5e:23:6c:9f]

It took a while for this to happen this time

Boot:

Settings for enp5s0:
        Supported ports: [ TP ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Advertised pause frame use: Symmetric
        Advertised auto-negotiation: Yes
        Advertised FEC modes: Not reported
        Speed: 1000Mb/s
        Duplex: Full
        Auto-negotiation: on
        Port: Twisted Pair
        PHYAD: 0
        Transceiver: internal
        MDI-X: Unknown
        Current message level: 0x000060e4 (24804)
                               link ifup rx_err tx_err hw wol
        Link detected: yes

After issue:


Settings for enp5s0:
        Supported ports: [ TP ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Advertised pause frame use: Symmetric
        Advertised auto-negotiation: Yes
        Advertised FEC modes: Not reported
        Speed: 100Mb/s
        Duplex: Full
        Auto-negotiation: on
        Port: Twisted Pair
        PHYAD: 0
        Transceiver: internal
        MDI-X: Unknown
        Current message level: 0x000060e4 (24804)
                               link ifup rx_err tx_err hw wol
        Link detected: yes

After physical reconnect:

Settings for enp5s0:
        Supported ports: [ TP ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Advertised pause frame use: Symmetric
        Advertised auto-negotiation: Yes
        Advertised FEC modes: Not reported
        Speed: 1000Mb/s
        Duplex: Full
        Auto-negotiation: on
        Port: Twisted Pair
        PHYAD: 0
        Transceiver: internal
        MDI-X: Unknown
        Current message level: 0x000060e4 (24804)
                               link ifup rx_err tx_err hw wol
        Link detected: yes

        

The modes are being reported correctly, if I manually try to set 1000Mb using KDE's  NetworkManager GUI nothing happens. The only way I can get the full speed back is to disconnect and reconnect the cable.

Last edited by Tom B (2021-03-09 19:49:01)

Offline

#13 2021-03-09 21:12:16

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

They're the same but for the speed.
The link partner isn't in there, so that's suspicious.

Does it happen if you turn autoneg off, duplex full and speed 1000?
(With ethtool, so we see what actually happens, and *before* the incident)

Online

#14 2021-03-13 15:37:29

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

Again, it took a couple of days for this to happen again, but if I try to set the speed with ethtool, it gives me an error without any information about what the cause is:


# ethtool enp5s0
Settings for enp5s0:
        Supported ports: [ TP ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  Not reported
        Advertised pause frame use: No
        Advertised auto-negotiation: No
        Advertised FEC modes: Not reported
        Speed: 100Mb/s
        Duplex: Full
        Auto-negotiation: off
        Port: Twisted Pair
        PHYAD: 0
        Transceiver: internal
        MDI-X: Unknown
        Current message level: 0x000060e4 (24804)
                               link ifup rx_err tx_err hw wol
        Link detected: yes
sudo ethtool -s enp5s0 speed 1000 duplex full autoneg off
netlink error: link settings update failed
netlink error: Invalid argument

Autoneg on or off has the same effect. Setting speed to 100 works with autoneg on and off.

This is the same issue the original poster had, I cannot specify speed 1000, it always gives "Invalid argument". 100 works fine

sudo ethtool -s enp5s0 speed 100 duplex full autoneg off

Works successfully. With speed 1000 it gives "invalid argument"

Last edited by Tom B (2021-03-13 15:51:29)

Offline

#15 2021-03-13 16:56:58

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

Can you *before* the connection breaks down?
Do you have the opportunity to test against a different partner? (router, but maybe at least try a different port)

Online

#16 2021-03-13 19:24:02

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

I can't set 1000mb before the connection breaks, it gives the same "invalid argument" so may be an issue there.. If I set 100mb before it breaks, it works but I can't then set it to 1000 unless I disconnect and reconnect.

I've swapped it to a different port on the router, I've swapped the ports with another PC which hasn't had this issue and is also running arch, but has a realtek ethernet adapter.

I'll see if it breaks, but it does seem to be once every few days.

Offline

#17 2021-03-14 14:13:27

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

Same problem, it's just done it again in the other port. The other PC connected to the port this one was previously is still fine.

What I have noticed is that to reset the speed correctly I have to unplug the PC end, not the router end, reconnecting at the router end has no effect. I'm not sure why this would be, but perhaps physically disconnecting the PC causes something to reset.

Offline

#18 2021-03-14 15:07:05

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

What if you flip the cable (ie. switch the plugs for NIC and router)?

Online

#19 2021-03-19 15:58:02

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

I think this was a hardware issue after all. I tried a different cable entirely and had the same issue, however, after unplugging everything else from the motherboard apart from the ethernet cable,  keyboard and mouse, it hasn't happened.

It's only been a couple of days but it's definitely lasted longer than before. I wonder if something was causing some kind of electrical interference or perhaps there's a power issue where with too many things plugged in, the board can't supply enough power for everything at once and forces the network adapter to run at a lower power level (this is purely speculation, I have no idea if this is the case)

Offline

#20 2021-03-19 16:08:32

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

Mind to enumerate "everything else" (more bus and type than vendor/model)?

Online

#21 2021-03-19 16:40:27

Tom B
Member
Registered: 2014-01-15
Posts: 187
Website

Re: Gigabit Ethernet only in 100MB/s Mode

I'll give it a few days and try plugging everything back in one by one if it still hasn't disconnected my network, it might just be coincidence.

I have a USB-C 3.1 hub (which has its own power supply and is connected to 2x2 hard disk bays), USB wireless audio connector for my headphones, USB keyboard and USB wireless mouse receiver which I'd actually moved to front panel USB.  USB webcam, USB microphone. So actually, all USB.

Currently it just has the keyboard plugged in with the mouse plugged in to the front panel.

Last edited by Tom B (2021-03-19 16:53:02)

Offline

#22 2021-03-19 20:54:13

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: Gigabit Ethernet only in 100MB/s Mode

Nothing of that should™ be able to draw some serious power.
Are ethernet and the (internal) usb hub on the same bus? (lspci)
Could the headphone dongle radio interfere w/ the ethernet port/cable?
The external power supply of the external hub could leak some current into the system (if the HW is defective)…

Online

Board footer

Powered by FluxBB