Ubuntu QA:
BlogBrainstormPackage status
Log in
Ubuntu QA
The Ubuntu community has contributed 21986 ideas, 135057 comments, 2615221 votes
Idea sandbox Idea sandbox
Popular ideas Popular ideas
Ideas in development Ideas in development
Implemented ideas Implemented ideas
Idea #17652: Optimization on ubuntu for SSD drives with EXT4

Written by ubuntosaure the 25 Jan 09 at 11:37. Related project: Live CD installer. Status: New
Rationale
I think that ubuntu should recognize the SSD hard drive to optimize its life and speed. In the near future EXT4 will be implemented on ubuntu and it would be nice to have a optimized filesystem for SSD drivers so that the new implementation of microsoft exFAT is beaten, or other new filesystems.
http://en.wikipedia.org/wiki/ExFAT
Tags: EXT4 SSD

483
votes
up equal down
Solution #1: EXT4 SSD profile
Written by ubuntosaure the 25 Jan 09 at 11:37.
With the coming of the new filesystem EXT4, create a mode which optimizes the performance on SSD drives.
40
votes
up equal down
Solution #2: Optimise for speed but not lifespan - short SSD write lifespan is a myth.
Written by r0g the 27 Jan 09 at 05:43.
I don't know if there would be any design trade-offs between speed and lifespan in such a profile but SSD's short write lifespan issues are a bit of a myth so if a call needs to be made between them we should go for speed!

See this site for why it's only a problem on the smallest of devices...

http://www.storagesearch.com/ssdmyths-endurance.html
33
votes
up equal down
Solution #4: Little package ssd-mode
Written by TuxHHG the 19 Apr 09 at 09:53.
Like laptop-mode there can be a package that change all ssd related points in one way.
1
votes
up equal down
Solution #5: SSD mode in Ubiquity
Written by HacKurx the 2 Jul 10 at 07:06.
Why not make the SSD option in the installer for all file systems.
It is easy to create it, simply activate SSD mode in ext4 and btrfs and write "noatime" into /etc/fstab.

Here's how it could look like:

Hebergement d'images
3
votes
up equal down
Solution #6: Suggest adequate filesystems
Written by caliga82 the 31 Aug 10 at 21:48.
(This may be just an addition/clarification to solution #1)

If a SSD is detected, the installer should inform the user how suitable a certain filesystem system is. In particular, if it supports the TRIM command.
Depending on the user's experience, there could be just an indicator (green, thumbs up...) or a complete explanation of the benefits of a filesystem with TRIM.

Propose your solution

Attachments
No attachments.


Duplicates


Comments
on5sl (Idea reviewer) wrote on the 25 Jan 09 at 13:22
exFAT from Microsoft is optimized for portable flash drives, and misses features like file permissions and so on...
So exFAT wo'nt be a EXT4 killer, but still we should be aware for other filesystems from Microsoft who could beat the great performance of EXT4.

on5sl (Idea reviewer) wrote on the 25 Jan 09 at 14:10
@AndrewLuecke

ow, i thought is didn't support it...Well then, whats is a good solution then? Create a new filesystm only for SSD?

ubuntosaure wrote on the 25 Jan 09 at 15:10
People who have a hard disk ssd uses ext2 because there is not Journal file system.
ext3 decreases life of a hard disk ssd.

on5sl (Idea reviewer) wrote on the 26 Jan 09 at 10:57
@AndrewLuecke

Well then, maybe it's a good idea then to use the LogFS in the future when is completely stable? I think developing another filesystem will be difficult cause of time and developers?

r0g wrote on the 28 Jan 09 at 00:19
@AndrewLuecke -

What the hell has wear-levelling got to do with anything?

AFAIK you can't even buy an SSD that doesn't do automatic wear-levelling in hardware. Rewriting the same logical sector will not rewrite the same hardware sector, this is NOT a software issue.

Also modern SSDs have so much write endurance it would take you years, if not decades of pounding it at FULL SPEED to deliberately wear it out. Bad write endurance is a myth as I point out in my solution above, read the article I mention in it if you doubt me.

mikaelstaldal wrote on the 30 Jan 09 at 10:28
The most important thing for SSDs is to avoid unnecessary writes. This can not be fixed by the filesystem alone, you also have to configure the whole system in a proper way (such as mounting /tmp as tmpfs) and use clever applications (which does not fsync too often like Firefox).

emil.s wrote on the 30 Jan 09 at 20:36
It seems as Btrfs will have an SSD-mode:
http://en.wikipedia.org/wiki/Btrfs#Features
And since Btrfs is designed to be a "replace everything" FS, i suggest we wait for it to be stable.

r0g wrote on the 31 Jan 09 at 03:50
@Andrew...

"Assuming we can write to a single 1kb sector continuously at 80MB, that means 25SECONDS!!! This assumes a good controller..."

You can't though, that's what hardware wear leveling does - it abstracts the drives ABI sectors from the actual hardware 'sectors'. You can repeatedly tell it to overwrite the same sector and it will tell you it has but underneath all that it has just overwritten the least worn block of flash it can find and has remapped the 'sector' you see to point at that instead.

Disk-controller schmisk-controller - wear leveling is not a software issue with modern SSDs. Writing less data overall will maybe extend the life of your SSD from a very long time to a very VERY long time at the cost of extra driver logic and cycles but you gain nothing from futzing with "where" the data is 'physically' written - there is no physical "where" with SSD.

ubuntosaure wrote on the 12 Feb 09 at 10:54
My fstab:

/dev/sda2 / ext3 defaults,noatime 0 0
proc /proc proc defaults 0 0
tmpfs /tmp tmpfs defaults 0 0
tmpfs /var/tmp tmpfs defaults 0 0
tmpfs /var/log tmpfs defaults 0 0
/dev/mmcblk0p2 swap swap defaults 0 0

ubuntosaure wrote on the 6 Mar 09 at 19:05
Look please:
http://www.ubuntu-eee.com/wiki/index.php5?title=How_to:_Reduce_Disk_Writes_to_P rolong_the_Life_of_your_Flash_Drive#M

mikaelstaldal wrote on the 9 Mar 09 at 09:10
Or look here for a more radical approach:

http://www.staldal.nu/tech/2008/07/26/linux-with-mounted-read-only/

walkeer wrote on the 9 May 09 at 12:02
Hust a few notes:
1) fragmentation actually IS problem even on SSD, because sequentional read is much higher than random read on SSD, not as much as on classic HDD bud it is still a major difference.
2)internal wear levelling every modern SSD (CF,SD,SSD) have causes internal fragmentation, invisible to OS or controller, which causes huge performance problems, because then writing in sequent causes basicly random write, which is far most the slowest operation SSD do. There is no simple solution for this yet, except whole disk full erase from time to time. for more on this google "ssd internal fragmentation".
3)ssd internal fragmentation can be kind of avoided by writing only larger amounts of data and completly avoiding writing small amounts, such as journal or database. For SSD I would recomend using Ext4 without journal, users reports huge read and write benefit from ext2. Noop scheduler also helps alot.

TuxHHG wrote on the 14 Jan 10 at 16:45
Anyway using ext4 with logging on desktop, thinkpad (m-tron mobi) and on my eee. Nothing could be uglier than minutes of full fsck, i remember 30min on a 2gb desktop after power loss. Atomic commit is a must.

Using this fstab here:

UUID=shortened / ext4 noatime,barrier =0,nobh,commit=100,errors=remount-ro 0 1

I vote for a bunch of changes that disable things that mostly are not neccesary. Who really needs a full span of logfiles with rotate on a netbook?

TuxHHG wrote on the 7 Feb 10 at 16:55
Found something here, tytso assumes some ssd tweaks but normally you have the system 'wrong' installed if you read them.

http://thunk.org/tytso/blog/2009/02/20/aligning-filesystems-to-an-ssds-erase-bl ock-size/

So we need a ssd-tweak mode that runs from setup cd if there is a ssd installed. It can be tuned from a to z before installation.


Post your comment