Bluehost.com Web Hosting $6.95

Re: [courier-users] Command line tool to calculate Maildir size?

This is a discussion on Re: [courier-users] Command line tool to calculate Maildir size? within the Courier-Imap forums, part of the Mail Servers and Related category; Ben Kennedy wrote: > Juri Haberland wrote at 5:09 pm (+0200) on 23 6 2005: > >>Because -...


Go Back   Usenet Forums > Mail Servers and Related > Courier-Imap

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-23-2005
Juri Haberland
 
Posts: n/a
Default Re: [courier-users] Command line tool to calculate Maildir size?

Ben Kennedy wrote:
> Juri Haberland wrote at 5:09 pm (+0200) on 23 6 2005:
>
>>Because -b includes --apparent-size.
>>Try again with -B1 instead of -b.

>
> You're right, -B1 gives a count which is visually more consistent with
> the "human-readable" total:
>
> basil ben # du -sB1 ~zygoat/Maildir
> 289280 /home/zygoat/Maildir
> basil ben # du -sb ~zygoat/Maildir
> 103316 /home/zygoat/Maildir
> basil ben # du -sh ~zygoat/Maildir
> 283K /home/zygoat/Maildir
>
> However, neither -B1 nor --apparent-size are mentioned in my man page at
> all. I had no idea such options existed. Weird.
>
> Moreover, what is the correct count? 289280 bytes? What is the 103316
> value in the above, then?


As far as I understand the man page, --aparent-size returns the size of
the file(s), whereas without --aparent-size the size allocated on disk
is returned. See the following example:

[juri@kaplah juri]$ echo "foo" > bar
[juri@kaplah juri]$ du -sh bar
4.0K bar
[juri@kaplah juri]$ du -sB1 bar
4096 bar
[juri@kaplah juri]$ du -sb bar
4 bar
[juri@kaplah juri]$

Cheers,
Juri


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
courier-users mailing list
courier-users@lists.sourceforge.net
Unsubscribe: https://lists.sourceforge.net/lists/.../courier-users
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 05:28 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0