Low Level Record Length Question ...

Ben Duncan bns
Tue Sep 13 11:02:23 PDT 2005


Am working diligently on my MVDBM SLAG database. I am looking at making
the minimum (since the system will be variable length records/fields)
Record/Block in 512 Bytes.

Is that the most effective size?

What I intend to do is to start each new record with 512 Bytes (there
is a header in each record, so that is not the "true" user size).
If/When the record exceeds 512 Bytes, and it exceeds it's slot size,
add another 512 bytes to the block allocation, write the new size to the file
end and free up the current "block" allocation for re-use.

All allocation will be done in x512 byte increments. For example, OLD
record size is 900 bytes of user data (2 blocks) and it gets added 1750
more bytes of user data, the new record/block will be 3072 and stuck
at the end of the file (or if there is a freeblock that size, in that
freeblock).

Does that sound like a winner ? Any comments, suggestions ?


Thanks ...


-- 
Ben Duncan   - VersAccounting Software LLC 336 Elton Road  Jackson MS, 39212
"Never attribute to malice, that which can be adequately explained by stupidity"
        - Hanlon's Razor



More information about the Linux-users mailing list