I recently bought a new laptop with a 16Gb mSATA SSD cache drive. I haven't used that one yet.

I have, however, opted for Ubuntu 13.04 with "Full Disk Encryption" for the main partition (is that what's called LUKS?).

With bcache making it's way into 3.10, I'd like to take advantage of the aforementioned cache drive.

According to this, one has to format one's backing and cache drives in order to take advantage of bcache.

My questions are:

  1. Which order do I proceed in? Set up bcache, then (re)setup LUKS or the other way around?
  2. Except for the few files pertaining to the encrypted setup (incl. /etc/fstab), can I tar/rsync/whatever the rest of the existing fs to another disk, set up bcache and LUKS and then tar/rsync/whatever back and expect things to work?
  3. Are there other things I should know about?
share|improve this question
    
If you get this going, I'm interested in a benchmark. My guess is that it won't help you any. If LUKS is your bottleneck, caching does next to nothing (not without making the encryption useless). If the disk is the bottleneck, on a desktop/laptop you're most likely better off putting the system and /home onto the SSD directly and leave the disk for the big and slow things. Also has the advantage that you can send the disk to sleep entirely while not in use, whereas a cache will always use the disk. – frostschutz May 24 '13 at 18:04
    
Thank you for the suggestions! As stated, the SSD is only 16Gb, so I don't really think putting / and /home on there is a viable option. Mostly, I just wanted to see if anything good would come of it, but I guess both / and the SSD partition will need to be encrypted, so I hope LUKS won't turn out to be that much of a bottleneck (I seem to remember reading that 3.10 contains some speedups in this regard as well). I shall experiment when I get the time, and do some benchmarks before and after as well when I do. – molgaard Jun 24 '13 at 7:46

I've put a quick intro to bcache conversion on AskUbuntu. You can use lsblk to figure out which stacked device to convert, which should be the partition that contains LUKS data.

share|improve this answer
    
This procedure doesn't work any more on Ubuntu 15.04; see askubuntu.com/questions/252140/… – Jean Jordaan Jul 3 '15 at 18:06

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.