• @treadful@lemmy.zip
    link
    fedilink
    English
    29 months ago

    Yeah, the man page doesn’t really help me out.

       fstrim is used on a mounted filesystem to discard (or "trim")
       blocks which are not in use by the filesystem. This is useful for
       solid-state drives (SSDs) and thinly-provisioned storage.
    
       By default, fstrim will discard all unused blocks in the
       filesystem. Options may be used to modify this behavior based on
       range or size, as explained below.
    
       The mountpoint argument is the pathname of the directory where
       the filesystem is mounted and is required when -A, -a, --fstab,
       or --all are unspecified.
    
       Running fstrim frequently, or even using mount -o discard, might
       negatively affect the lifetime of poor-quality SSD devices. For
       most desktop and server systems a sufficient trimming frequency
       is once a week. Note that not all devices support a queued trim,
       so each trim command incurs a performance penalty on whatever
       else might be trying to use the disk at the time.
    

    For instance, why would unused blocks not be discarded? And what does “discarded” even mean in this context? But it does recommend against using it for SSDs so I think I’ll skip it.

    • @naeap@sopuli.xyz
      link
      fedilink
      18 months ago

      “this is useful for solid-state drives”
      Where is it not recommended?

      Or did I just miss something?

      • @treadful@lemmy.zip
        link
        fedilink
        English
        28 months ago

        Running fstrim frequently, or even using mount -o discard, might negatively affect the lifetime of poor-quality SSD devices.

        I guess it was recommending against frequent runs.