realbasic-nug
[Top] [All Lists]

Re: Wired

To: REALbasic Network Users Group <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Wired
From: Emile Schwarz <emile dot schwarz at wanadoo dot fr>
Date: Thu, 31 Jan 2002 08:35:56 +0100
Hi,

>That would true if you are still running with disks formatted as HFS. But in
>most cases today there will be no difference (with HFS+ formatted drives).
>It just depends on the block size which is normally 4K by default.


You?re mostly right. I didn?t wanted into that because in my example, a 
SimpleText file with 1 character cannot have a ?Bytes?
length so small because of the StyledData presence in the ResourceFork.
So I?d better use TeachText instead (1 character saved = 1 Byte on disk).
SimpleText uses both Forks (so 2 * 4 KB in HFS Extended), so double the file 
size.


Now, Joe Newbie is asking to itself ?I don?t understand why !?.
The answer is historical: just like the Y2K bug (in PCs), the Hard Disk Driver 
(?) originally uses a 8 Bits value to store the
number of Blocks. Then, hard disk size grows, grows, grows... and here comes 
the logical file length...

Still talking about MacOS, Apple came some years ago with HFS Extended that by 
default uses 4 KB logical length file ? since I never
go to verify if it is really possible to do, I do not say: It is possible to 
change that value, but it was said that at HFS Extended
release time ? at the performance (speed) coast.

HTH,

Emile

// ******************************************** \\
Subject: Re: Wired
From: "Kevin Rudman" <kevin dot rudman at ntlworld dot com>
Date: Wed, 30 Jan 2002 21:12:40 +0000

on 30/1/02 3:32 pm, Emile Schwarz at emile dot schwarz at wanadoo dot fr wrote:
> 
> What is the size of the two respective(s) hard disk ?
> 
> Original application size:    1.4 MB. Hard drive size (in GB):
> Manipulated application size: 2 MB. Hard drive size (in GB):
> 
> 
> Last: a one byte SimpleText file takes less than 1KB in a floppy disk (either
> 800 KB or 1.4 MB). If you copy that floppy... Err.
> that file to a 40 MB hard drive it will take more rooms in the hard drive. The
> used room increase "proportionally" to the hard disk
> drive !

That would true if you are still running with disks formatted as HFS. But in
most cases today there will be no difference (with HFS+ formatted drives).
It just depends on the block size which is normally 4K by default.

On an HFS+ drive the space occupied will be the same whether it's on a 4GB
or an 80GB drive, for example.

On floppy disks or 100MB Zip disks the minimum space occupied is less
because they format with a smaller block size (floppy 512 bytes, Zip 1.5K).

In any case a Get Info should always show the same actual byte count.

Kevin Rudman


-- 
___________________________________________________________________
?If I?d lived in Roman times, I?d lived in Rome.
Where else ?
Today America is the Roman Empire and New York is Rome itself.?

John Winston-Ono Lennon, early 70?s.



<Prev in Thread] Current Thread [Next in Thread>