From owner-freebsd-questions@FreeBSD.ORG Tue Dec 6 00:23:08 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 15FFE16A41F for ; Tue, 6 Dec 2005 00:23:08 +0000 (GMT) (envelope-from richard@inf.ed.ac.uk) Received: from nutty.inf.ed.ac.uk (nutty.inf.ed.ac.uk [129.215.216.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4898443D66 for ; Tue, 6 Dec 2005 00:23:04 +0000 (GMT) (envelope-from richard@inf.ed.ac.uk) Received: from macintosh.inf.ed.ac.uk (macintosh.inf.ed.ac.uk [129.215.164.64]) by nutty.inf.ed.ac.uk (8.12.8/8.12.8) with ESMTP id jB60Muui025623; Tue, 6 Dec 2005 00:22:56 GMT Received: by macintosh.inf.ed.ac.uk (Postfix, from userid 26013) id 8BC2D561540; Tue, 6 Dec 2005 00:22:56 +0000 (GMT) From: Richard Tobin To: David Kelly , user In-Reply-To: David Kelly's message of Mon, 5 Dec 2005 17:13:16 -0600 Organization: just say no X-Mailer: Ream 5.1.51-richard-mac Message-Id: <20051206002256.8BC2D561540@macintosh.inf.ed.ac.uk> Date: Tue, 6 Dec 2005 00:22:56 +0000 (GMT) Cc: freebsd-questions@freebsd.org Subject: Re: cp/mv/etc : argument list too long ... I am sick of this X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Dec 2005 00:23:08 -0000 The sysctl kern.argmax reflects the maximum argument list size. It's set to 65536, at least in 4.11, and is (I think) not changeable except by rebuilding the kernel with a different value for ARG_MAX. > Is well and good that there be some limit to how much data one can pack > on the command line and incoming arglist in an application's > environment else fumble fingers could cause major havoc. This is a bogus argument. The number of fumbles prevented by a limit of 65536 is not going to be very different from the number if it was, say, a million. On the other hand, having to switch commands once your data passes some arbitrary size is annoying and (I assert :-) not in the spirit of BSD. There may well be some good reasons for limiting the argument size, especially on a multi-user system. But the right solution is to make setting kern.argmax work, and allow system admistrators to decide what's appropriate for their systems. (I don't have a more recent release handy to check with; maybe it's already been done.) -- Richard