Re: [SLE] slow reiserfs?

From: Danny Sauer (suse-linux-e.suselists_at_danny.teleologic.net)
Date: 09/09/04

  • Next message: James Knott: "Re: [SLE] Remote Desktop Connection"
    Date: Thu, 9 Sep 2004 16:39:06 -0500
    To: SuSE List <suse-linux-e@suse.com>
    
    

    Randall wrote regarding 'Re: [SLE] slow reiserfs?' on Thu, Sep 09 at 13:15:
    > Dave, Danny,
    >
    >
    > On Thursday 09 September 2004 10:46, Danny Sauer wrote:
    > > Dave wrote regarding '[SLE] slow reiserfs?' on Thu, Sep 09 at 08:06:
    > > > I'm trying to discover the cause of some long delays in the running
    > > > of a program.
    > > >
    > > > I'm running a Perl script that is comparing the files in two
    > > > directories. There are about 150,000 files of a few KB each in each
    > > > directory, which mostly correspond but they're not all identical. My
    > > > script is running diff on each pair. It prints a timestamped line for
    > > > each pair and this scrolls up the screen but sometimes stops for
    > > > several seconds - ten is the most I've noticed -
    >
    > Dave, you say you're using "diff" to compare the files. Do you need to
    > know exactly _how_ the files differ, or only _that_ they differ? If it's
    > the latter, then use the "cmp" command and you'll cut down on the CPU
    > time consumed. Of course, this will only make the process more disk-bound
    > than it already is, but that's still going produce some improvement in
    > overall run-time.

    Either way, it'd be faster to use one of the perl modules that implements
    the diff algorithm rather than launching the diff program. If it's just
    "do they differ" then it'd be quicker to just cmp them line by line...
    Calculating a checksum will require reading the whole file, and by the
    time you've read in the file, you could've been comparing it to the other
    file and be done. A checksum would only be useful if you were using the
    contents of the file more than once - in which case it'd cut down on memory
    consumption quite a bit (though you'd still have to compare the files
    directly if the checksum matched, given the possibility of multiple
    files generating the same checksum with some algorithms).

    Ignore the whole "read them into memory" thing, though. I read the
    OP as "comparing the files in the directories" instead of "comparing
    the files in two directories".

    --Danny, who should really change his screen font...

    -- 
    Check the headers for your unsubscription address
    For additional commands send e-mail to suse-linux-e-help@suse.com
    Also check the archives at http://lists.suse.com
    Please read the FAQs: suse-linux-e-faq@suse.com
    

  • Next message: James Knott: "Re: [SLE] Remote Desktop Connection"

    Relevant Pages

    • Re: Best Performance File Compare: MD5/SHA1 or Byte-by-Byte Checking?
      ... you might want to use the method that loops ... the entire contents of the two files into memory. ... comparing the chunks, you are going to make the process much more efficient. ... What about MD5? ...
      (microsoft.public.dotnet.languages.csharp)
    • Server Reboots BugCheck 50
      ... Loading Kernel Symbols ... Invalid system memory was referenced. ... Timestamp: unavailable ... Checksum: 00000000 ...
      (microsoft.public.windows.server.general)
    • Re: Odd Performance Issue
      ... As you can see its very basic, meant to push memory and cpu activities. ... Super PI takes 42m01s on the older machine, and 18m13s on the new one. ... The new machine should be three to four times faster in general ops (super ... Anyway, you aren't comparing CPU performance, you are ...
      (microsoft.public.dotnet.languages.csharp)
    • Re: 64-bit on the horizon? (Was Re: Vista Requirement Already)
      ... seemingly on that basis you stated that the memory footprint of 64-bit ... Hence you aren't comparing like with like. ... don't believe those results support the conclusion you are drawing from ... You believe, I show facts. ...
      (borland.public.delphi.non-technical)
    • BSOD by atapi.sys , process_name: Idle
      ... Memory dump gives me the report below. ... Frame IP not in any known module. ... Timestamp: unavailable ... Checksum: 00000000 ...
      (microsoft.public.windowsxp.hardware)