Date: Tue, 30 Oct 2001 08:02:42 -0800 (PST) From: Archie Cobbs <archie@dellroad.org> To: Trond Davidsen <trond.davidsen@ii.uib.no> Cc: freebsd-net@FreeBSD.ORG Subject: Re: Mpd with a large number, 200+ , of bundles Message-ID: <200110301602.f9UG2gr07609@arch20m.dellroad.org> In-Reply-To: <3BD6FA2F.6070509@ii.uib.no> "from Trond Davidsen at Oct 24, 2001 07:28:15 pm"
next in thread | previous in thread | raw e-mail | index | archive | help
Trond Davidsen writes: > I'm trying to set up mpd as a replacement for poptop + ppp. But I run > into a problem when I try to configure more than 100 bundles. When I > configure 30 bundles, everything works nicely. When I configure 100 > bundles, things seems to work nicely, but when I run ngctl, I get the > following error when typing 'list' at the ngctl prompt: > > > [lines for ng100 - ng24 removed] > > Name: ng23 Type: iface ID: 00000849 Num hooks: 1 > Name: <unnamed> Type: socket ID: 00000848 Num hooks: 2 > Name: <unnamed> Type: vjc ID: 00000847 Num hooks: 4 > Name: <unnamed> Type: bpf ID: 00000846 Num hooks: 3 > Name: mpd37379-pptp12 Type: ppp ID: 00000845 Num hooks: 6 One problem with netgraph is that node and hook names can only be about 15 characters.. so when you get to 100 bundles, the hook names start overflowing the buffers. If you're only running one version of mpd, for example, you can try this patch to fix the '100 bundles' problem by shortening the node names: Index: ngfunc.c =================================================================== RCS file: /home/cvs/archie/mpd/src/ngfunc.c,v retrieving revision 1.2 diff -u -r1.2 ngfunc.c --- ngfunc.c 2001/04/12 17:03:33 1.2 +++ ngfunc.c 2001/10/30 15:58:46 @@ -189,7 +189,7 @@ newPpp = 1; /* Give it a name */ - snprintf(nm.name, sizeof(nm.name), "mpd%d-%s", getpid(), b->name); + snprintf(nm.name, sizeof(nm.name), "mpd-%s", b->name); if (NgSendMsg(b->csock, MPD_HOOK_PPP, NGM_GENERIC_COOKIE, NGM_NAME, &nm, sizeof(nm)) < 0) { Log(LG_ERR, ("[%s] can't name %s node: %s", > + list > ngctl: send msg: No buffer space available > + quit > > which buffer is this, and how do I make it larger? This is probably due to a fixed size buffer in the base netgraph code somewhere... it doesn't look like libnetgraph can generate an ENOBUFS on its own. Try running ngctl with one or more '-d' flags.. -Archie __________________________________________________________________________ Archie Cobbs * Packet Design * http://www.packetdesign.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200110301602.f9UG2gr07609>