[jcifs] Getting Switch IP address and port number

Justin Mahoney JMahoney at ditech.com
Fri Aug 5 16:28:26 GMT 2005

The switch probably does not have an IP address, unless it is actually a
router. To find out, just run a tracert ('traceroute' on *nix) from your
desktop machine to the server. It will list all nodes with assigned IP
numbers that are visited along the path from your desktop to the server.

Why would you need to know the "port number of the switch?" It is very
unlikely you would be able to discover that information without simply
looking at the physical switch hardware itself. Do you mean the TCP port
number of the connection?

If you are simply trying to confirm which switch port the desktop is plugged
into, take your best guess, unplug a cable from the switch, and go back to
the desktop to verify that the connection lights on the network card have
gone out. Then plug it back in at the switch and verify the connection
lights on the network card come back on.

-----Original Message-----
From: jcifs-bounces+jmahoney=ditech.com at lists.samba.org
[mailto:jcifs-bounces+jmahoney=ditech.com at lists.samba.org] On Behalf Of
Valentin Kisimov
Sent: Thursday, August 04, 2005 11:47 PM
To: jcifs at lists.samba.org
Subject: [jcifs] Getting Switch IP address and port number


I have a problem and I hope you can help me.

The environment consists of Desktop connected to a Switch connected to a
Server. I can know the IP address and MAC address of the Desktop and the
Server. Being inside the Desktop, I am looking to find the IP address of the
switch and the Port number of the switch to which the Desktop is connected.

If you have any idea/code to resolve the problem I will very appreciate.
Thanks in advance.


Dr. Valentin Kisimov
T-Systems South Africa,
International Business Gateway, New Road, Midrand 1685 PO Box 2496, Midrand
tel: (swb) +27 11 254 7800
fax: +27 11 254 7802
mobile: +27 82 570 5048
-------------- next part --------------
HTML attachment scrubbed and removed

More information about the jcifs mailing list