TRIM für SSD einschalten auf FreeBSD 8.2 STABLE

Fusselbär

Makefile Voyeur
Hallo, freudige Überraschung als ich heute mal wieder ein bisschen herum gestöbert habe
und in der man page für tunefs auf aktuellem FreeBSD 8.2-STABLE amd64 folgendes entdeckt habe:
man tunefs said:
-t enable | disable
Turn on/off the TRIM enable flag. If enabled, and if the under-
lying device supports the BIO_DELETE command, the file system
will send a delete request to the underlying device for each
freed block. The trim enable flag is typically set when the
underlying device uses flash-memory as the device can use the
delete command to pre-zero or at least avoid copying blocks that
have been deleted.
Inzwischen wird zur Benutzung von tunefs angemerkt:
man tunefs said:
This utility should work on active file systems. To change the root file
system, the system must be rebooted after the file system is tuned.
das funktioniert aber so nicht mit dem TRIM einschalten im Multiuserbetrieb.

Aber im Single User Mode geht es:
Code:
tunefs -t enable /dev/ada0p2
Dann rebooten und gleich mal nachgeschaut:
Code:
tunefs -p ada0p2                                                                                                                                                                                                                                             
tunefs: POSIX.1e ACLs: (-a)                                disabled                                                                                                                                                                                                            
tunefs: NFSv4 ACLs: (-N)                                   disabled                                                                                                                                                                                                            
tunefs: MAC multilabel: (-l)                               disabled                                                                                                                                                                                                            
tunefs: soft updates: (-n)                                 enabled                                                                                                                                                                                                             
tunefs: gjournal: (-J)                                     disabled                                                                                                                                                                                                            
tunefs: trim: (-t)                                         enabled                                                                                                                                                                                                             
tunefs: maximum blocks per file in a cylinder group: (-e)  2048                                                                                                                                                                                                                
tunefs: average file size: (-f)                            16384                                                                                                                                                                                                               
tunefs: average number of files in a directory: (-s)       64                                                                                                                                                                                                                  
tunefs: minimum percentage of free space: (-m)             8%                                                                                                                                                                                                                  
tunefs: optimization preference: (-o)                      time                                                                                                                                                                                                                
tunefs: volume label: (-L)
Die andern Filesysteme auf dieser Kiste sind ZFS.
 
Vielleicht noch als Anmerkung: TRIM braucht wirklich 8-STABLE. Mit 8.2-RELEASE geht's nicht, auch wenn einige Quellen es nach wie vor behaupten. Nutzer der 9.0-BETAs können nach dem Einschalten von TRIM außerdem "fsck -E /dev/festplatte" machen und damit alle nicht belegten Blöcke einmal TRIMen. Auf ältere und vom TRIM abhängigen SSDs gibt's damit die alte Geschwindigkeit zurück.
 
Nein. ZFS kann es nicht und ich wüsste nicht, dass jemand daran arbeitet.
 
Back
Top