1/3/2024 0 Comments Does trim enabler really workAutomatic TRIM (Deprecated, Slow)Īutomatic TRIM has been supported since Ubuntu 10.10 (kernel 2.6.33) with the EXT4 file system. If you see no errors, your cron job should be working fine. Make the script executable: sudo chmod +x /etc/cron.weekly/fstrimĪnd finally test it: sudo /etc/cron.weekly/fstrim If you have more mount points that reside on one or more SSDs, add them to SSD_MOUNT_POINTS as explained in the code. Note that the above assumes that only your root filesystem / is located on an SSD. # SSD_MOUNT_POINTS='/ /boot /home /media/my_other_ssd' # Make sure all mount points are within the quotes. # You can add more SSD mount points, separated by spaces. # By default we assume only / is on an SSD. Paste the following code in the file, then save and close the file: #! /bin/sh Here's how to activate it manually in older versions of ubuntu (11.10 to 13.10):Ĭreate a weekly CRON job script file: gksudo gedit /etc/cron.weekly/fstrim This is the currently recomended method, and is planed to be activated per default for Ubuntu 14.04. Note: For Ubuntu 11.04 and earlier systems, fstrim is not available so you have to use wiper.sh supplied with hdparm in /usr/share/doc/hdparm/contrib/wiper.sh.gz Scheduled TRIM (Recommended) However it is not needed when scheduled or automatic TRIM are enabled, as detailed in the sections below. In Ubuntu this can be performed with fstrim: sudo fstrim / There are three ways to perform TRIM, manual, scheduled, and automatic: Manual TRIM (or just edit the file /etc/cron.weekly/fstrim and add -no-model-check) Ubuntu 13.10 and Earlier If you have another brand, you could disable the vendor check by running the following command: sed -i 's/exec fstrim-all/exec fstrim-all -no-model-check/g' /etc/cron.weekly/fstrim Since 15.04 Ubuntu uses systemd and its timer ( man systemd.timer, Arch wiki) systemctl list-timersĪs of Ubuntu 14.04, scheduled TRIM is enabled by default for Intel, SAMSUNG, OCZ, Patriot and Sandisk SSDs. In Ubuntu 14.10 and 15.04, TRIMming happens automatically every week on all SSDs supported by fstrim.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |