From owner-freebsd-net Fri Nov 15 12:28:51 2002 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 4DF5937B401 for ; Fri, 15 Nov 2002 12:28:47 -0800 (PST) Received: from wattres.Watt.COM (dsl093-133-130.sfo2.dsl.speakeasy.net [66.93.133.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id C2EB243E42 for ; Fri, 15 Nov 2002 12:28:46 -0800 (PST) (envelope-from steve@Watt.COM) Received: (from steve@localhost) by wattres.Watt.COM (8.12.6/8.12.6) id gAFKSjbq030789; Fri, 15 Nov 2002 12:28:45 -0800 (PST) (envelope-from steve) Message-Id: <200211152028.gAFKSjbq030789@wattres.Watt.COM> From: steve@Watt.COM (Steve Watt) Date: Fri, 15 Nov 2002 12:28:45 -0800 In-Reply-To: Archie Cobbs "Re: MPD UDP setup" (Nov 15, 11:42) X-Mailer: Mail User's Shell (7.2.6 beta(5) 10/07/98) To: Archie Cobbs Subject: Re: MPD UDP setup Cc: net@FreeBSD.ORG Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Nov 15, 11:42, Archie Cobbs wrote: } Subject: Re: MPD UDP setup } Steve Watt wrote: } > When I try to start mpd, I get the following in my error } > log, and don't see anything bound to UDP:3141... } > } > Nov 14 23:57:59 wattres mpd: [netremote] can't bind ksocket node: Invalid argument } } Are your netgraph modules up-to-date and kernel in sync? Yup. Did a full upgrade yesterday afternoon, including mpd 3.10. } What happens when you run ngctl(8) and enter these commands? } Replace "X.X.X.X" with your globally visible address. } } + mkpeer ksocket sock inet/dgram/udp } + msg sock bind inet/X.X.X.X:3141 That looks like it works. Can't figure out how to delete the new node, though. Oh, nevermind, it went away with the ngctl session. } If that works, then try enabling netgraph debugging in mpd } and ngctl and compare the messages going back & forth. Well, they're different, but I'm not good enough friends with netgraph to figure out what's making it unhappy. ngctl sayeth: - - - 8< - - - + mkpeer ksocket sock inet/dgram/udp ngctl: SENDING MESSAGE: ngctl: SOCKADDR: { fam=32 len=4 addr="." } ngctl: NG_MESG : ngctl: vers 2 ngctl: arglen 48 ngctl: flags 0 ngctl: token 1 ngctl: cookie GENERIC (851672668) ngctl: cmd 2 ngctl: args (48 bytes) ngctl: 0000: 6b 73 6f 63 6b 65 74 00 00 aa 04 08 dc cd bf bf ksocket......... ngctl: 0010: 73 6f 63 6b 00 32 06 28 04 00 00 00 9c c5 bf bf sock.2.(........ ngctl: 0020: 69 6e 65 74 2f 64 67 72 61 6d 2f 75 64 70 00 bf inet/dgram/udp.. + msg sock bind inet/66.93.133.130:3141 ngctl: SENDING MESSAGE: ngctl: SOCKADDR: { fam=32 len=7 addr="sock" } ngctl: NG_MESG : ngctl: vers 2 ngctl: arglen 60 ngctl: flags 0 ngctl: token 2 ngctl: cookie GENERIC (851672668) ngctl: cmd 13 ngctl: args (60 bytes) ngctl: 0000: 00 00 18 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ ngctl: 0010: 00 00 00 00 62 69 6e 64 00 00 00 00 00 00 00 00 ....bind........ ngctl: 0020: 00 00 00 00 69 6e 65 74 2f 36 36 2e 39 33 2e 31 ....inet/66.93.1 ngctl: 0030: 33 33 2e 31 33 30 3a 33 31 34 31 00 33.130:3141. ngctl: RECEIVED RESPONSE: ngctl: SOCKADDR: { fam=32 len=7 addr="sock" } ngctl: NG_MESG : ngctl: vers 2 ngctl: arglen 52 ngctl: flags 1 ngctl: token 2 ngctl: cookie GENERIC (851672668) ngctl: cmd 13 ngctl: args (52 bytes) ngctl: 0000: 00 00 10 00 00 00 00 00 00 00 00 00 8d 9f 30 38 ..............08 ngctl: 0010: 01 00 00 00 62 69 6e 64 00 00 00 00 00 00 00 00 ....bind........ ngctl: 0020: 00 00 00 00 10 02 0c 45 42 5d 85 82 00 00 00 00 .......EB]...... ngctl: 0030: 00 00 00 00 .... ngctl: SENDING MESSAGE: ngctl: SOCKADDR: { fam=32 len=7 addr="sock" } ngctl: NG_MESG : ngctl: vers 0 ngctl: arglen 16 ngctl: flags 0 ngctl: token 3 ngctl: cookie KSOCKET (942710669) ngctl: cmd 1 ngctl: args (16 bytes) ngctl: 0000: 10 02 0c 45 42 5d 85 82 00 00 00 00 00 00 00 00 ...EB].......... + quit - - - >8 - - - And mpd says: - - - 8< - - - [netremote:netremote] set debug 5 [netremote:netremote] open [netremote] IFACE: Open event [netremote] IPCP: Open event [netremote] IPCP: state change Initial --> Starting [netremote] IPCP: LayerStart [netremote:netremote] [netremote] bundle: OPEN event in state CLOSED [netremote] opening link "netremote"... [netremote] link: OPEN event [netremote] LCP: Open event [netremote] LCP: state change Initial --> Starting [netremote] LCP: LayerStart [netremote] device: OPEN event in state DOWN [netremote] netgraph: SENDING MESSAGE: [netremote] netgraph: SOCKADDR: { fam=32 len=9 addr="bypass" } [netremote] netgraph: NG_MESG : [netremote] netgraph: vers 2 [netremote] netgraph: arglen 48 [netremote] netgraph: flags 0 [netremote] netgraph: token 63 [netremote] netgraph: cookie GENERIC (851672668) [netremote] netgraph: cmd 2 [netremote] netgraph: args (48 bytes) [netremote] netgraph: 0000: 6b 73 6f 63 6b 65 74 00 4e 27 07 08 00 00 00 00 ksocket.N'...... [netremote] netgraph: 0010: 6c 69 6e 6b 30 00 00 00 81 e0 06 08 00 00 00 00 link0........... [netremote] netgraph: 0020: 69 6e 65 74 2f 64 67 72 61 6d 2f 75 64 70 00 00 inet/dgram/udp.. [netremote] netgraph: SENDING MESSAGE: [netremote] netgraph: SOCKADDR: { fam=32 len=15 addr="bypass.link0" } [netremote] netgraph: NG_MESG : [netremote] netgraph: vers 2 [netremote] netgraph: arglen 16 [netremote] netgraph: flags 0 [netremote] netgraph: token 64 [netremote] netgraph: cookie KSOCKET (942710669) [netremote] netgraph: cmd 1 [netremote] netgraph: args (16 bytes) [netremote] netgraph: 0000: 00 02 0c 45 42 5d 85 82 00 00 00 00 00 00 00 00 ...EB].......... [netremote] netgraph: sendto(bypass.link0): Invalid argument [netremote] can't bind ksocket node: Invalid argument *** aha! Maybe... [netremote] netgraph: SENDING MESSAGE: [netremote] netgraph: SOCKADDR: { fam=32 len=9 addr="bypass" } [netremote] netgraph: NG_MESG : [netremote] netgraph: vers 2 [netremote] netgraph: arglen 16 [netremote] netgraph: flags 0 [netremote] netgraph: token 65 [netremote] netgraph: cookie GENERIC (851672668) [netremote] netgraph: cmd 5 [netremote] netgraph: args (16 bytes) [netremote] netgraph: 0000: 6c 69 6e 6b 30 00 04 08 6c ef bf bf 10 00 00 00 link0...l....... [netremote] device is now in state OPENING [netremote] device: DOWN event in state OPENING [netremote] device is now in state DOWN [netremote] link: DOWN event [netremote] LCP: Down event [netremote] device: OPEN event in state DOWN [netremote] pausing 9 seconds before open [netremote] device is now in state DOWN close [netremote] IFACE: Close event [netremote] IPCP: Close event [netremote] IPCP: state change Starting --> Initial [netremote] IPCP: LayerFinish [netremote:netremote] [netremote] bundle: CLOSE event in state OPENED [netremote] closing link "netremote"... [netremote] link: CLOSE event [netremote] LCP: Close event [netremote] LCP: state change Starting --> Initial [netremote] LCP: LayerFinish [netremote] device: CLOSE event in state DOWN [netremote] device is now in state DOWN - - - >8 - - - My *** aha! is that the sin_len in the sockaddr_in being sent with the bind request is 0. Lemme go hack and see if that's the problem. Steve -- Steve Watt KD6GGD PP-ASEL-IA ICBM: 121W 56' 57.8" / 37N 20' 14.9" Internet: steve @ Watt.COM Whois: SW32 Free time? There's no such thing. It just comes in varying prices... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message