How to query the computer's ip address?
Malcolm Kay
malcolm.kay at internode.on.net
Sun Feb 8 05:09:12 PST 2004
On Sun, 8 Feb 2004 21:49, Rob wrote:
> Hi,
>
> Silly question, maybe, but is there a simple command to query the
> computer's ip address? Something similar to 'hostname' for finding the
> computer's hostname. I need the four dot-separated ip numbers.
>
A computer often has a number of associated ip addreses; so it is a bit
difficult. However interfaces usually have a unique address (or at least a prime
address) so it makes more sense to think in terms of the ip address of a
particular NIC in the machine.
So ifconfig is the most reasonable way to find what ip addresses are
associated with your computer.
Malcolm
More information about the freebsd-questions
mailing list