From owner-freebsd-net Sat Jan 30 06:36:19 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id GAA28849 for freebsd-net-outgoing; Sat, 30 Jan 1999 06:36:19 -0800 (PST) (envelope-from owner-freebsd-net@FreeBSD.ORG) Received: from labinfo.iet.unipi.it (labinfo.iet.unipi.it [131.114.9.5]) by hub.freebsd.org (8.8.8/8.8.8) with SMTP id GAA28834 for ; Sat, 30 Jan 1999 06:36:13 -0800 (PST) (envelope-from luigi@labinfo.iet.unipi.it) Received: from localhost (luigi@localhost) by labinfo.iet.unipi.it (8.6.5/8.6.5) id NAA15704; Sat, 30 Jan 1999 13:26:34 +0100 Newsgroups: comp.unix.bsd.freebsd.misc Date: Sat, 30 Jan 1999 13:26:29 +0100 (MET) From: Luigi Rizzo cc: net@FreeBSD.ORG Subject: Re: ping -f only 50 pkts/sec ? h In-Reply-To: <78uv4d$fkv$1@rena.mat.uc.pt> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org [also posted to net@freebsd.org] On 30 Jan 1999, Rui Pedro Mendes Salgueiro wrote: > Rui Pedro Mendes Salgueiro wrote: ... > > more testing) and I noticed that the -f option seems to be limited > > to 50 pkts/sec: ... > I think I found when the problem was introduced. ... > I compiled the 1.36 version, tried it and: ... > 10000 / 2.87 = ~3484 packets/sec. > The 1.37 version : ... > 9997 / (3*60 + 21.15) = ~49.699 packets/sec. > > The 1.37 version has the following comment: > ---------------------------- > revision 1.37 > date: 1998/05/25 20:16:05; author: fenner; state: Exp; lines: +104 -81 > Use select() timeouts instead of SIGALRM to schedule packet transmission. > > I suspect that this is related. definitely. I think that a select() with a non-zero timeout will sleep for at least one tick (10ms); i suppose that if you compile a kernel with HZ=1000 you'll see 500 pkts/s. Because the manpage says -f Flood ping. Outputs packets as fast as they come back or one hundred times per second, whichever is more. i think the 1.36 behaviour is the correct one. Can't comment on the fix having not looked at the code. cheers luigi -----------------------------------+------------------------------------- Luigi RIZZO . EMAIL: luigi@iet.unipi.it . Dip. di Ing. dell'Informazione HTTP://www.iet.unipi.it/~luigi/ . Universita` di Pisa TEL/FAX: +39-050-568.533/522 . via Diotisalvi 2, 56126 PISA (Italy) -----------------------------------+------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message