title
Products            Buy            Support Forum            Professional            About            Codec Central
 

pre-allocate files to avoid fragmentation

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bmacnaughton
    • Oct 2006
    • 13

    pre-allocate files to avoid fragmentation

    I just converted a number of files from FLAC to MP3 for portable use. Because the converter runs in multithreaded mode it manages to fragment each file quite significantly - three Keith Jarret files (long, to be sure) are 234, 579, and 605 fragments. While Windows will get around to defragmenting them over time it would, in the meantime, improve the performance of the conversion if you pre-allocated then truncated the files based on a reasonable guess of the target size. If one is writing to a USB thumb-drive the performance improvement would be orders or magnitude; even writing to disk will be dramatic.

    I think this is the method for doing this:



    It can extend the size (without actually writing data) or truncate (if you extended too far).

    Thanks.
  • Spoon
    Administrator
    • Apr 2002
    • 43888

    #2
    Re: pre-allocate files to avoid fragmentation

    Not a bad idea
    Spoon
    www.dbpoweramp.com

    Comment

    • Sardonyx
      • Jun 2011
      • 10

      #3
      Re: pre-allocate files to avoid fragmentation

      Perhaps an option "encode to RAM"?

      I have been experimenting with a RAMdrive and [encode local]. My concern was the performance hit of thrashing 8 files (quad core w/hyperthreading). There is a HUGE performance boost if the output is written to the same HDD as the input files, not so much using different drives. I wasn't thinking of the resulting fragmentation.

      My idea for "encode to RAM" is it would work similar fashion, but without forcing the user to install RAMdrive software.

      Comment

      • smisk
        dBpoweramp Enthusiast
        • Jan 2009
        • 61

        #4
        Re: pre-allocate files to avoid fragmentation

        Originally posted by Sardonyx
        Perhaps an option "encode to RAM"?
        Well you already have the "encode to local disk" DSP why don't you check it out. When it is finished with your file (building file, adding tags, running user-specified external progs) it will move your file to another (network) location

        Comment

        • Casperig
          • Apr 2012
          • 1

          #5
          Re: pre-allocate files to avoid fragmentation

          I vote for this as well.

          Comment

          • Michael Sargent
            dBpoweramp Enthusiast
            • Dec 2009
            • 133

            #6
            Re: pre-allocate files to avoid fragmentation

            Originally posted by smisk
            Well you already have the "encode to local disk" DSP why don't you check it out. When it is finished with your file (building file, adding tags, running user-specified external progs) it will move your file to another (network) location
            I don't seem to see an "encode to local disk" DSP. Is there another name for it? Or does it needed to be downloaded separately? If so, would you mind sharing the URL?

            Thanks,
            Mike

            Comment

            Working...

            ]]>