Re: any change in fs block allocation between current and stable ?
On 2000-Feb-15 10:17:35 +1100, Matthew Dillon <[EMAIL PROTECTED]> wrote: > >:> You can't change this behavior. UFS can only use a file fragment (that >:> is, typically 1/8 of a full block) at the *END* of a file, not the middle. >: >:pardon the ignorance (but i don't have the red book handy), >:thas that mean that if you need 1 frag+1 byte you end up using a full >:block ? > >I believe so, but I'm not 100% sure. That's not what is reported in the inode's block count. The following is on an 8K/1K filesystem: gsmx07% ls -lis total 160 761017 2 -rw-r--r-- 1 jeremyp inplat 1024 Feb 16 08:22 b1 761018 4 -rw-r--r-- 1 jeremyp inplat 1025 Feb 16 08:22 b1+1 761019 4 -rw-r--r-- 1 jeremyp inplat 2048 Feb 16 08:22 b2 761021 6 -rw-r--r-- 1 jeremyp inplat 2049 Feb 16 08:22 b2+1 761022 6 -rw-r--r-- 1 jeremyp inplat 3072 Feb 16 08:22 b3 761024 8 -rw-r--r-- 1 jeremyp inplat 3073 Feb 16 08:22 b3+1 761025 8 -rw-r--r-- 1 jeremyp inplat 4096 Feb 16 08:22 b4 761026 10 -rw-r--r-- 1 jeremyp inplat 4097 Feb 16 08:22 b4+1 761027 10 -rw-r--r-- 1 jeremyp inplat 5120 Feb 16 08:22 b5 761052 12 -rw-r--r-- 1 jeremyp inplat 5121 Feb 16 08:22 b5+1 761053 12 -rw-r--r-- 1 jeremyp inplat 6144 Feb 16 08:22 b6 761054 14 -rw-r--r-- 1 jeremyp inplat 6145 Feb 16 08:22 b6+1 761055 14 -rw-r--r-- 1 jeremyp inplat 7168 Feb 16 08:22 b7 761056 16 -rw-r--r-- 1 jeremyp inplat 7169 Feb 16 08:22 b7+1 761057 16 -rw-r--r-- 1 jeremyp inplat 8192 Feb 16 08:22 b8 761058 18 -rw-r--r-- 1 jeremyp inplat 8193 Feb 16 08:22 b8+1 gsmx07% Peter To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: any change in fs block allocation between current and stable ?
On Mon, Feb 14, 2000 at 10:30:53PM +0100, Luigi Rizzo wrote: > > You can't change this behavior. UFS can only use a file fragment (that > > is, typically 1/8 of a full block) at the *END* of a file, not the middle. > > pardon the ignorance (but i don't have the red book handy), > thas that mean that if you need 1 frag+1 byte you end up using a full > block ? Nope. You can have a frag that is a multiple of the minimal frag size. For instance an 11K file uses two 4k full blocks and one 3k frag. [example taken from McKusick's UNIX Internals class notes] >From the red Daemon book, pp.272: The fragment size is specified at the time that the filesystem is created; each file system block can be broken down into two, four, or eight fragments [parts]; each of which is addressable. Enjoy! -- -- David([EMAIL PROTECTED]) To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: any change in fs block allocation between current and stable ?
:> You can't change this behavior. UFS can only use a file fragment (that :> is, typically 1/8 of a full block) at the *END* of a file, not the middle. : :pardon the ignorance (but i don't have the red book handy), :thas that mean that if you need 1 frag+1 byte you end up using a full :block ? : : cheers : luigi I believe so, but I'm not 100% sure. -Matt Matthew Dillon <[EMAIL PROTECTED]> To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: any change in fs block allocation between current and stable ?
> You can't change this behavior. UFS can only use a file fragment (that > is, typically 1/8 of a full block) at the *END* of a file, not the middle. pardon the ignorance (but i don't have the red book handy), thas that mean that if you need 1 frag+1 byte you end up using a full block ? cheers luigi To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: any change in fs block allocation between current and stable ?
:Hi, :I have a question related to ufs block allocation. :This problem arises when building picobsd floppy on /dev/fd0 :(ufs with 512/4096 fragments/blocks). : :With 3.4, i can easily fill up a disk to 100% occupation. : :With -current (2127), i often fail to write a file (say 53KB) :on disk even though there _is_ room (say 55KB), and if i split the file :in multiple parts i can write on that disk even more bytes :than the original file size. : :It looks like there is some change related to the use of file :system fragments, the feeling i have is that there is :something like : :"if you need to write a full block, don't look for :fragments but for a full block'. : :Does the above sound reasonable, and if so, would it be difficult :to change the behaviour to make use of fragments if there is :no better option ? : : cheers : luigi :---+- : Luigi RIZZO, [EMAIL PROTECTED] . Dip. di Ing. dell'Informazione : http://www.iet.unipi.it/~luigi/ . Universita` di Pisa You can't change this behavior. UFS can only use a file fragment (that is, typically 1/8 of a full block) at the *END* of a file, not the middle. Once a fragment has been allocated out of a full block, it cannot be used as a full block again until the fragment(s) have been deallocated. This means that there may be free fragments available when there are no full blocks available, allowing small files to continue to be created while larger files fail. -Matt Matthew Dillon <[EMAIL PROTECTED]> To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: any change in fs block allocation between current and stable ?
http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/ufs/ffs/ffs_alloc.c you may want to investigate revision 1.62. * Luigi Rizzo <[EMAIL PROTECTED]> [000212 03:19] wrote: > Hi, > I have a question related to ufs block allocation. > This problem arises when building picobsd floppy on /dev/fd0 > (ufs with 512/4096 fragments/blocks). > > With 3.4, i can easily fill up a disk to 100% occupation. > > With -current (2127), i often fail to write a file (say 53KB) > on disk even though there _is_ room (say 55KB), and if i split the file > in multiple parts i can write on that disk even more bytes > than the original file size. > > It looks like there is some change related to the use of file > system fragments, the feeling i have is that there is > something like > > "if you need to write a full block, don't look for > fragments but for a full block'. > > Does the above sound reasonable, and if so, would it be difficult > to change the behaviour to make use of fragments if there is > no better option ? > > cheers > luigi > ---+- > Luigi RIZZO, [EMAIL PROTECTED] . Dip. di Ing. dell'Informazione > http://www.iet.unipi.it/~luigi/ . Universita` di Pisa > TEL/FAX: +39-050-568.533/522 . via Diotisalvi 2, 56126 PISA (Italy) > Mobile +39-347-0373137 > ---+- > > > To Unsubscribe: send mail to [EMAIL PROTECTED] > with "unsubscribe freebsd-current" in the body of the message -- -Alfred Perlstein - [[EMAIL PROTECTED]|[EMAIL PROTECTED]] To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
any change in fs block allocation between current and stable ?
Hi, I have a question related to ufs block allocation. This problem arises when building picobsd floppy on /dev/fd0 (ufs with 512/4096 fragments/blocks). With 3.4, i can easily fill up a disk to 100% occupation. With -current (2127), i often fail to write a file (say 53KB) on disk even though there _is_ room (say 55KB), and if i split the file in multiple parts i can write on that disk even more bytes than the original file size. It looks like there is some change related to the use of file system fragments, the feeling i have is that there is something like "if you need to write a full block, don't look for fragments but for a full block'. Does the above sound reasonable, and if so, would it be difficult to change the behaviour to make use of fragments if there is no better option ? cheers luigi ---+- Luigi RIZZO, [EMAIL PROTECTED] . Dip. di Ing. dell'Informazione http://www.iet.unipi.it/~luigi/ . Universita` di Pisa TEL/FAX: +39-050-568.533/522 . via Diotisalvi 2, 56126 PISA (Italy) Mobile +39-347-0373137 ---+- To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message