How to Check the Ethernet Card Network Link Status in SLES/SLED
Sometimes, if you find that your Internet or LAN is not working, you will use the ‘ping’ command from SLED/SLES CLI (Command Linux Interface) by pinging to your default Gateway Server or DNS Server or to any known site. But, in the end you might have a very basic problem.
The ‘Ping’ command is useful to find problems related to our ‘Network’ and whether it is working or not. When your network is not working it could be a problem with the DNS Server not working, the Default Gateway is not reachable, the router is not working between the Source Host and the Destination host, etc.. But in the end you will find that your network cable is not working or not connected to the Computer’s Ethernet Card, which is a very basic problem and can be a starting point for diagnosing Network related issues.
How to check the Ethernet Card Network Link Status in SLES/SLED.
There is a utility in SLES/SLED that will give us the Ethernet Card Network Link status, showing whether the Network Cable is Plugged (Link is up) or Unplugged (Link is down).
Launch your SLED/SLES CLI (Command Line Interface) and type: ifplugstatus.
From the output below, you can see that the Ethernet Card Network Link eth2 is detected.
person@NOVELLDESK:~>ifplugstatus lo: link beat detected eth0: unplugged eth1: unplugged eth2: link beat detected sit0: unplugged person@NOVELLDESK:~>
If your link is down due to a loose network cable or the network cable is not connected, then you will have this kind of output from the ‘ifplugstatus’ command:
person@NOVELLDESK:~>ifplugstatus lo: link beat detected eth0: unplugged eth1: unplugged eth2: unplugged sit0: unplugged person@NOVELLDESK:~>
So, from the output you can see that the Ethernet Card Network Link is down or the Network cable is unplugged or loose. This would be the first step for diagnosing network related issues rather then wasting time on pinging different hosts and finally concluding on this type of problem.
Again, Art of Administration. That’s all for now…