[comp.unix.questions] mkdir has stopped working

slootman@dri.nl (Paul Slootman) (04/21/91)

In article <285400001@adaptx1> neese@adaptx1.UUCP writes:
>Check the amount of files/directories in the directory you are trying to
>create one in.  If the total is more than 999, the mkdir command will fail.
>You can only have up to 1000 entries in each subdirectory.  I don't know
>whether this is a file system limit or a limit imposed by mkdir.

This limit is a consequence of the limit on the number of links a file
may have, which is 1000 (at least it is on the systems I've seen). As
every directory contains a link to itself and its parent, you can't have
more than 998 (sub)directories in any single directory.

While we're on the subject, why is/was this limit imposed? To make sure
some old version fsck / ncheck didn't barf?

Paul.