public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Brian Duncan <brianmduncan@gmail.com>
To: linux-xfs@oss.sgi.com
Subject: Re: xfssyncd and disk spin down
Date: Mon, 14 Feb 2011 18:04:23 +0000 (UTC)	[thread overview]
Message-ID: <loom.20110214T185310-606@post.gmane.org> (raw)
In-Reply-To: 20110210221851.GG2559@dastard

Dave Chinner <david <at> fromorbit.com> writes:

> 
> On Thu, Feb 10, 2011 at 10:42:54PM +0200, Petre Rodan wrote:
> > 
> > Hello Dave,
> > 
> > On Fri, Jan 21, 2011 at 10:43:10AM +1100, Dave Chinner wrote:
> > > .....
> > > > in other words xfsyncd and xfsbufd now alternate at 18s intervals
> > > > keeping the drive busy with nothing constructive hours after the
> > > > last write to the drive.
> > > 
> > > This is a different problem, and not one I've seen before. Looking
> > > at the traces, it appears that we have not empties the AIL. At
> > > least, that's what I'm assuming at this point because log IO
> > > completion is not updating log tail. When we start a log IO, we set
> > > the log header lsn to the current head:
> > > 
> > > >    xfssyncd/sdc1-1413  [000]  3356.093456: xfs_log_reserve: dev 8:33
type DUMMY1 t_ocnt 1 t_cnt 1
> t_curr_res 2740 t_unit_res 2740 t_flags XLOG_TIC_INITED reserveq empty writeq
empty
> grant_reserve_cycle 2 grant_reserve_bytes 428523008 grant_write_cycle 2
grant_write_bytes
> 428523008 curr_cycle 2 curr_block 836959 tail_cycle 2 tail_block 810683
> > > 
> > > Which in this case is: curr_cycle 2 curr_block 836959
> > > 
> > > When the log IO completes, that value gets written to the
> > > l_last_sync_lsn. When the AIL tail is removed, the tail lsn is
> > > updated to the new tail item. If the AIL is empty, then the
> > > l_last_sync_lsn is used. That means then next dummy transaction
> > > made to cover the log should have the cycle/block of the above
> > > current cycle.
> > > 
> > > Instead, what I see is that the next dummmy transaction shows:
> > > 
> > > >    xfssyncd/sdc1-1413  [000]  3392.067122: xfs_log_reserve: dev 8:33
type DUMMY1 t_ocnt 1 t_cnt 1
> t_curr_res 2740 t_unit_res 2740 t_flags XLOG_TIC_INITED reserveq empty writeq
empty
> grant_reserve_cycle 2 grant_reserve_bytes 428524032 grant_write_cycle 2
grant_write_bytes
> 428524032 curr_cycle 2 curr_block 836961 tail_cycle 2 tail_block 810683
> > > 
> > > The current head has moved: curr_cycle 2 curr_block 836961
> > > 
> > > But the tail hasn't: tail_cycle 2 tail_block 810683
> > > 
> > > So effectively we've got some item on the AIL that we haven't
> > > flushed and isn't being flushed by xfssyncd. That's the problem I
> > > need to get to the bottom of and it also explains why it's an
> > > intermitten problem...
> > 
> > I have been watching the stream of patches that go into 2.6.38,
> > but I probably missed the one that might be the answer to the
> > problem above. can you please tell me which one to try, or can I
> > help with anything?
> 
> I know what the problem is, but I haven't had time to work out of
> code a fix. Been spending my time trying to work out the cause bugs
> that are triggering hangs, crashes or corruptions here...
> 
> Cheers,
> 
> Dave.


FYI,

I found this thread after searching.. I upgraded one of my servers and
encountered this issue with XFS keeping drives from going to sleep with its
constant writing (after a copy to a volume).

I just wanted to note that I have an XFS volume that does have lazy-count set to
1 that this is occuring with, with 2.6.327. 

meta-data=/dev/sdf1              isize=256    agcount=4, agsize=122094500 blks
         =                       sectsz=512   attr=2
data     =                       bsize=4096   blocks=488378000, imaxpct=5
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0
log      =internal               bsize=4096   blocks=238465, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0

After writing any data to this drive, this would occur indefinitely:(until I
unmount and remount the drive)

[ 2839.120064] xfssyncd/sdf1(756): WRITE block 1954432155 on sdf1 (2 sectors)
[ 2869.120065] xfssyncd/sdf1(756): WRITE block 1954432157 on sdf1 (2 sectors)
[ 2899.120066] xfssyncd/sdf1(756): WRITE block 1954432159 on sdf1 (2 sectors)
[ 2929.120065] xfssyncd/sdf1(756): WRITE block 1954432161 on sdf1 (2 sectors)
[ 2959.120060] xfssyncd/sdf1(756): WRITE block 1954432163 on sdf1 (2 sectors)
[ 2989.120061] xfssyncd/sdf1(756): WRITE block 1954432165 on sdf1 (2 sectors)
[ 3019.120058] xfssyncd/sdf1(756): WRITE block 1954432167 on sdf1 (2 sectors)
[ 3049.120056] xfssyncd/sdf1(756): WRITE block 1954432169 on sdf1 (2 sectors)
[ 3079.120058] xfssyncd/sdf1(756): WRITE block 1954432171 on sdf1 (2 sectors)
[ 3109.120059] xfssyncd/sdf1(756): WRITE block 1954432173 on sdf1 (2 sectors)
[ 3139.120065] xfssyncd/sdf1(756): WRITE block 1954432175 on sdf1 (2 sectors)
[ 3169.120061] xfssyncd/sdf1(756): WRITE block 1954432177 on sdf1 (2 sectors)
[ 3199.120062] xfssyncd/sdf1(756): WRITE block 1954432179 on sdf1 (2 sectors)
[ 3229.120060] xfssyncd/sdf1(756): WRITE block 1954432181 on sdf1 (2 sectors)
[ 3259.120067] xfssyncd/sdf1(756): WRITE block 1954432183 on sdf1 (2 sectors)


_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

  reply	other threads:[~2011-02-14 18:07 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-23 16:55 xfssyncd and disk spin down Petre Rodan
2010-12-23 19:29 ` Stan Hoeppner
2010-12-23 21:16   ` Petre Rodan
2010-12-24  0:54     ` Stan Hoeppner
2010-12-24  5:15       ` Stan Hoeppner
2010-12-24  6:02       ` Petre Rodan
2010-12-24 23:00         ` Stan Hoeppner
2010-12-25  3:36           ` Eric Sandeen
2010-12-25  4:32             ` Stan Hoeppner
2010-12-24 18:17 ` Eric Sandeen
2010-12-25 12:09   ` Petre Rodan
2010-12-27  2:19 ` Dave Chinner
2010-12-27  6:16   ` Petre Rodan
2010-12-27 14:07     ` Dave Chinner
2010-12-27 17:19       ` Petre Rodan
2010-12-31  0:13         ` Dave Chinner
2011-01-20 10:01           ` Petre Rodan
2011-01-20 11:06             ` Dave Chinner
2011-01-20 12:07               ` Petre Rodan
2011-01-20 13:24                 ` Christoph Hellwig
2011-01-20 23:43             ` Dave Chinner
2011-02-10 20:42               ` Petre Rodan
2011-02-10 22:18                 ` Dave Chinner
2011-02-14 18:04                   ` Brian Duncan [this message]
2011-05-31 14:40                     ` Brian Duncan
2011-05-31 15:16                       ` Michael Weissenbacher
2011-06-01 23:37                         ` Dave Chinner
2011-07-11  4:02                           ` Brian Duncan
2011-07-11 14:34                             ` Michael Weissenbacher

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=loom.20110214T185310-606@post.gmane.org \
    --to=brianmduncan@gmail.com \
    --cc=linux-xfs@oss.sgi.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