I found previous version was quite slow (3MB/s), but this newer Pi has more power.
What speeds can I expect with external hdd and standard installation of luks (I believe aes 256, xts, plain 64)?
I can see this question, the performance of Rasperry Pi 4 on LUKS, is old, but it is more relevant now than ever.
It is quite common to use LUKS with AES because CPUs (like Intel's, AMD's, etc) include AES acceleration in the CPU. This makes AES fast because encryption and decryption is performed by hardware. On the other hand, Raspberry Pi CPU's do not include AES acceleration, and this makes AES slow.
The situation has changed recently wih the creation of Adiantum encryption algorithm and its incorporation in Raspberry Pi OS's kernel modules. Adiantum was designed to be secure and fast in software, faster than AES in software. This allows LUKS on Raspberry Pi to be faster than before if Adiantum is used.
If someone wants to try it, this is a good guide that explains how to encrypt the SD card of a Raspberry Pi to use LUKS with Adiantum: https://rr-developer.github.io/LUKS-on-Raspberry-Pi/
I have recently installed LUKS on a Raspberry Pi 4B with 4GB RAM. I'm using a Seagate Video 2.5HDD 1TB model ST100VT001, and transferring via LAN from a 500GB Samsung SSD.
I've checked, Adiantum is running. (Adiantum? Is that a precious metal from Avatar?)
My test is 128 files, total size 208GB. Windows10 predicts that it will take about 50 minutes. So far, the copy speed is fairly steady at 55 MB/s.
I expect the main limitation on speed to be the encryption process, as the SSD can supply data at 500 MB/s. My LAN is gigabit, so it maxes out at about 110MB/s. The hard drive should be able to accept data at around 100MB/s.
So I conclude that the RasPi 4B is encrypting at about 50MB/s which is pretty good all things considered.
And yes, this is my first post here.
USB3 is about 10x faster than cryptography on the RPI 4 SOC which is missing hardware common to other SOCs in the same price and performance range.
aes-xts 512b benchmarks:
MiB/s, Product
9.7, RPI 1
18.8, HiFive Unmatched (U740)
22.5, RPI 3
42.2, Odroid C2
60.0, USB2 ===
66.1, RPI 4
76.2, Odroid XU4
221.2, UP1
240.3, Orange Pi PC2, NanoPi NEO2 (AllWinner H5)
267.0, espressobin
370.5, ROCK64 (RK3328)
570.6, Odroid C4 (S905X3)
625.0, USB3 ===
655.6, Odroid N1, ROCKPRO64, etc (RK3399)
666.1, UP2 (N4200)
704.2, Odroid H2 (J4105)
707.1, Odroid N2 (S922X)
826.1, rackspace (E5-2670)
985.1, EC2 (AMD EPYC 7571)
1366.7, EC2 (E5-2676)
1393.7, old i5 (2500S)
2710.3, Ryzen 1800X
2994.5, i7-1165G7
The Pi 4 has USB 3.0, which I assume is what you plan to connect your external HDD over. The maximum bandwidth of USB 3.0 is 640 MB/s. (The Pi 3 had USB 2.0, which maxes out at 60 MB/s.) However, this is only the theoretical maximum speed.
It's hard to estimate the speeds you would get in practice, since software overhead will slow your R/W speed down.