CEPH filesystem development
 help / color / mirror / Atom feed
From: Phil Carns <carns@mcs.anl.gov>
To: Yehuda Sadeh Weinraub <yehudasa@gmail.com>
Cc: ceph-devel@vger.kernel.org
Subject: Re: minor file journal size bug
Date: Tue, 15 Jun 2010 14:29:38 -0400	[thread overview]
Message-ID: <4C17C692.8040705@mcs.anl.gov> (raw)
In-Reply-To: <AANLkTimuybE0Lw-2RC2VOAUKh5OWopXcp4f3fdfYs2xv@mail.gmail.com>

On 06/14/2010 01:37 PM, Yehuda Sadeh Weinraub wrote:
> On Mon, Jun 14, 2010 at 7:19 AM, Phil Carns<carns@mcs.anl.gov>  wrote:
>    
>> Hi,
>>
>> I ran into a minor problem when configuring the ObjectStore to use a file
>> journal that was 10 gigabytes in size (osd_journal_size = 10240).  The
>> osd_journal_size configuration parameter is an integer.  This would normally
>> be fine since the units are in megabytes, but it can overflow when bit
>> shifted in FileJournal.cc.  This causes the journal to fall back to trying
>> to detect a raw block device journal.
>>
>> I've attached a small patch that fixes the problem for me, but there is
>> probably a cleaner way to do it.
>>
>>      
> Thanks!
>
> Just defining osd_journal_size as a long long would do the trick (as
> follows), although I'm not sure whether we need to be able to define
> journals that are bigger than 2^32 MB. So I guess that in this case we
> should probably go with your solution, and also go over the code and
> check to see whether we have some other places where we do the same.
> We should really be using some macro that does this conversion with a
> correct cast.
>
> Yehuda
>    

Thanks Yehuda.  I don't know what the right long term answer is, but 
either way works fine for my test case (I just tried your patch to confirm).

-Phil

      reply	other threads:[~2010-06-15 18:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-14 14:19 minor file journal size bug Phil Carns
2010-06-14 17:37 ` Yehuda Sadeh Weinraub
2010-06-15 18:29   ` Phil Carns [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4C17C692.8040705@mcs.anl.gov \
    --to=carns@mcs.anl.gov \
    --cc=ceph-devel@vger.kernel.org \
    --cc=yehudasa@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox