Page 11 of 12 FirstFirst ... 9101112 LastLast
Results 101 to 110 of 118

Thread: How to optimize 10.04 Lucid Lynx for SSD

  1. #101
    Join Date
    Jul 2010
    Beans
    31
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Where do I add the noatime and discard option? The example fstab files are different than mine. This is how mine looks like.

    Code:
    # /etc/fstab: static file system information.
    #
    # Use 'blkid -o value -s UUID' to print the universally unique identifier
    # for a device; this may be used with UUID= as a more robust way to name
    # devices that works even if disks are added and removed. See fstab(5).
    #
    # <file system> <mount point>   <type>  <options>       <dump>  <pass>
    proc            /proc           proc    nodev,noexec,nosuid 0       0
    # / was on /dev/sda1 during installation
    UUID=e404377d-1d35-41d1-bcfd-760371b8247a /               ext4    errors=remount-ro 0       1
    
    # mounting tmpfs
    tmpfs /tmp tmpfs defaults,noatime,mode=1777 0 0

  2. #102
    Join Date
    Mar 2008
    Beans
    21

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Quote Originally Posted by Elysius View Post
    Where do I add the noatime and discard option? The example fstab files are different than mine. This is how mine looks like.

    Code:
    # /etc/fstab: static file system information.
    #
    # Use 'blkid -o value -s UUID' to print the universally unique identifier
    # for a device; this may be used with UUID= as a more robust way to name
    # devices that works even if disks are added and removed. See fstab(5).
    #
    # <file system> <mount point>   <type>  <options>       <dump>  <pass>
    proc            /proc           proc    nodev,noexec,nosuid 0       0
    # / was on /dev/sda1 during installation
    UUID=e404377d-1d35-41d1-bcfd-760371b8247a /               ext4    errors=remount-ro 0       1
    
    # mounting tmpfs
    tmpfs /tmp tmpfs defaults,noatime,mode=1777 0 0
    Replace errors=remount-ro with errors=remount-ro,noatime,discard

  3. #103
    Join Date
    Jun 2010
    Location
    Netherlands
    Beans
    14
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Did I understand correctly that TRIM is only supported on ext4?

    I decided to install my system on Ext2, because Ext3 and Ext4 have journalling which would imply additional write cycles. In fact, according to http://en.wikipedia.org/wiki/Ext2 Ext2 is the filesystem of choice for SSD, SD and Flash USB.

    Did I just upgrade my kernel for no good reason?

  4. #104
    Join Date
    Jan 2007
    Beans
    6,542
    Distro
    Ubuntu 13.04 Raring Ringtail

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Quote Originally Posted by Bakmeel View Post
    In fact, according to http://en.wikipedia.org/wiki/Ext2 Ext2 is the filesystem of choice for SSD, SD and Flash USB.
    SD and Flash definitely, and probably early/cheap SSDs too. For a recent SSD with decent wear levelling then write cycles isn't really worth worrying about IMO. I'd rather have the significant extra performance of Ext4 than a small improvement in lifespan.

  5. #105
    Join Date
    Apr 2007
    Location
    Ottawa, Canada
    Beans
    740
    Distro
    Kubuntu Development Release

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Quote Originally Posted by Bakmeel View Post
    Did I understand correctly that TRIM is only supported on ext4?
    Yes

    Quote Originally Posted by Bakmeel View Post
    I decided to install my system on Ext2, because Ext3 and Ext4 have journalling which would imply additional write cycles.
    You can create an ext4 filesystem without a journal, I don't know how though.


    Quote Originally Posted by Bakmeel View Post
    Did I just upgrade my kernel for no good reason?
    Yeah
    This is not a signature.

  6. #106
    Join Date
    Jun 2010
    Location
    Netherlands
    Beans
    14
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Quote Originally Posted by Jordanwb View Post
    Yeah
    Bugger.

  7. #107
    Join Date
    Jun 2006
    Beans
    70

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Just thought I would add a little workaround that was frustrating me no end. I'd also seen a couple of posts that mentioned similar symptoms.

    The disclaimer
    * As always, YMMV
    * Don't mess with partition tables without having backups!!

    The problem
    I had been trying to set up the SSD with -H 32 -S 32 using fdisk, as mentioned in several guides/threads to align partitions. What happened is that setting did not 'stick'. It constantly reverted back to 255 heads and 63 sectors/track. This happened when I used the Ubuntu 10.04 live CD, or when I was using sysrescuecd 1.5.8.

    I was setting up four primary partitions.

    The investigation
    After messing around a little bit, it turned out that it was only when adding the 4th primary partition that it reverted to 255/63. After a little experimenting, it turned out that it only reverted back to 255/63 when you used up nearly all the disk. Eg, setting the 4th partition to the end of the disk caused it to revert. My last sector is now set ~68K sectors from the end of the disk; and the 32/32 holds. Note that your disk may be different, Just set the last sector on the last partition to be 1 sector less than a multiple of 2048 so as to align with the erase block size. Save the change and try listing from the terminal using fdisk -ucl. It should still show "32 heads, 32 sectors/track". If it doesn't try again with the partition a little smaller. When it does 'stick' reboot and check it again.

    I didn't spend any time on 'minimising; 68K sectors is only ~39KB. Don't even really understand what caused it. Maybe it's a bug in fdisk. Maybe it's my machine. Don't really care as it seems I have worked around it.

    The summary
    When the 4th (or last) partition was set somewhat before the end of the disk, the 32 heads and 32 sectors setting is permanent. When it went to the last sector, this caused the heads to be reset to 255 and the sectors/track to be 63.

    hth
    ws

    PS: You may also 'lose' your setting of 32 heads and 32 sectors/track if you dual boot and run certain of the 'repair' options in windows. That is probably a topic for another day...
    Last edited by wiresquire; July 14th, 2010 at 11:07 AM.

  8. #108
    Join Date
    Jun 2010
    Location
    Netherlands
    Beans
    14
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Quote Originally Posted by libssd View Post
    Mount /tmp /var/log and /var/tmp in RAM. Add these lines to the end of fstab to mount /tmp (temporary files) as tmpfs (temporary file system):

    Code:
       tmpfs /tmp tmpfs noexec,defaults,noatime 0 0
       tmpfs /var/tmp tmpfs noexec,defaults,noatime 0 0
    Save, then: sudo mount -a

    Reboot for the changes to take effect. Running df, you should see a new line with /tmp and /var/tmp mounted on tmpfs.
    I have succeeded in getting the temp files to RAM and I am considering to put the logfiles there too. However, I am aware that when I reboot these files are lost and that is not desirable.

    I have made a crontab to back up the logfiles every day at midnight:

    Code:
    sudo crontab -l -u root
    
    # m h  dom mon dow   command
      0 0   *   *   *    cp -r /var/log/* /var/log_local/
    But that doesn't solve the issue of restoring some of the logfiles when I reboot the system, and some services like apache won't come back online.

    Has anyone tried to restore the logfiles to the ramdisk at reboot using:

    Code:
    # m h  dom mon dow   command
    @reboot cp -r /var/log_local/* /var/log/
    Any alternatives to restore the logs at reboot?

  9. #109
    Join Date
    Jun 2010
    Location
    Netherlands
    Beans
    14
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How to optimize 10.04 Lucid Lynx for SSD

    Apparently nobody has tried it, so I did

    And it works!
    Now, each night the logfiles will be copied from the memory to the SSD.
    Upon reboot, the logfiles are restored and all services resume operation as normal.

    Now I just need a small script to make an additional backup when I shut down

  10. #110
    Join Date
    Jul 2008
    Location
    United States
    Beans
    43
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: How to optimize 10.04 Lucid Lynx for SSD

    I will be receiving my new Intel X25M G2 80GB SSD in a couple of days. It supposedly already has the latest firmware installed.

    A comprehensive guide for Lucid installation and tweaks would be awesome -- either here or in another section of the Forum. If this has already been done, could someone advise me where in the Forum it is located? I've just read this entire thread and have come away somewhat confused.

    Should I just wait for Meerkat? (Newer kernel, perhaps better support for SSDs overall)?

    I have just enough Linux knowledge to be dangerous, not enough to be truly competent -- so a detailed instructional guide would be something many of us would love to have in order to extend the life and increase the performance of our SSDs. I realize there will always be conflicting opinions about settings (tweaks) but I would think that by now some experience would shed some light on what works and what doesn't.

    Thanks!
    Acer TimelineX 3820T-7459 // Ubuntu 10.10 (AMD64)

Page 11 of 12 FirstFirst ... 9101112 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •