From owner-freebsd-net Fri Aug 20 3:15:58 1999 Delivered-To: freebsd-net@freebsd.org Received: from mh.acorn.co.uk (mh.acorn.co.uk [136.170.131.2]) by hub.freebsd.org (Postfix) with ESMTP id CE5D014DCB for ; Fri, 20 Aug 1999 03:15:48 -0700 (PDT) (envelope-from kbracey@e-14.com) Received: from kbracey.acorn.co.uk (kbracey [136.170.129.213]) by mh.acorn.co.uk (8.8.6/8.8.6) with SMTP id LAA00320 for ; Fri, 20 Aug 1999 11:15:46 +0100 (BST) Date: Fri, 20 Aug 1999 11:15:54 +0100 From: Kevin Bracey To: freebsd-net@freebsd.org Subject: RE: on dual-homed machine, how to specify outgoing interface to s end multicast packets Message-ID: <35277e3449%kbracey@kbracey.acorn.co.uk> In-Reply-To: X-Organization: Acorn Computers Ltd, Cambridge, United Kingdom X-Mailer: Messenger v1.40f for RISC OS MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Posting-Agent: RISC OS Newsbase 0.61b Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org In message George Chung wrote: > you're right, I can't ping the address. so how do I fix that?! :-) > > -----Original Message----- > From: Mike Nowlin [mailto:mike@argos.org] > Sent: Wednesday, August 18, 1999 10:27 PM > To: George Chung > Cc: 'freebsd-net@freebsd.org' > Subject: Re: on dual-homed machine, how to specify outgoing interface to > send multicast packets > > > > > On a dual-homed machine, there is no "network" portion of the destination > > Class D address to make any kind of determination as to which outgoing > > interface to use. > > > > So I make a call to > > > > setsockopt(fd, IPPROTO_IP, IP_MULTICAST_IF, &inaddr, sizeof(struct > > in_addr)); > > > > I confirm that this call works. Plus I doublechecked by giving it a bogus > > inaddr, and it gave me errno 49 EADDRNOTAVAIL. However, when I try send a > > packet to "225.0.0.1", I get errno 65 EHOSTUNREACH. > > First guess is that it's a routing problem... Try pinging that address -- > if you get a "route not available" (or similar message), that's probably > it. > This is a known BSD bug - even if you specify an interface manually for multicasts, you need a route set up for multicast packets :( As a side- effect, IGMP messages won't get sent either, unless you have a multicast route set up. -- Kevin Bracey, Senior Software Engineer Pace Micro Technology plc Tel: +44 (0) 1223 518566 645 Newmarket Road Fax: +44 (0) 1223 518526 Cambridge, CB5 8PB, United Kingdom WWW: http://www.acorn.co.uk/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message