How do I find my own IP address?

Miguel Barreiro enano@REDACTED
Thu Jan 22 22:39:27 CET 2004


> > > 2>prim_inet:ifget(S, "eth0", [addr]).
> > > {ok,[{addr,{192,168,100,100}}]}
> >
> > This will work on a vanilla Unix system.
>
> Not even there (depending on your interpretation of 'vanilla Unix') -
> the BSD's have not traditionally had interfaces named eth*.  They're
> named after the specific devices (ed*, rl*, dc*, etc) instead.

Please. We're talking "how do I know what's my IP", that of course means
"how do I know what's this interface's IP". If one doesn't even know which
interface, then just list them first.

ObOfftopic: traditionally, AIX systems have had two interfaces (en* and
ent* IIRC) for each physical NIC: one of them behaves as an Ethernet card
and the other as IEEE 802.3.






More information about the erlang-questions mailing list