On Thu, May 26, 2005 at 10:39:11AM -0700, Ken A wrote:
> Clifton Royston wrote:
> >On Wed, May 25, 2005 at 02:47:39PM -0700, Ken A wrote:
...
> >>I think found a way to work around this, at least with linux kernel 2.4 
> >>and up. The fix is to put the temp drop on a different partition so the 
> >>quota system doesn't see it, and then use the vfs feature "mount --bind" 
> >>to remount the temp drop filesystem as part of the /var/spool 
> >>filesystem. ie: mount --bind /var/tempdrop /var/spool/tempdrop
> >>
> >>This allows qpopper to rename files using fast-update, and since the 
> >>quota system is looking at the underlying filesystem, it ignores files 
> >>in the temp drop directory.
...
> >  I just talked to a more Linux-oriented friend who thinks this might
> >simply result in the same file copy happening, but hidden from you
> >because it's been pushed down into the kernel level where vfs resides. 
> >He's not sure, though.  Before concluding that this really had the
> >effect you want, I would try turning on detailed timing info; you might
> >find that the "relink" is now taking approximately as much time as the
> >file copy used to, because it's now actually doing a file copy.
> >  I'll be interested to hear the results.
> 
> Qpopper's --enable-timing only resolves to seconds afaik, so I did some 
> testing copying a large file with perl's Time::HiRes, and system("mv"). 
> I'm assuming mv uses relink() just like qpopper. (not much of a C 
> programmer here!)
> 
> Apparently, the mount --bind option doesn't really give any advantage
> over leaving the temp-drop on a different partition. :-(
> 
> Time to copy on same partition: 0.147061
> Time to move on same partition: 0.001959
> Time to move to with bound partition: 0.150901
> Time to move across partitions: 0.151158

  Oh well, TANSTAAFL, I guess.  I was really hoping you were on to
something here, but logic was telling me it couldn't be that good. :-/

  Thanks for the followup!

  -- Clifton

-- 
          Clifton Royston  --  [EMAIL PROTECTED] 
         Tiki Technologies Lead Programmer/Software Architect
"I'm gonna tell my son to grow up pretty as the grass is green
And whip-smart as the English Channel's wide..."
                                            -- 'Whip-Smart', Liz Phair

Reply via email to