Good idea or not to defragment an electronic/static drive ?
  • Order of the Butterfly
    Order of the Butterfly
    Brumiga
    Posts: 278 from 2004/4/3
    From: France
    Hello,

    A friend that does not want to be present here asked me the following question. Is it or not a Good idea to defragment an electronic/static drive ? An other guy an artificial intelligence told him that this was possible without out risk for the electronic/static device. Personnaly I think that this is not a good idea. I also think that we should wait to have the function trim implemented to allow maintaining those devices.

    Can some competent persons give a correct answer to this question ?

    Brumiga
  • »09.11.26 - 13:41
    Profile
  • Paladin of the Pegasos
    Paladin of the Pegasos
    pampers
    Posts: 1074 from 2009/2/26
    Wasn't the original idea of defragmentation to "calm down" hard drive head and give it better timings results?
    Never touched my ssd or nvme with any of defragmentation stuff but as I work mostly on linux with ZFS, I'm spoiled too much ;)
    MorphOS 3.x
  • »09.11.26 - 14:25
    Profile
  • Caterpillar
    Caterpillar
    flip
    Posts: 39 from 2005/8/25
    From: Italy
    The SSD/NVM-e Disk Driver NOT NEED to defragment. More work they do, more life cycle span are used = less life time.
    Only the classic HDD, on certain O.S. need to defrag.
  • »09.11.26 - 14:28
    Profile
  • MorphOS Developer
    geit
    Posts: 1107 from 2004/9/23
    There are basically no seek times on flash, as there is no physical head moving around, so reordering blocks does nothing but increasing the flash cycles count per cell.

    The only benefit would be that mixed blocks are reduced on writing. e.g. the SSD has 8192 blocks and the filesystem only 512. Writing any number of bytes would cause the entire 8192 block to be rewritten.

    So better find out what the SSD block size is and use the same in the file system in an aligned way. Also leave a good amount of space empty (as in untouched) at the end. If the SSD was already in use, format it on a PC to mark all blocks unused and e.g. only use 480GB or an 512GB drive, when doing the partitioning.

    So no. Defragmentation does not increase the read speed, but may increase the write speed while also kill the drive much quicker in the process.

    I have formatted my SSD with a 1024byte block size and simply don“t care. MorphOS will mangle the drive anyway, so the lifetime will be lower than in a Windows, Linux or Mac system.
  • »09.11.26 - 14:46
    Profile