Enable TRIM
TRIM (Trim command let an OS know which SSD blocks are not being used and can be cleared)
Back up fstab first in case something wrong happen.
# cp /etc/fstab ~/fstab.bk
Edit fstab file
# nano /etc/fstab
Add discard to your ssd drives or partitions, after ext4
UUID=bef10b86-494d-41c6-aa46-af72cfba90fd / ext4 discard,errors=remount-ro 0 1
Edit fstab file
# nano /etc/fstab
Add noatime,nodiratime to your ssd drives or partitions, after ext4
UUID=bef10b86-494d-41c6-aa46-af72cfba90fd / ext4 discard,noatime,nodiratime,errors=remount-ro 0 1
Disable hibernation
# nano /usr/share/polkit-1/actions/org.freedesktop.upower.policy
Look for
<allow_active>yes</allow_active>
Change from “yes” to “no”, there are two, one for hibernation, and another one for suspend. If you have to disable them both, make sure to replace them both from yes to no.
<allow_active>no</allow_active>
Tmpfs
Edit fstab file
# nano /etc/fstab
Add the line to the end of fstab file
tmpfs /tmp tmpfs defaults,noatime,mode=1777 0 0
If logs aren’t important for you (laptop or desktop), you can also mount /var/log to
tmpfs. Add the line to the end of fstab file
tmpfs /var/log tmpfs defaults,noatime,mode=0755 0 0
From How to tweak and optimize SSD for Ubuntu, Linux Mint