本帖最后由 Nezzdivya 于 2012-3-7 16:46 编辑
这两天瞎折腾看到一篇文章。。里面把原理说的挺详细 有兴趣可以看看
说的是 Trim Enabler的 1.1 or 1.2 对 3.0目前未知,不过据猜想应该也是劣于终端开启原生管理
各位可以自己研究下
个人还是推荐终端开启。。(据说能和ssd本身的 gc配合比较好)
文章后文也会对原理有一定的说明
有兴趣的可以看看
欢迎反馈
原文
http://digitaldj.net/2011/07/21/trim-enabler-for-lion/
DO NOT USE TRIM ENABLER (VERSION 1.1 OR 1.2) TO ENABLE TRIM ON LION. After a little inspection of this application, I found that instead of patching the file, it replaces an entire kernel extension. This means that when you use TRIM Enabler with Lion, it replaces a critical kernel extension, with lots of dependencies, with an older one (from Snow Leopard 10.6.8). This is bad. Very bad. While TRIM does become enabled, the kernel extension you now have has the potential to cause a ton of problems. That means anything from kernel panics, to disk I/O delays…and the dreaded spinning beach ball. After confronting the developer, Oskar Groth (who I refuse to link to), via his blog’s commenting system, I was told that I was simply trolling and spreading fear (even though I offered the alternative I share here). Apparently, the next version of TRIM Enabler will correctly patch the file, instead of replacing it, but that hasn’t happened yet.
另外附上终端开启方法
1. Backup the file we’re patching sudo cp /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorage /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorage.original2. Patch the file to enable TRIM support sudo perl -pi -e 's|(\x52\x6F\x74\x61\x74\x69\x6F\x6E\x61\x6C\x00{1,20})[^\x00]{9}(\x00{1,20}\x51)|$1\x00\x00\x00\x00\x00\x00\x00\x00\x00$2|sg' /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorage3. Clear the system kernel extension cache sudo kextcache -system-prelinked-kernelsudo kextcache -system-caches4. Now Reboot! a) If in the future you want to disable TRIM support sudo perl -pi -e 's|(\x52\x6F\x74\x61\x74\x69\x6F\x6E\x61\x6C\x00).{9}(\x00\x51)|$1\x41\x50\x50\x4C\x45\x20\x53\x53\x44$2|sg' /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStoragesudo kextcache -system-prelinked-kernelsudo kextcache -system-cachesb) If something goes horribly wrong, restore the backup sudo cp /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorage.original /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorageAll this patch does is simply replace the string “APPLE SSD” in the file IOAHCIBlockStorage with zeros. This happens to bypass the restriction of only allowing Apple branded SSDs. The backup of the original file is saved in the same directory as the original file. To check if it worked, open up About This Mac, click the “More Info…” button then the “System Report” button. In the list on the left, choose “Serial-ATA”. Click on your SSD Drive and in the lower half of the screen you should now see “TRIM Support: Yes” instead of “No”. Remember, if you have an older generation SSD, the hardware itself may not support TRIM …and therefore this patch won’t help you. This patch bypasses the restriction put in place by Apple to restrict TRIM support to Apple branded SSD drives. You WILL need to re-apply this patch after each major update of OS X. That means for 10.7.1, 10.7.2, etc.
文章后面的update和update2会对原理有一些描述。
大家可以参考一下
欢迎反馈
have a nice day
|