My Linux server spends a lot of time computing LUKS encryption. Is there any way to hardware accelerate it (with a PCI express card for example)?
Beginning with Kernel 2.6.32 the AES-NI instructions on newer Intel processors are supported by dm-crypt. You might want to check /proc/cpuinfo if your processor supports these instructions. Otherwise, upgrading your processor will speed up your harddisk encryption (provided you are actually using AES encryption)
AESNI is hardware acceleration for AES encryption. As long as your LUKS/dmcrypt is setup to use AES, which it most likely is, and so long that your processor supports it, you can add the AESNI kernel module manually or automatically.
Manual (test to make sure it works/is supported)
sudo modprobe aesni-intel
sudo vim /etc/initramfs-tools/modules
- Add aesni_intel
sudo update-initramfs -u
You want to add it to your initramfs, and not just your normal kernel because you want it to be available before you decrypt your drive and load your main kernel.
To my knowledge, there are no such add-on cards for dm-crypt/luks encrypion. DM doesn't support them.
That said, it does look like there is a move afoot to get GPU-acceleration into the processing pipeline if it is available. As servers still rarely have GPUs in them (though that's changing) this may not be that useful for you.