Autonegotiation: An EtherNet/IP Implementation Problem

autonegotiation

It’s time for me to admit something and its sort of hard to admit. OK, here it is: “I personally have never really designed, deployed or maintained an EtherNet/IP network.” Crazy, for a guy that makes his living in the industrial automation connectivity business.

I’ve always been on the other side, advising developers on how to add EtherNet/IP to their products or creating products that have EtherNet/IP, Siemens S7 Communications or Modbus TCP in them. I’ve never been responsible for a network whose performance suddenly takes a nosedive or a link that constantly resets or a switch that is shutting ports down, seemingly randomly.  I’m starting to learn how little I really know.

Let’s take something that every Ethernet link does every time it makes a connection: find a speed and a duplex setting. If you are using an unmanaged switch – not the best choice for EtherNet/IP and PROFINET IO networks – it’s all done for you. You can’t get any link configured your way. You’re leaving everything to chance.

I can hear you out there. “Do you know how much money I can save using off-brand unmanaged switches?” Yes, that’s certainly true. Unmanaged switches are less expensive, but you actually lose control of your network. The unmanaged switch decides the best data rate to use, a process known as autonegotiation. It decides between full-duplex (data moving in two directions at the same time) and half-duplex (data moving in either one direction or another). It makes all the decisions for you and takes control of your automation network out of your hands. All you can do is hope for the best and you’ve heard it before: “Hope is not your best strategy.”

Take autonegotiation. Sounds great. You don’t have to worry about what device you hook up to the switch. The switch and the device will “negotiate” the best data rate. Unfortunately, the Ethernet evolved quickly and, in the rush to get products out, some vendors interpreted the specs a little differently than others did. The result is that if you have a device that supports 100MB, you “assume” that the switch and the device will use 100MB, but because of some relatively minor incompatibilities, they end up with 10MB and you lose some performance.

In the worst case, autonegotiation results in speed mismatches, and you might not even get the link light to display. Or your unmanaged switch might negotiate a duplex mismatch with one side half-duplex and the other side full-duplex. It works but you can get significant packet-loss problems. And even worse – and very difficult to troubleshoot – both sides of the link come to an agreement on their speed and duplex settings, but one end of the connection intermittently concludes that it needs to renegotiate, bringing the link down at random times.

This discussion has focused on a device to switch links, but it would be wrong to limit our discussion to just that. Every link you have can have these problems. You have to consider the links between two switches, links between your servers and other servers, and between servers and switches. Any of these incompatibilities or even substandard cabling can have a negative impact on the operation of your network.

You’ll also want to note that you’ll have fewer problems at 1GB and 10GB data rates. The reason for that is that considerable effort was spent creating international specifications for these data rates, and vendors making chipsets are all adhering to those standards. 10MB and 100MB came to the market so fast as new technology that those standards weren’t fully in place when they were deployed.

If you find that you have problems like dropped packets, performance issues, or connections resetting or failing you should look at your switches. Your unmanaged switches may be more of a problem than you know. Unlike an unmanaged switch, in a managed switch you have total control of the link. You decide on the duplex and data rate. And you have access to troubleshooting tools within the switch to identify and fix performance problems.

Life is too short to not accept that you get what you pay for, and it’s true with unmanaged switches.