From owner-freebsd-questions Thu Oct 3 5: 6: 8 2002 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 D89E137B401 for ; Thu, 3 Oct 2002 05:06:06 -0700 (PDT) Received: from mailf.telia.com (mailf.telia.com [194.22.194.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8F56E43E81 for ; Thu, 3 Oct 2002 05:06:05 -0700 (PDT) (envelope-from erikt@midgard.homeip.net) Received: from d1o913.telia.com (d1o913.telia.com [195.252.44.241]) by mailf.telia.com (8.12.5/8.12.5) with ESMTP id g93C6369005021 for ; Thu, 3 Oct 2002 14:06:03 +0200 (CEST) X-Original-Recipient: Received: from falcon.midgard.homeip.net (h63n1fls20o913.telia.com [212.181.162.63]) by d1o913.telia.com (8.8.8/8.8.8) with SMTP id OAA22771 for ; Thu, 3 Oct 2002 14:06:02 +0200 (CEST) Received: (qmail 64646 invoked by uid 1001); 3 Oct 2002 12:05:50 -0000 Date: Thu, 3 Oct 2002 14:05:50 +0200 From: Erik Trulsson To: Jimmy Lantz Cc: freebsd-questions@FreeBSD.ORG Subject: Re: file naming rulesets/conventions/limitations Message-ID: <20021003120550.GA64496@falcon.midgard.homeip.net> Mail-Followup-To: Jimmy Lantz , freebsd-questions@FreeBSD.ORG References: <5.1.0.14.0.20021003132831.02f52e38@mail.lusidor.nu> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: <5.1.0.14.0.20021003132831.02f52e38@mail.lusidor.nu> User-Agent: Mutt/1.5.1i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 03, 2002 at 01:44:02PM +0200, Jimmy Lantz wrote: > Hi, > I wonder if there's any rulesets/conventions/limitations to filenames in= =20 > freebsd? > Limits to amount of chars used in filenames (I've heard 14 chars but I us= e=20 > more and havent had any problems) > What special chars ar allowed? (can I use @ in a filename for instance?= =20 > I've tested, it works, just want to know if it can give me some problems= =20 > later on...) 14 chars was the limit on old V7 systems, but that limitation disappeared from BSD almost 20 years ago. The answers to your questions can be found in the intro(2) manpage which contains the following: File Name Names consisting of up to 255 (MAXNAMELEN) characters may be used to name an ordinary file, special file, or directory. These characters may be selected from the set of all ASCII char=AD acter excluding 0 (NUL) and the ASCII code for /' (slash). Note that it is generally unwise to use *', =7F', =1B' or =1D' as part of file names because of the special meaning attached to these characters by the shell. Path Name A path name is a NUL-terminated character string starting with an optional slash /', followed by zero or more directory names sep=AD arated by slashes, optionally followed by a file name. The total length of a path name must be less than 1024 (MAXPATHLEN) charac=AD ters. If a path name begins with a slash, the path search begins at the root directory. Otherwise, the search begins from the current working directory. A slash by itself names the root directory. An empty pathname refers to the current directory. [As an additional note it might also be unwise to use spaces in filenames, = since many programs interpret them as separators between filenames.] --=20 Erik Trulsson ertr1013@student.uu.se To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message