inode #1

John F. Haugh II jfh at rpp386.Dallas.TX.US
Sat Apr 15 04:22:21 AEST 1989


In article <352 at anvil.oz> michi at anvil.oz (Michael Henning) writes:
>I just did a "find / -inum 1 -print" on an AIX and a Xenix 386 system. As
>it turns out, inode 1 is not used. The root inode of every file system is 2.
>Can anyone tell me why inode 1 is not used anywhere ?  It seems that it
>could be used, since if 0 indicates that a directory entry is free, why
>not use inode 1 like any other inode ?

Because in ages past someone wanted to use inode 1 to contain the list
of bad blocks.

If you use fsdb to create a file with inumber 1, it should function
just fine.  The root inode is defined to be 2 in <sys/param.h>, there
is no reason it can't be defined to be 1.  Non-portable programs not
withstanding :-( ...
-- 
John F. Haugh II                        +-Quote of the Week:-------------------
VoiceNet: (214) 250-3311   Data: -6272  | "Porsche does not recommend
InterNet: jfh at rpp386.Dallas.TX.US       |  exceeding any speed limits"
UucpNet : <backbone>!killer!rpp386!jfh  +--        -- Porsche Ad   ------------



More information about the Comp.unix.wizards mailing list