Xref: utzoo news.admin:3839 comp.unix.wizards:12060 comp.bugs.sys5:660 Path: utzoo!attcan!uunet!cbmvax!ditto From: ditto@cbmvax.UUCP (Michael "Ford" Ditto) Newsgroups: news.admin,comp.unix.wizards,comp.bugs.sys5 Subject: Re: Too many inodes Summary: du counts links, not inodes Keywords: du wc inodes Message-ID: <5167@cbmvax.UUCP> Date: 2 Nov 88 01:33:00 GMT References: <580@mbph.UUCP> Reply-To: ditto@cbmvax.UUCP (Michael "Ford" Ditto) Organization: Commodore Technology, West Chester, PA Lines: 19 In article <580@mbph.UUCP> hybl@mbph.UUCP (Albert Hybl Dept of Biophysics SM) writes: >there are a total of 6192 inodes assigned to the file system. >That is as it should be. However, the du|wc count reports 6368 >files/directories! "du -a" will count each link (directory entry) once, even if it refers to an inode that was already counted, thus for every file that has two links, your "du -a|wc -l" will be off by one (and off by two for each 3-link file, etc.). In the news spool directory, multiple links are used when articles are crossposted. -- -=] Ford [=- "The number of Unix installations (In Real Life: Mike Ditto) has grown to 10, with more expected." ford@kenobi.cts.com - The Unix Programmer's Manual, ...!sdcsvax!crash!elgar!ford 2nd Edition, June, 1972. ditto@cbmvax.commodore.com