On Jun 21, 2005, at 8:26 AM, Daniel Sumorok wrote:
If you type "netstat -rn" at the command line you will get the
routing table. Usually, the gateway's IP address is a function of the
destination IP address, and the interface to use is a function of the
gateway's IP address. There can also be multiple gateways attached
to a
single interface. Usually, a single gateway is designated as the
"default" route, and all packets destined for that gateway are routed
through the same interface. The routing table should tell you exactly
where each packet will be routed.
thanks, daniel. that got me almost there, but not quite...
the gateway for en1 says "link#5". what is that supposed to mean?
it should say "192.168.21.1" .
i'm looking at the netstat docs, but i'm not seeing anything (except -
a, which isn't doing what i need i to) that might list ALL interfaces
and their corresponding gateways. i'm getting good data for the
"default" route, but i need all ifaces and all gateways.
the system is obviously aware of the gateways that i've either
specified in SysPrefs or that were set up for me via DHCP.