[Top] [All Lists]

Re: Contiguous file sequences

To: Daire Byrne <daire.byrne@xxxxxxxxx>
Subject: Re: Contiguous file sequences
From: Matthias Schniedermeyer <ms@xxxxxxx>
Date: Mon, 27 Sep 2010 20:35:16 +0200
Cc: Eric Sandeen <sandeen@xxxxxxxxxxx>, xfs@xxxxxxxxxxx
In-reply-to: <AANLkTi=xPjAtjP5E6XK8Xhgvo1FoqAEUKLvDrNJO3-OH@xxxxxxxxxxxxxx>
References: <AANLkTikHqjvEGJb0XnNy+nz7+nHLVLwjF_wp5RZdk_1-@xxxxxxxxxxxxxx> <4C9A6298.106@xxxxxxxxxxx> <AANLkTinz4rYCb8cHH69pYy-oPT-041y+DmVaWm3N_1hu@xxxxxxxxxxxxxx> <4CA018D9.1030803@xxxxxxxxxxx> <AANLkTi=xPjAtjP5E6XK8Xhgvo1FoqAEUKLvDrNJO3-OH@xxxxxxxxxxxxxx>
User-agent: Mutt/1.5.19 (2009-01-05)
On 27.09.2010 17:30, Daire Byrne wrote:
> Eric,
> On Mon, Sep 27, 2010 at 5:08 AM, Eric Sandeen <sandeen@xxxxxxxxxxx> wrote:
> > Daire Byrne wrote:
> >>> Why is this the goal, what are you trying to achieve?
> >>
> >> I am essentially trying to play back a large frame sequence and trying
> >> to minimise seeks as it can lead to sporadic slowdowns on a SATA based
> >> RAID.
> >
> > Ok - and you've really seen allocation patterns that cause the playback
> > to slow down?  xfs_bmap information for a few sequential files that were
> > this far off would be interesting to see.
> >
> > Are you certain that it's seekiness causing the problem?  A great way
> > to visualize it would be to use the seekwatcher application while you
> > run a problematic file sequence.
> I'm certain that the seekiness is the culprit. The image files are
> pretty big and require 400MB/s+ speeds to play them back at full rate.
> I can play a sequence which is aligned perfectly on disk just fine
> (readahead) but when seeks are required between frames the framerate
> drops noticeably. I'm using SATA disks which probably doesn't help
> matters.

As long as the disc-subsystem can sustain more than 400MB/s, there is a 
way to do "poor men's mega readahead".

I assume the sequence in which the files are accessed is predetermined 
and RAM is plentiful?

Then you can write a program/script that utilizes inotify to identify 
the file that is currently read and reads, say, 15 frames ahead, 
assuming that the sequence has 30fps the physical disc access is then 
about 1/2 a second ahead of time.

Of course the disc-subsystem has to be able to do bursts of more than 
400MB/s, so that when there is "stuttering" it can catch up before the 
"buffer runs empty".

A solution with a guarantee that the files stay in RAM could be done 
with a tmpfs. Depending on the playing program you may have to fake a 
little, but either sparse-files or symlinks should do the trick to have 
every file visible and replacing it with the real file/content a little 
before it is used and droping it afterwards.

Bis denn

Real Programmers consider "what you see is what you get" to be just as 
bad a concept in Text Editors as it is in women. No, the Real Programmer
wants a "you asked for it, you got it" text editor -- complicated, 
cryptic, powerful, unforgiving, dangerous.

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