On May 3, 2012, at 2:56 PM, Chris Schanzle wrote:
> On 05/03/2012 02:23 PM, aurfalien wrote:
>> On May 3, 2012, at 2:11 PM, Florian Philipp wrote:
>>
>>> Am 03.05.2012 20:01, schrieb aurfalien:
>>>> Hi all,
>>>>
>>>> I never really paid attention to this but a file on an NFS mount is
>>>> showing 64M in size, but when copying the file to a local drive, it
>>>> shows 2.5MB in size.
>>>>
>>>> My NFS server is hardware Raided with a volume stripe size of 128K
>>>> were the volume size is 20TB, my local disk is about 500GB.
>>>>
>>>> Is this due to my stripe size?
>>>>
>>>> Nuggets are appreciated.
>>>>
>>>> - aurf
>>> Is it a sparse file? What exact command did you use to calculate the
>>> file size?
>>>
>>> Regards,
>>> Florian Philipp
>>>
>> By the way, this is only across NFS as when ssh'd into the server, the file
>> size shows 2.5M, same as the clients when its local so its seems NFS is the
>> culprit.
>>
>> I have r/wsize tweaked but thats it.
>>
>> Any ideas?
>>
>> - aurf
>
> RHEL 5 and 6 'cp' utility enables 'crude heuristic' sparse file detection
> ('man ls'). compare results with:
>
> cp --sparse=never /nfsserver/file var/tmp/
>
> and without the --sparse option.
>
> the 'stat' utility is also handy to compare actual disk blocks used vs byte
> size. Most filesytems default to 4 KB or eight 512-byte blocks.
>
> 'ls -sl' also shows disk blocks (usually in KB, not 'filesystem blocks') used
> in first column of output.
>
> NFS options or RAID block size won't matter here, but the NFS file server's
> *filesystem* block size can make a difference of how many disk blocks are
> actually used on the disk (local or remote). E.g., one of our NFS servers
> has a 32K filesystem block size. A one-byte file takes 32K of disk space on
> that box.
Hi all,
It was my fstab mount option of allocsize=64m that caused this issue.
Just wanted to report back.
Thanks to all who responded to my call for help, I very much appreciate it.
- aurf
>