Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Oct 1998 11:44:10 +0930
From:      Greg Lehey <grog@lemis.com>
To:        Terry Lambert <tlambert@primenet.com>, francisco@natserv.com
Cc:        freebsd-fs@FreeBSD.ORG
Subject:   Re: Optimizing space utilization
Message-ID:  <19981013114410.A21983@freebie.lemis.com>
In-Reply-To: <199810122018.NAA21730@usr07.primenet.com>; from Terry Lambert on Mon, Oct 12, 1998 at 08:18:53PM %2B0000
References:  <199810110304.XAA22392@federation.addy.com> <199810122018.NAA21730@usr07.primenet.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Monday, 12 October 1998 at 20:18:53 +0000, Terry Lambert wrote:
>>>> On a 1 Gig partition by using 1/4 the number of inodes (sent -i 16384
>>>> to  newfs) I was able to save a little over 30MB. A 3% saving. :-)
>>>> I was still left with over 64K inodes, which I doubt I will use.
>>
>>> Interesting.  At 262 bytes per inode, I'd only expect a saving of
>>> about 12 MB.
>
> Uh, what are you smoking?

Cooked inodes.

> An inode is 128 bytes, exactly, including reserve space.

Oops.  The in-core inode is 262 bytes, which isn't particularly
relevant to the disk.  Where should I have been looking (i.e. which
file?).

> Are you perhaps counting the mandatory 24 byte overhead on a directory
> entry, and assuming a 110 byte file name?  If so, you should be
> aware that flexname allocations must round to 4 byte boundaries,
> so you are off by 2 (108 and 112 are evenly divisible by 4).

No.  Here's a test program:

#define MAXQUOTAS 2
#include "/T/vinum/vinumhdr.h"
#include <ufs/ufs/inode.h>
main ()
{
  printf ("inode size is %d\n", sizeof (struct inode));
  }

The MAXQUOTAS is because I didn't want a whole slew of knotted header
files.  vinumhdr is gratuitous, but save more knotted header files.

Greg
--
See complete headers for address, home page and phone numbers
finger grog@lemis.com for PGP public key

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-fs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19981013114410.A21983>