From owner-freebsd-net@FreeBSD.ORG Thu Feb 26 18:55:00 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 69CA216A4CE for ; Thu, 26 Feb 2004 18:55:00 -0800 (PST) Received: from shuttle.wide.toshiba.co.jp (shuttle.wide.toshiba.co.jp [202.249.10.124]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0033743D1F for ; Thu, 26 Feb 2004 18:54:59 -0800 (PST) (envelope-from jinmei@isl.rdc.toshiba.co.jp) Received: from ocean.jinmei.org (unknown [3ffe:501:100f:1048:200:39ff:fe5e:cfd7]) by shuttle.wide.toshiba.co.jp (Postfix) with ESMTP id 91AEB15210; Fri, 27 Feb 2004 11:54:58 +0900 (JST) Date: Fri, 27 Feb 2004 11:55:10 +0900 Message-ID: From: JINMEI Tatuya / =?ISO-2022-JP?B?GyRCP0BMQEMjOkgbKEI=?= To: Donald McLachlan In-Reply-To: <200402261627.i1QGRVT02174@janus.dgrc.crc.ca> References: <200402261627.i1QGRVT02174@janus.dgrc.crc.ca> User-Agent: Wanderlust/2.10.1 (Watching The Wheels) Emacs/21.3 Mule/5.0 (SAKAKI) Organization: Research & Development Center, Toshiba Corp., Kawasaki, Japan. MIME-Version: 1.0 (generated by SEMI 1.14.5 - "Awara-Onsen") Content-Type: text/plain; charset=US-ASCII cc: freebsd-net@freebsd.org Subject: Re: IPv6 multicast sendto() 'operation not supported' X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Feb 2004 02:55:00 -0000 >>>>> On Thu, 26 Feb 2004 11:27:31 -0500 (EST), >>>>> Donald McLachlan said: > In preparation for writing an IPv6 multicast application I wrote a little > test program (shown below). This program worked on linux (RedHat), but > when I try it on a FreeBSD box (5.0, running zebra router and pim6dd) > sendto() fails with "Operation not supported" ... ??? > To verify my app was OK, I installed a solaris box on the LAN beside the > linux box and the app compiled and worked fine. > Thinking it might be a bug in 5.0 or an interaction with zebra/pim6dd I > installed a FreeBSD 5.2 box on the lan beside the other 2 app boxes and > I get the same error again. Anyone know what is missing/wrong in my test app? > [ I'm guessing FreeBSD wants some extra socket options set, but I don't know > which ones. ] Did your code really succeed the bind(2) call in the main function? > bzero((char *)&sin, (int)sizeof(sin)); /* setup address info */ > bcopy(the_addr, (char *)&sin.sin6_addr, sizeof(the_addr)); > sin.sin6_family = AF_INET6; > sin.sin6_port = htons(3000); > /* bind addr to sock */ > if(bind(sock, (struct sockaddr *)&sin, sizeof(sin)) < 0) > { > perror("bind"); > exit(errno); > } FreeBSD should require a valid sin6_len (which should be sizeof(sockaddr_in6)), so the program should have stopped here. JINMEI, Tatuya Communication Platform Lab. Corporate R&D Center, Toshiba Corp. jinmei@isl.rdc.toshiba.co.jp