BlinkenlightenNetworking?
February 16, 2009 11:30 AM   Subscribe

I would like to make the network link light on my laptop blink in a recognizable way. I also want this to happen on the switch to which it's connected. How is this done? Oh, and without spending 400 bucks please.

So I do network diagnostics. For this, I mostly use a toner.

However there are times (like now) where I am plugging into a hot network jack on the patch panel, meaning it's connected to some switch, somewhere), but I have no idea which switch or which port on the switch is mine. In this case I'm connecting two gigabit switches together on opposite sides of the plant, but the jack I need to use on the far panel is hot. It's got a network connection to a 100 megabit switch in the closet. I need to unplug that from the switch. Can't find it on the other end.
On a small network I'd just take note of all the "on" connections on hte switch, then plug in the laptop and look for the extra light. That's easy. However, today's task involves 12 48 port switches in there with 576 potential lights.

So I'd like to have my laptop "blink" the network light on the switch. The best way to do this would seem to be to disable and re-enable the NIC on the laptop repeatedly. But there doesn't seem to be any way to do this other than scripting an enable/disable network connection, but I suck at scripting. Badly.

This is on Windows.

Any help would be appreciated. Thanks!
posted by disclaimer to Computers & Internet (10 answers total)
 
ping (from the command line) will cause your network light and the router light to flash at least once per second.

Start -> Run -> "cmd.exe" (or something close to this) to bring up a command line in Windows

ping www.yahoo.com (or some other known address)
posted by zippy at 11:39 AM on February 16, 2009


Presuming that ping does light up your NIC, you can use -t to have it keep pinging:

ping -t www.whatever.com
posted by me & my monkey at 12:50 PM on February 16, 2009


Do you have a managed switch? The techie way to do this would be to look at the switches MAC address table and see what MAC addresses are connected to each port on the switch.

This is why you pay 25% more for the managed switch :). Trying to figure out where 500 ports go is insanity.

S11R2CORE3550>show mac address-table

Mac Address Table
-------------------------------------------

Vlan Mac Address Type Ports
---- ----------- -------- -----
200 0010.4901.c6b0 DYNAMIC Fa0/17
200 0010.4902.2f00 DYNAMIC Fa0/17
200 0010.4902.553b DYNAMIC Fa0/17
200 0010.4903.4768 DYNAMIC Fa0/47
200 0010.4903.a3f2 DYNAMIC Fa0/48
200 0010.4903.a3f4 DYNAMIC Fa0/48
200 0010.4903.a46f DYNAMIC Fa0/19
200 0010.4903.a470 DYNAMIC Fa0/6
200 0010.4903.a472 DYNAMIC Fa0/26
200 0010.4903.a473 DYNAMIC Fa0/8
200 0010.4903.b49c DYNAMIC Fa0/48

Total Mac Addresses for this criterion: 144
S11R2CORE3550>

posted by SirStan at 1:17 PM on February 16, 2009


Also;

Linux' PING command has a wonderful 'hack' to help with this -- '-a' makes PING produce an audable BEEP each time the ping completes. Its great for this situation.
posted by SirStan at 1:20 PM on February 16, 2009


Are you saying you only have a link status LED, not an activity LED? If so, this may not be possible -- it depends on your NIC, but disabling it through software probably won't interrupt the electrical connection, which means the switch on the other end will still detect a device on the wire.

Do you have a digital camera and a tripod handy? Why not take "before" and "after" pictures from exactly the same position, and then overlay them in an image editor to show the differences? Alternatively, just find a coworker with a phone and a couple minutes to spare, and just have them plug and unplug the cable a few times while you watch the lights.
posted by teraflop at 4:17 PM on February 16, 2009


Are your switches Ciscos? If so, by default each switchport broadcasts it's switch name and port number at layer 2 periodically via CDP. Linux has free CDP listeners/broadcasters, windows has some pay-for-play options. They will make your job a hell of alot easier. If you can't carry a laptop around you may just be able to carry around a USB stick with an executable application.

P.S. Even if they're not, let us know the manufacturer. They may have a similar technology.

P.S.S. Why aren't you just toning these out?
posted by datacenter refugee at 5:02 PM on February 16, 2009


About ten years ago it was discovered that you can sniff the data from a switch by recording the pulses from the little ethernet light. Its all a little randomized now, so I dont think you can do recognizable patterns. You might be able to get away with ping , long pause, ping, long pause, etc, but even that might be difficult to see, especially against 48 other blinking lights. Maybe run iperf against a far server. This should give you a solid light for a little while, but still hard to see on a busy network. Maybe iperf on a loop via a batch file.

On top of that, this will only work if your machine isnt doing anything else. Windows machines are notoriously chatty, so you'll have to be careful. Shut off the browser, rpc, and server services at the very least.

The real way to do this is to simply log into the switch and list mac addresses by port. You'll see your mac in the list and what port its on. I do this all the time. Heck, Ive memorized the mac address of my test laptop. This approach also guarantees you dont accidentally unplug a server.

On unmanaged switches I just have a buddy unplug and replug in the cable from afar while I sit in the server room watching. Ive never worked somewhere with a toner.
posted by damn dirty ape at 5:16 PM on February 16, 2009


Best answer: Also, devcon.exe can disable and enable devices in windows. You can put it in a simple loop in a batch file. You can google for some example scripts. Im guessing this will work:

:TOP
devcon /disable "device_id_here"
devcon /enable "device id_here"
GOTO TOP


Or you can try this ping:

:TOP
ping server01
ping 0.0.0.0 -n 1 -w 3000
GOTO TOP

That should send 5 pings, wait 3 seconds, then do that again, over and over. Im assumiing that pinging 0.0.0.0 wont blink on the switch. That might be recognizable. Who knows.
posted by damn dirty ape at 5:29 PM on February 16, 2009


Response by poster: Hey thanks everyone, I'm going to try a few things...

Damn dirty ape, thanks, your suggestions are going to be my first go.

Pings are troublesome because, as has been said, Windows is extremely chatty and there's no way to isolate the pings from the noise.

The switches are cheap crap netgear unmanaged switches. Boo (I am replacing them with cheap crap netgear managed switches as I go along though - the boss there lurvs his netgear crap)

datacenter refugee - toning doesn't work, there's a full voltage load on the patch panel port. Toning reveals no tone on the other side, only interference. I tried it.

I'll report back with my findings...
posted by disclaimer at 8:32 AM on February 17, 2009


Response by poster: Following up:

- pinging doesn't work. There is far too much traffic generated by Windows and its processes to keep the network quiet enough to discern ping traffic from anything else.

- devcon shows promise but I'm running 64 bit vista and there is a hassle about picking the proper hardware instance id's. I simply couldn't find the right syntax to make it go (and it kept crashing anyway). It certainly wasn't worth the time I spent attempting to make it work.

- Toning doesn't work - the cable is powered and I couldn't get a clear tone back in the closet.

So I caved, and the solution to the problem is this network cable tester. It has the ability to "blink" the hub/switch - a steady on-off light every two seconds on the switch.

I spent way more than I wanted to, but it certainly saved me an hour+ in finding the cable.


Thanks for your input everyone.
posted by disclaimer at 7:15 PM on February 18, 2009


« Older How far in advance should I buy my plane tickets?   |   Hello end user! Just FYI, the admin password to... Newer »
This thread is closed to new comments.