fpt@wgivax.UUCP (Fred Toth #7252) (09/06/85)
Version 7 had a bug that would allow more blocks to be allocated to an inode than the size field required. This was totally consistant, in that fsck would not complain. Allocated blocks plus free blocks still equaled total blocks. I suspect this is your problem. We first found this problem after porting the SV program dcopy to our version 7 system. After running a test dcopy to reorganize the disk, we ended up with a few thousand more free blocks. Hmm, must be a bug in the port, right? Well, after much head scratching and studying of the dcopy source, I decided to write a program to check the above mentioned condition. Sure enough, our missing blocks were there all along, allocated to files that had no use for them. I will post a copy of scani.c to net.sources. If you don't get it and you want a copy, drop me a line. Scani reads the disk directly, and reports inode numbers that fall into this class. You can use ncheck to get the names. Copying and deleting the original files will free up the space. I never bothered to look for the problem in v7. Maybe someone else out there knows about this bug and how to fix it. Obviously it's still around. Fred Toth Washburn Graphics, Inc. Charlotte, NC decvax!mcnc!unccvax!wgivax!fpt
campbell@maynard.UUCP (Larry Campbell) (09/08/85)
> Version 7 had a bug that would allow more blocks to be allocated > to an inode than the size field required. This was totally > consistant, in that fsck would not complain. Allocated blocks > plus free blocks still equaled total blocks. > > I suspect this is your problem. > > Fred Toth > Washburn Graphics, Inc. > Charlotte, NC > decvax!mcnc!unccvax!wgivax!fpt Yes, indeed. Last night it happened again and I went adb-ing through the inode for /usr/lib/news/history. It was a "large" file, with 70 blocks. The first i_addr entry pointed to a perfectly reasonable indirect block with 70 entries followed by zeroes. But i_addr[1] through i_addr[8] also contained pointers to indirect blocks, which in turn pointed to all the lost disk space. Copying the history file and deleting the original freed up the lost blocks. Later this weekend I'll try running the scani program you posted to see if any other files are involved. Any insights into what provokes the bug, possible fixes or workarounds, would be greatly appreciated. -- Larry Campbell decvax!genrad The Boston Software Works, Inc. \ 120 Fulton St. seismo!harvard!wjh12!maynard!campbell Boston MA 02109 / / ihnp4 cbosgd ARPA: campbell%maynard.uucp@harvard.arpa