You are Here:
Download Linux Lite 5.4 RC1 today - See Release Announcements



[ SOLVED ] Trim support

Author (Read 3353 times)

0 Members and 1 Guest are viewing this topic.

Trim support
« on: December 04, 2016, 08:20:30 PM »
 

carchaser

  • PayPal Supporter
  • New to Forums
  • *****
  • 5
    Posts
  • Country: us
  • Reputation: 1
  • Linux Lite Member

  • Linux Lite: 3.0 32bit

  • CPU: Intel Celeron 1300MHZ

  • MEMORY: 512mb

  • VIDEO CARD: Intel Graphics Chipset
Can some please fur ther explain this yellow box to me.  I'm fairly new to this and don't understand what I'm looking at since there is no direct command and example.  I don't understand the copy area in the yellow box and how I'm supposed to modify it.  I coped this from the help manual:

Terminal Command:
                 
sudo leafpad /etc/rc.local

Above the line exit 0 in that file, add the TRIM command fstrim -v for every EXT4 partition from your fstab file.
Copy the text below and edit it to match your set up. We include the creation of a log for you so you can check if trim is performed during boot up. The log is in /var/log/trim.log
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

LOG=/var/log/trim.log
echo *** $(date -R) *** >> $LOG
fstrim -v /boot >> $LOG
fstrim -v / >> $LOG
fstrim -v /home >> $LOG
echo " " >> $LOG

exit 0
Last Edit: December 26, 2016, 11:45:56 PM by Jerry
 


Re: Trim support
« Reply #1 on: December 04, 2016, 10:16:00 PM »
 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 7910
    Posts
  • Country: nz
  • Reputation: 744
  • Linux Lite Member
    • Linux Lite OS

  • Linux Lite: 5.2 64bit

  • CPU: Intel Xeon Dual CPU's E5645 2.4GHz 12 Cores

  • MEMORY: 16Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
Before we start, can you please open a terminal and type in the following commands:

Code: [Select]
lsblk -d -o name,rota
Code: [Select]
df -h
and report back here with the results.
 

Re: Trim support
« Reply #2 on: December 25, 2016, 05:19:03 PM »
 

carchaser

  • PayPal Supporter
  • New to Forums
  • *****
  • 5
    Posts
  • Country: us
  • Reputation: 1
  • Linux Lite Member

  • Linux Lite: 3.0 32bit

  • CPU: Intel Celeron 1300MHZ

  • MEMORY: 512mb

  • VIDEO CARD: Intel Graphics Chipset

[email protected]:~$ lsblk -d -o name,rota
NAME ROTA
sda     0
sr0     1
[email protected]:~$
[email protected]:~$ df -h
Filesystem      Size  Used Avail Use% Mounted on
udev            1.9G     0  1.9G   0% /dev
tmpfs           389M  6.5M  383M   2% /run
/dev/sda5        71G  4.7G   63G   7% /
tmpfs           1.9G  364K  1.9G   1% /dev/shm
tmpfs           5.0M  4.0K  5.0M   1% /run/lock
tmpfs           1.9G     0  1.9G   0% /sys/fs/cgroup
cgmfs           100K     0  100K   0% /run/cgmanager/fs
tmpfs           389M   44K  389M   1% /run/user/1000
[email protected]:~$




Before we start, can you please open a terminal and type in the following commands:

Code: [Select]
lsblk -d -o name,rota
Code: [Select]
df -h
and report back here with the results.
 

Re: Trim support
« Reply #3 on: December 25, 2016, 10:54:13 PM »
 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 7910
    Posts
  • Country: nz
  • Reputation: 744
  • Linux Lite Member
    • Linux Lite OS

  • Linux Lite: 5.2 64bit

  • CPU: Intel Xeon Dual CPU's E5645 2.4GHz 12 Cores

  • MEMORY: 16Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
Assuming you have got up to this point in the Help Manual, continue with the following.

Open a terminal and do:

Code: [Select]
sudo leafpad /etc/rc.local
copy the below into it overwriting the existing contents:

Code: [Select]
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

LOG=/var/log/trim.log
echo *** $(date -R) *** >> $LOG
fstrim -v / >> $LOG
echo " " >> $LOG

exit 0

then carry on with the rest of the Trim tutorial in the Help Manual.
Last Edit: December 25, 2016, 10:56:51 PM by Jerry
 

Re: Trim support
« Reply #4 on: December 26, 2016, 11:10:18 PM »
 

carchaser

  • PayPal Supporter
  • New to Forums
  • *****
  • 5
    Posts
  • Country: us
  • Reputation: 1
  • Linux Lite Member

  • Linux Lite: 3.0 32bit

  • CPU: Intel Celeron 1300MHZ

  • MEMORY: 512mb

  • VIDEO CARD: Intel Graphics Chipset
This did it!  Thank you so much for the help Jerry!  I'm loving Linux Lite 3.2!





Assuming you have got up to this point in the Help Manual, continue with the following.

Open a terminal and do:

Code: [Select]
sudo leafpad /etc/rc.local
copy the below into it overwriting the existing contents:

Code: [Select]
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

LOG=/var/log/trim.log
echo *** $(date -R) *** >> $LOG
fstrim -v / >> $LOG
echo " " >> $LOG

exit 0

then carry on with the rest of the Trim tutorial in the Help Manual.
 

Re: Trim support
« Reply #5 on: December 26, 2016, 11:46:07 PM »
 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 7910
    Posts
  • Country: nz
  • Reputation: 744
  • Linux Lite Member
    • Linux Lite OS

  • Linux Lite: 5.2 64bit

  • CPU: Intel Xeon Dual CPU's E5645 2.4GHz 12 Cores

  • MEMORY: 16Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
Cool :)
 


Tags:
 


Download Linux Lite 5.4 RC1 today - See Release Announcements