Re: [Discuss] ssd's in linux
From: discuss-bounces+blu=nedharvey@blu.org [mailto:discuss- bounces+blu=nedharvey@blu.org] On Behalf Of Kent Borg On 11/08/2013 06:15 AM, Stephen Adler wrote: I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I have been wondering the same thing, I have an empty msata slot in my Thinkpad, and little flash cards that fit in there are pretty cheap. Especially the small capacity ones: ~60GB for ~70 dollars. But flash makes me worry. In the memory stick and SD space they like to go from working to not working in an instant, with no warning nor change to recover anything. And recently a Linux kernel release was delayed when Linus' fancy SSD volume died--with no warning nor chance to recover anything. Baaah. First of all, USB sdcard are the cheap junk. Reliability in SSD's comes primarily from smart controllers, which USB sdcard don't have. If you use USB sdcard in a way similar to your laptop hard drive, you can bet the USB sdcard will die frequently. Second of all, how many hard drives have you seen fail in your life? Failures happen to everything, and I'm certain that SSD is not the first drive that ever failed in the hands of Linus. Or anyone else. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
From: discuss-bounces+blu=nedharvey@blu.org [mailto:discuss- bounces+blu=nedharvey@blu.org] On Behalf Of Jack Coats I found having 'enough ram', don't configure swap, or swap to a How many times have we had this conversation? Agreed you should never swap active memory, and therefore, you need to have enough memory in your system. And the linux kernel will use free memory for caching buffering to gain performance. But if you add some swap to your system, your kernel will swap out idle processes, whenever the idle process is less active than some working cache data. By giving your system some swap, you gain performance, because the kernel is able to keep something in cache which is more valuable than a zombie process or whatever that could be put aside to make more room for more cache. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Use a standard drive for swap and high change rate volumes. Sent from my Windows Phone From: Stephen Adlermailto:ad...@stephenadler.com Sent: 11/8/2013 6:15 AM To: Blu unix (blu)mailto:discuss@blu.org Subject: [Discuss] ssd's in linux Guys, I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life expectancy since there is a limited number of writes one can do to the NAND memory. Do I need to setup a raid array to ensure the SSD contents are correct? Thanks. Steve. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
From: discuss-bounces+blu=nedharvey@blu.org [mailto:discuss- bounces+blu=nedharvey@blu.org] On Behalf Of Stephen Adler I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life expectancy since there is a limited number of writes one can do to the NAND memory. Do I need to setup a raid array to ensure the SSD contents are correct? That is legend. ... Meaning ... something that once was true which is no longer true ... Actually it's still true, but now it's irrelevant in all but the cheapest junkiest devices. And it may not even be a problem in the cheapest junkiest devices. It's very likely that all 2.5 SSD's have intelligent controllers in them... The same is not true for USB and SDCard devices, etc. The solution to NAND lifetime was wear leveling (obviousl requires an intelligent controller). Every time you write to a block of the SSD, the SSD internally maintains a mapping table and remaps everything around physically. You think you keep writing to block 0 or whatever, and internally the SSD spreads it out across all the blocks. There was also a problem with garbage collection, which is really a non-issue anymore, thanks to intelligent controllers. Performance on day 1 will be the greatest. It will degrade over time, but it will take a fair while before you could notice or measure the difference. And even after a couple years of continuous usage, it'll still be way faster than the HDD. When you upgrade, you tend not to notice. But if you ever need to downgrade, you suddenly realize you've become a snob, because how can the rest of the schmoes in the world live with this crap.;-) ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On Fri, Nov 08, 2013 at 06:15:32AM -0500, Stephen Adler wrote: Guys, I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life expectancy since there is a limited number of writes one can do to the NAND memory. Do I need to setup a raid array to ensure the SSD contents are correct? Here's the method I'm considering using on my house desktop -- not a server. 1 SSD and a pair of mirrored HDs. The SSD will have /boot and two partitions for caching with flashcache. The RAID will have a second /boot, /, /home, and swap. / and /home will be cached on the SSD. Every so often I will copy /boot over from the SSD to the RAID. The SSD acts as a giant, nonvolatile cache for the RAID; I expect to normally have my entire working set available through it. Meanwhile, I generally get the storage capacity and reliability of the RAID mirror. I've run an experiment along these lines and it seems promising. -dsr- ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/08/2013 06:15 AM, Stephen Adler wrote: I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life I've been using a SSD for operating system and a HDD for /home for about a year on a desktop computer. Running latest linux distribution and didn't run into any issues (yet). The speed improvements are amazing. I make regular backups of /home , reinstalling the o.s. is not a big deal if the SSD fails for any reason. I mount my / with ext4relatime,discard,errors=remount-ro hdparm reports it as: Model=M4-CT128M4SSD2 regards, Nuno - -- http://aeminium.org/nuno/ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAEBAgAGBQJSfN5BAAoJEPIY6fuKMkz5pYsP/09IRPF4ZciAbmc/0sOwUzSi 2wpCOSwx1OwYLrliHn5azZbHvrKr+yJAAXpzsCaPdriEm11x+JrS+DR3A8j6zz0O GENJNYFyLabM+qjqf3JFELwi0Zcxysetem+3zW5At1zefJPk8aTdOcGGMDexehsr BBEICHIjmnmSXUpra0acElDwPk6WOvaFgZSxbmGJk/qnojmURXX4Oce5sBoxn8Sw gXq5gV/jo6a3Buxqli9oHKFvPrbw5yKXw5XKJHrNSfH5aqYEn5Ni1LSf4eg9JnsJ TBoA0Ob2a9Yvn+DjGwKzKXXfW3H5Ap99aQsCdX0H/vG35TtWBYqo9mY+MJ+7fckt Adopz3mZHjte/Fl0YTmLEgydOFt4ri/ZvA3eH5WJOj8BeewHZwOTD2+a3sVkIX3C cycLJbv0c56U7YvhP1RERUTVm2k6YbEQgexwBN9vrdsHWg7/dmgC53s/yBkIw2hO vB24Sbo4/PS+AujBla67xWlsIgtF5CWM5rEEMLyPwdBlISKSxAL0SI5YtzzrcM4y uh51hv2IzqI4VFkHr7J/ZLdU21f5l45IkLzRrE/CcyfvQLN7acT5gP7uBPqQ/brA 6vvSgpH9WGvxO8fe5+SSLsswdj2+pw7wtWzHqJWGh2S65MllMyPJhaRbsLAPtggs 9vl43wYajWHw01pM+py6 =z1Yt -END PGP SIGNATURE- ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/08/2013 07:51 AM, Nuno Sucena Almeida wrote: a year on a desktop computer. Running latest linux distribution and didn't run into any issues (yet). The speed improvements are amazing. I forgot to mention. I don't have any disk swap. - -- http://aeminium.org/nuno/ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAEBAgAGBQJSfN8LAAoJEPIY6fuKMkz5j1gQAJPyFw7A2m91h/Jiz1yq7b+M Q+xhh+3QjbT6BlrEgfte//vqzxHLMO2XUB2osLyJ0xE6EJ4ytw/wjptGIVHXv9/i CNGsc/IhBnfqetpaRi5aanuZGMlAz4/x1c7QgqQN8/QZ1ZHKBADuOWqC2DoUvFxj BxBzXwUiRsjL+O0vIk/rYU5MYqpDO6UKO3uYka0IojlxXprtBDsZZwtJHRUQ/zgT 79nEc4wsSkFD/ymUy3UDWh1xNBZez6GQePFDY4461s7yFxJEC4WzLAOtBBPGt62R PgcjASgQ3RpSXp7rPITmBLMWJn4RoscGUv/ZlPis7gTxRMTqOL0jOi4KnU193SGO g+kbIwxaGlkuX4vx9Ui5skChUBlGdX46kkeX00B27oHEjqh8JBKjO0n69hNB/3/K YY5Z/fEpj2BR6rmERvDok73hA8n1vfvB2j/zcCgRXUZaUTij0Ye3ZyE0WulgJNEA SDuCv4tLSeEbE4lcqwl49RkBoLbZxeL8E3HbATsgNk7WJEyvlzS86HxPno5kAFqh MPZAmHaxYWUh6M2iLx3vR1BqOdVRcfqreX/9NgpDMU8KDCe95kjvJKGTFPLfkobk wF21MExYf/KD/kgFhY4NaGUcb08/O3GLPqkxkG5dZpA7jEt1fUgPgtM3yg60wPnz YxvPIs/kw17nC6kL1QxG =q7lK -END PGP SIGNATURE- ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On Fri, Nov 08, 2013 at 06:15:32AM -0500, Stephen Adler wrote: I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life expectancy since there is a limited number of writes one can do to the NAND memory. Do I need to setup a raid array to ensure the SSD contents are correct? After trying out various methods of combining a SSD with a spinning HDD (write-behind RAID etc.) I've settled on keeping the two drives separate for performance reasons, and then using Lsyncd to synchronize files between them in almost-realtime as an online backup. Lsyncd uses the inotify Linux kernel feature to determine what files/dirs have changed in real time, and then it spawns rsync to do the actual copies. I partitioned the SSD and HDD identically, except for some extra space on the SSD where I put a swap partition (yes I'm swapping to SSD but I don't dip into swap much). I also made sure to install the bootloader on the HDD as well so I can boot from the HDD if the SSD dies. Not quite as resilient as RAID, but good enough for a desktop. Just be sure to align your partitions (and any other block layers such as LVM, LUKS, filesystems, etc.) to 2MiB boundaries for best SSD performance and wear. This should be the default for all modern tools/distros these days. You may also want to enable TRIM on the SSD, although recent research brings into question the value of TRIM and whether it actually hurts performance rather than helping it. I'm just not going to be paranoid about wearing out the SSD, especially since I have lsync there to keep my backups. With the whole system on SSD performance is outstanding. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On 11/08/2013 06:15 AM, Stephen Adler wrote: I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I have been wondering the same thing, I have an empty msata slot in my Thinkpad, and little flash cards that fit in there are pretty cheap. Especially the small capacity ones: ~60GB for ~70 dollars. But flash makes me worry. In the memory stick and SD space they like to go from working to not working in an instant, with no warning nor change to recover anything. And recently a Linux kernel release was delayed when Linus' fancy SSD volume died--with no warning nor chance to recover anything. What I have been considering is using an SSD as a cache, and in the 3.10 kernel there is support for this (Bcache). Given Linus' recent experience, I bet it is pretty solid about not leaving data exposed on SSD only for too long. Googling about a bit it seems a different dm-cache feature showed up a little before that. How big is my disk working set? I bet 60GB would cover it pretty well. Bcache only caches random disk access (configurable), which makes sense, disks can sustain sequential just fine, which makes 60GB even bigger. It seems Bcache came from Google, where they stack this on top of raid arrays. I use Ubuntu (though I am getting annoyed by it and might switch to something else), the recent release is on kernel 3.11, and next April's long-term support release presumably would be at least as new a kernel, so doing it then might make sense. I run my disk encrypted, so whatever I might do needs to stack with that, too. -kb ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
I found having 'enough ram', don't configure swap, or swap to a non-ssd device, and set the 'no access time' flag for any file systems in the device and it will make your machine scream. Also, it can prolong life if you remove all 'time' variables, other than 'create time' on your file systems. Consider turning off 'all' logging. Oh, for me 'enough ram' is either all the machine can hold or all I can afford, and as fast as the machine will usefully handle (no reason to put 2ns ram if 50ns is all the hardware will handle, etc). If you run Linux, it uses 'extra ram' for caching by default. Possibly changing that ratio can help by allowing it to keep more programs in memory and less 'pre-emptive' file system caching. I forgot the switches for this, but they can be found without to much problem. Most of the other warnings about 'don't install what you don't need' and 'remove unused components' still make sense to keep a screaming beast's volume tuned up and loud. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On Fri, 8 Nov 2013, Chuck Anderson wrote: On Fri, Nov 08, 2013 at 06:15:32AM -0500, Stephen Adler wrote: I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life expectancy since there is a limited number of writes one can do to the NAND memory. Do I need to setup a raid array to ensure the SSD contents are correct? After trying out various methods of combining a SSD with a spinning HDD (write-behind RAID etc.) I've settled on keeping the two drives separate for performance reasons, and then using Lsyncd to synchronize files between them in almost-realtime as an online backup. Lsyncd uses the inotify Linux kernel feature to determine what files/dirs have changed in real time, and then it spawns rsync to do the actual copies. I partitioned the SSD and HDD identically, except for some extra space on the SSD where I put a swap partition (yes I'm swapping to SSD but I don't dip into swap much). I also made sure to install the bootloader on the HDD as well so I can boot from the HDD if the SSD dies. Not quite as resilient as RAID, but good enough for a desktop. Just be sure to align your partitions (and any other block layers such as LVM, LUKS, filesystems, etc.) to 2MiB boundaries for best SSD performance and wear. This should be the default for all modern tools/distros these days. You may also want to enable TRIM on the SSD, although recent research brings into question the value of TRIM and whether it actually hurts performance rather than helping it. I'm just not going to be paranoid about wearing out the SSD, especially since I have lsync there to keep my backups. With the whole system on SSD performance is outstanding. Do we know the form of SSD failures? That is, if the failures are of the form of unsignaled write failures, then your lsyncd will copy the bad bits to backup, defeating your purpose. Only if the failures are bits rot sometime after being correctly written, will your backup be helpful. I have looked, but never found, information on this point. dan feenberg feenb...@nber.org ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On 11/08/2013 09:08 AM, Daniel Feenberg wrote: Do we know the form of SSD failures? My impression and experience is they go from working to brick. -kb ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Nathan Burridge wrote: Use a standard drive for swap and high change rate volumes. So conventional wisdom says. Conventional wisdom is wrong on this. The entire point of using flash-based SSDs is performance, specifically fast random read performance. For performance, it is best to put your swap on SSD and use an eager swap policy. That way when physical memory is allocated it is mirrored to swap at allocation time. This minimizes writes to swap (flash writes are slow) while maximizing read performance from swap (flash reads are very fast). This is one of the best ways to use SSDs. Flash-based media is consumable. It's a matter of how long it takes before it runs out of usable cells. Six months, a year, two years, maybe five for the enterprise-grade models. Buying into SSD means accepting the fact that you will replace it in the foreseeable future. Given that? Pushing a SSD as hard as possible is the best value for your money. -- Rich P. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Stephen Adler ad...@stephenadler.com writes: Guys, I'm thinking of upgrading my linux system by adding an SSD drive to use as my system disk. Has anyone done this? Any pros and cons regarings using SSD's? I'm more intrested in the cons. I'm worried about the life expectancy since there is a limited number of writes one can do to the NAND memory. Do I need to setup a raid array to ensure the SSD contents are correct? Others have discussed performance and longevity issues but what do people think of SSDs and what wikipedia calls data remanence (your data remaining visible on the drive despite your (modest and not involving sledge hammers or demagnetization) efforts)? Their article makes it sound like hard drives fair better here: https://en.wikipedia.org/wiki/Data_remanence#Data_on_solid-state_drives -- Mike Small sma...@panix.com ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On 11/08/2013 02:47 PM, Mike Small wrote: Others have discussed performance and longevity issues but what do people think of SSDs and what wikipedia calls data remanence (your data remaining visible on the drive despite your (modest and not involving sledge hammers or demagnetization) efforts)? Part of why I run full disk encryption is to not worry about that. Don't destroy the disk, just destroy the encryption key. If I did Bcache with an SSD, maybe I could stack it under the encryption. I think the sequential vs. random access patterns are still visible at that level. Heck, Bcache stands for block layer cache. That stacking would work. -kb ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Kent Borg wrote: Part of why I run full disk encryption is to not worry about that. Don't destroy the disk, just destroy the encryption key. There are reasons why this does not pass muster at the DoD. Me? I use an industrial drill press. Technically, /I/ don't use an industrial drill press; I have a machinist do it. For SSDs? Belt sander. -- Rich P. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On 11/08/2013 04:00 PM, Richard Pieri wrote: Kent Borg wrote: Part of why I run full disk encryption is to not worry about that. Don't destroy the disk, just destroy the encryption key. There are reasons why this does not pass muster at the DoD. Me? I use an industrial drill press. I don't think that passes DoD requirements either. But I don't need to make the DoD happy, I just need to destroy the encryption key. -kb ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Kent Borg wrote: I don't think that passes DoD requirements either. The drill press? It certainly does for non-classified media. Classified media requires a thorough degaussing optionally followed by physical destruction. Incineration is also an option for classified media. Incineration is also acceptable for flash media. Repeat statement about how flash-based media are consumables. But I don't need to make the DoD happy, I just need to destroy the encryption key. And all I -- for some value of I which may not be myself -- have to do is find a way to recover that key which, depending on [insert everything about potential weaknesses in algorithms and schedulers and not-really-random number generators here] may not be that difficult. Depends on your threat model. Or you could use RAM-based SSDs instead of flash. Almost instant sanitizing when power is removed. -- Rich P. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On Fri, Nov 8, 2013 at 4:34 PM, Richard Pieri richard.pi...@gmail.com wrote: Kent Borg wrote: I don't think that passes DoD requirements either. Or you could use RAM-based SSDs instead of flash. Almost instant sanitizing when power is removed. Where almost instant means up to ten minutes if the RAM has been pre-chilled. Lest We Remember: Cold Boot Attacks on Encryption Keys https://citp.princeton.edu/research/memory/ So you need to both cut the power and prevent physical access for a few minutes. Bill Bogstad ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Bill Bogstad wrote: So you need to both cut the power and prevent physical access for a few minutes. If an attacker has physical access to the live system then cold boot attacks are among the least of your worries. -- Rich P. ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
On Fri, 8 Nov 2013, Bill Bogstad wrote: On Fri, Nov 8, 2013 at 4:34 PM, Richard Pieri richard.pi...@gmail.com wrote: Kent Borg wrote: I don't think that passes DoD requirements either. Or you could use RAM-based SSDs instead of flash. Almost instant sanitizing when power is removed. Where almost instant means up to ten minutes if the RAM has been pre-chilled. Yes, but how exactly will the intruder get to pre-chill your RAM before you turn off the machine? And why would he bother? If he has physical access to your machine while it is still turned on, why would he wait for you to turn it off? Am I missing a common threat? Daniel Feenberg ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss
Re: [Discuss] ssd's in linux
Sounds like an episode of Nikita ... chilling RAM so it has different characteristics or uses almost no power while it is moved to another device. OK, where is that rock I came out from under? ... On Fri, Nov 8, 2013 at 7:03 PM, Daniel Feenberg feenb...@nber.org wrote: On Fri, 8 Nov 2013, Bill Bogstad wrote: On Fri, Nov 8, 2013 at 4:34 PM, Richard Pieri richard.pi...@gmail.com wrote: Kent Borg wrote: I don't think that passes DoD requirements either. Or you could use RAM-based SSDs instead of flash. Almost instant sanitizing when power is removed. Where almost instant means up to ten minutes if the RAM has been pre-chilled. Yes, but how exactly will the intruder get to pre-chill your RAM before you turn off the machine? And why would he bother? If he has physical access to your machine while it is still turned on, why would he wait for you to turn it off? Am I missing a common threat? Daniel Feenberg ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss -- ... Jack On today's episode of 'This Ol Geek'... Texas is the finest portion of the globe that has ever blessed my vision. - Sam Houston Whatever you do, work at it with all your heart... Colossians 3:23 If you are not part of the solution, you are part of the precipitate - Henry J. Tillman Anyone who has never made a mistake, has never tried anything new. - Albert Einstein You don't manage people; you manage things. You lead people. - Admiral Grace Hopper, USN Life is complex: it has a real part and an imaginary part. - Martin Terma ___ Discuss mailing list Discuss@blu.org http://lists.blu.org/mailman/listinfo/discuss