DragonFly BSD
DragonFly kernel List (threaded) for 2004-08
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: Re2: out of inodes... new install


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 6 Aug 2004 11:08:42 -0700 (PDT)

:For getting the default fragsize/blocksize in the installer, I followed
:disklabel's man page, which states:
:
:     fsize   For 4.2BSD and LFS file systems only, the fragment size.
:             Defaults to 1024 for partitions smaller than 1GB, 4096 for
:             partitions 1GB or larger.
:
:     bsize   For 4.2BSD and LFS file systems only, the block size. 
:             Defaults to 8192 for partitions smaller than 1GB, 16384 for
:             partitions 1GB or larger.
:
:I take it that "4096" is a typo (size-o?) in the man page?
:
:At any rate there is a way to change this in the installer - in "Create
:Subpartitions", select "Switch to Expert Mode" and you can change the
:fragsize and blocksize to anything you like.
:
:-Chris

    The two go together and should generally use a 1:8 ratio.  e.g.
    1K/8K, 2K/16K, 4K/32K.  I recommend 2K/16K.  The buffer cache is tuned
    for 16K blocks and if you use larger blocks you can fragment the buf_map
    (which may or may not reduce system performance).

    I think the real 'bug' is that the default bytes/inode is calculated
    based on the fragment size rather then simply a fixed constant.
    Using 2K/16K for /usr ought be perfectly acceptable if one also
    specifies the -i option to set the bytes/inode.

    -

    For the installer I recommend immediately changing the 4K/16K to 2K/16K,
    and then considering adding a heuristic for /usr that tries to leave room
    for the files that are expected to be placed there (/usr/ports, /usr/src,
    and a fully populated /usr/obj) by setting the default bytes/inode based
    on the size of the partition.  That might be a little involved from a UI
    perspective since you would want to recalculate whenever the size is
    changed and would also want the user to be able to override it.

    On one of my machines I get:

    find /usr/obj/. | wc -l	...	145K
    find /usr/src/. | wc -l	...	 92K
    find /usr/ports/. | wc -l	...	167K

    that's 404K files, not including base files in /usr.  So I am thinking
    that for /usr we have to use 1K/8K (which ought to give around ~700K
    inodes on a 3G partition).

					-Matt
					Matthew Dillon 
					<dillon@xxxxxxxxxxxxx>



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]