Tuma Wang writes:
> So it's similar to the DL_ENABMULTI_REQ primitive? I'm not very
> certain of the semantics of this primitive. It's for link level
> multicast?

Correct.  On a BSD or Linux system, you can issue SIOCADDMULTI to add
an arbitrary Ethernet multicast address to the accepted set on the
underlying driver.  It does so *WITHOUT* interaction with the IP
multicast infrastructure on those systems.

It's a bit of a hack.  You have to pass in a 'struct sockaddr' with
sa_family set to AF_UNSPEC, and with the Ethernet address (it can only
really be an Ethernet address) in the sa_data field.

I *think* the reason it exists on those systems is to support socket-
based operations that are doing raw Ethernet I/O.  It has nothing to
do with IP multicast on those systems.  On Solaris, raw datalink I/O
isn't done by way of sockets -- instead, you use the standards-
compliant DLPIv2 interfaces.

Thus, it does nothing.  There's nothing in Solaris that supports this
ioctl.  You should get back EINVAL if you use it anywhere on any
Solaris system, as the kernel itself has no reference to that ioctl.
(That is, it's not different from passing in a random number via
ioctl().)

> What's the relation between it and IP_ADD_MEMBERSHIP?

None, really.

> If I
> want to do IP multicast, I guess IP_ADD_MEMBERSHIP alone is enough?

Yes.  You will very likely need IP_MULTICAST_IF (to set the output
interface) for most usable multicast applications.

You may also want IP_MULTICAST_TTL (if you need to set the TTL) and
perhaps IP_MULTICAST_LOOP (to turn off multicast loopback to local
receivers), depending on what the application does.

Depending on what sort of multicast routing support you have (or
need), you may also want the ip_mreq (IGMPv2) or ip_mreq_source
(IGMPv3) functions.  See the ip(7P) man page for more details.

-- 
James Carlson, Solaris Networking              <[EMAIL PROTECTED]>
Sun Microsystems / 35 Network Drive        71.232W   Vox +1 781 442 2084
MS UBUR02-212 / Burlington MA 01803-2757   42.496N   Fax +1 781 442 1677
_______________________________________________
networking-discuss mailing list
[email protected]

Reply via email to