In this man page http://man7.org/linux/man-pages/man7/ip.7.html, it is written that
IP_ADD_MEMBERSHIP can be used to join a multicast group. We need to provide, as input, in particular, the IP multicast group address and the IP address of the local interface.
But what is a local interface exactly? What would be an IP address of a local interface?
Is it the address like 127.0.0.1? I know this often called the "localhost" or "loopback" interface. But I am not sure what why it's called "interface", anyway (what is a local interface?). Isn't 127.0.0.1 just the IP address that points to my own computer?
Is the IP address of my local interface the address of my computer on my local area network (LAN): for example, given that I am on a Mac OS X, the "inet" address under
en0(that can be retrieved using the command
How is this IP address of the local interface different from the address of the multicast group?
Local interface implies the existence of global interface, I guess. So, what would be a "global interface"?
So, which address corresponds to the IP address of my local interface that I should pass to