LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 11-15-2017, 04:34 AM   #1
karthik_kk
LQ Newbie
 
Registered: Nov 2017
Posts: 3

Rep: Reputation: Disabled
Fibre Optic port moving to 1000Mb/s eventhough it is not listed in the supported link mode in LXT971A Cortina Transceiver


In my Fibre Optic device (Linux 2.6.27, LXT971A PHY Transceiver), connection to the port is lost intermittently. While debugging with ETHtool, the following observation was observed:

Settings for eth0:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Supported pause frame use: No
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Advertised pause frame use: No
Advertised auto-negotiation: Yes
Speed: 1000Mb/s
Duplex: Full
Port: MII
PHYAD: 0
Transceiver: external
Auto-negotiation: off
Link detected: yes

The Switch used (ruggedcom) supports only 100Mb/s FULL DUPLEX . Why is the speed moved to 1000Mb/s and the link detected is "yes" ? After this stage is reached the port will not try any other speed and stays in 1000Mb/s until device restart. Please note that the issue is observed only with a FO cable of length 30m or more and works fine with FO cable of length 2m.

Any comments or insights are greatly appreciated.
 
Old 11-15-2017, 09:16 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,134
Blog Entries: 14

Rep: Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265
Quote:
Originally Posted by karthik_kk View Post
In my Fibre Optic device (Linux 2.6.27, LXT971A PHY Transceiver), connection to the port is lost intermittently. While debugging with ETHtool, the following observation was observed:

Settings for eth0:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Supported pause frame use: No
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Advertised pause frame use: No
Advertised auto-negotiation: Yes
Speed: 1000Mb/s
Duplex: Full
Port: MII
PHYAD: 0
Transceiver: external
Auto-negotiation: off
Link detected: yes

The Switch used (ruggedcom) supports only 100Mb/s FULL DUPLEX . Why is the speed moved to 1000Mb/s and the link detected is "yes" ? After this stage is reached the port will not try any other speed and stays in 1000Mb/s until device restart. Please note that the issue is observed only with a FO cable of length 30m or more and works fine with FO cable of length 2m.

Any comments or insights are greatly appreciated.
You have a fiber switch that only does 100MB? Or are you saying you configured the port on the switch to only do 100MB?

By default the NIC may go to its highest allowed speed. You can change the speed with ethtool.
Command line to do that is: ethtool -s eth0 speed 100 duplex full autoneg off

You can add ethtool options to the interface configuration so it sets this any time the interface is restarted. On Fedora, RHEL, CentOS and other RH derivied distros the NIC configuration file would be /etc/sysconfig/network-scripts/ifcfg-eth0. It may be different for other distros.
Setting to add to force 100MB and full duplex in that file would be:
ETHTOOL_OPTS="autoneg off speed 100 duplex full"

NOTE: If you save a copy of the original ifcfg-eth0 before changing it (as you should always do so you can backout) be sure to prepend something to the name as the network startup looks for all files named ifcfg*.
e.g. Rather than saving with "cp -p ifcfg-eth0 ifcfg-eth0.20171115" do "cp -p ifcfg-eth0 20171115.ifcfg-eth0". With the first usage it process both ifcfg-eth0 AND ifcfg-eth0.20171115 which you don't want.
 
1 members found this post helpful.
Old 11-15-2017, 09:29 AM   #3
karthik_kk
LQ Newbie
 
Registered: Nov 2017
Posts: 3

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by MensaWater View Post
You have a fiber switch that only does 100MB? Or are you saying you configured the port on the switch to only do 100MB?

By default the NIC may go to its highest allowed speed. You can change the speed with ethtool.
Command line to do that is: ethtool -s eth0 speed 100 duplex full autoneg off

You can add ethtool options to the interface configuration so it sets this any time the interface is restarted. On Fedora, RHEL, CentOS and other RH derivied distros the NIC configuration file would be /etc/sysconfig/network-scripts/ifcfg-eth0. It may be different for other distros.
Setting to add to force 100MB and full duplex in that file would be:
ETHTOOL_OPTS="autoneg off speed 100 duplex full"

NOTE: If you save a copy of the original ifcfg-eth0 before changing it (as you should always do so you can backout) be sure to prepend something to the name as the network startup looks for all files named ifcfg*.
e.g. Rather than saving with "cp -p ifcfg-eth0 ifcfg-eth0.20171115" do "cp -p ifcfg-eth0 20171115.ifcfg-eth0". With the first usage it process both ifcfg-eth0 AND ifcfg-eth0.20171115 which you don't want.
Thank you for the input MensaWater.


But we already tried Ethtool and if a script with ethtool forcing is run in the background the issue is never happening again. My doubt was why was the speed moving to 1000 Mbps even though the fiber switch will support only 100MB and the transceiver supports only 10 or 100 Mbps ?
 
Old 11-15-2017, 10:48 AM   #4
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,134
Blog Entries: 14

Rep: Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265
Since you're not doing autonegotiation the switch port isn't determining the speed of the NIC.

You COULD turn on autonegotiation if the switch supports it. So long as your max advertised rate on the NIC is 100MB which it was in the output you sent, and the max allowed by the switch is 100MB then typically they'd negotiate to that speed. Note that it IS possible for autonegotiation to negotiate to lower speeds - you typically see that if you have a cabling issue of some sort.

I'm still really surprised that you have a fiber switch that can only do 100MB. Fiber is capable of so much more (we use it here for 10GB ethernet and have used it for 2GB, 4GB, 8GB and now 16GB SAN).

We have run into switches (Dell Force10) that did not actually work well with server NICs (copper) and switch ports hard set to 100MB so had to adjust those NICs to allow autonegotiation to 1000MB on both ends.
 
Old 12-19-2017, 05:06 AM   #5
karthik_kk
LQ Newbie
 
Registered: Nov 2017
Posts: 3

Original Poster
Rep: Reputation: Disabled
SOLVED !!

The device power supply was moving to a voltage less than 2.8V, where the LXT971A PHY Chip needs about 2.9V or 3V minimum for its functioning. When the PHY Chip gets OFF, the PHY_READ of BMCR will return 0xFFFF in the PHY area (dont know why) of the Kernel. Hence resulting in Checking the speed of 1000MBPS FULL DUPLEX as it is the first check of BMCR after reading it using PHY_READ. The supply was fixed and the issue was not found again.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to identify "True Optic Fibre Broadband" connection satimis Linux - Networking 4 02-17-2016 08:23 AM
help with fiber optic: single multi mode 50 62.5 and connectors ron7000 Linux - Networking 1 07-08-2015 12:15 AM
Fibre optic cables' data capacity may soon be reached Jeebizz Linux - News 0 10-15-2010 10:52 AM
Fibre optic capacity 'auto-tuned' by novel device Jeebizz Linux - News 0 09-09-2010 10:37 AM
gphoto2...no supported cameras listed? 187807 Slackware 1 02-26-2004 04:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 07:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration