sockets and multiple interfaces

Klacke klacke@REDACTED
Fri Nov 17 14:19:43 CET 2000


On Fri, Nov 17, 2000 at 12:19:15PM +0100, Hans Nilsson wrote:
> 
> How do I bind a socket to a certain interface in Erlang?
> 
> (In C the function setsockopt(2) the option SO_BINDTODEVICE is used to
> bind the socket to for example "eth0". I can't find this in the Erlang
> source code.)
> 


Option {ip, Ipddr} will bind the socket to the
interface which has ipaddress IpAddr. 

I think we have some documentation to do regarding all the
funky options which can be use set sockets in various modes.
There's now a very large number of undocumented options and it's
not trivial to read the code in order to find out what's existing.

/klacke


-- 
Claes Wikstrom                        -- Caps is nowhere and
Alteon WebSystems                     -- everything is under control          
http://www.bluetail.com/~klacke       --




More information about the erlang-questions mailing list