From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.saout.de ([127.0.0.1]) by localhost (mail.saout.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 78WiYcPkuX-G for ; Tue, 24 Jul 2012 16:27:54 +0200 (CEST) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.9]) by mail.saout.de (Postfix) with ESMTP for ; Tue, 24 Jul 2012 16:27:54 +0200 (CEST) Date: Tue, 24 Jul 2012 16:27:53 +0200 From: Heinz Diehl Message-ID: <20120724142753.GA21730@fancy-poultry.org> References: <20120722203929.GB3925@merlins.org> <20120722214757.GA16793@tansi.org> <20120723062850.GA6931@merlins.org> <20120723081407.GA872@tansi.org> <20120723161242.GB27727@merlins.org> <500D86AC.7090100@redhat.com> <20120723175129.GA15867@merlins.org> <500DC2B0.8060409@redhat.com> <20120724055722.GA15507@merlins.org> <500EA8FE.3010303@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <500EA8FE.3010303@redhat.com> Subject: Re: [dm-crypt] aes-xts-plain with aes_x86_64 makes my SSD 5x slower than my encrypted HD List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dm-crypt@saout.de On 24.07.2012, Milan Broz wrote: > - Disable readahead > # blockdev --setra 0 /dev/mapper/sdc_null_crypt This seems not only to be a problem with SSD drives, but also with conventional harddisks. I've never seen something like this, because I have had "blockdev --setra 8192 /dev/sda" in my rc.local for ages, because it's well known that it speeds up all disks significantly. Here's a short test. The partition is encrypted with 256-bit twofish-xts-plain64:sha256. [root@wildsau ~]# hdparm -i /dev/sda /dev/sda: Model=Hitachi HTS723232L9A360, FwRev=FC4OC30F, SerialNo=090119FC1400NEGNHSTD Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs } RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=4 BuffType=DualPortCache, BuffSize=15058kB, MaxMultSect=16, MultSect=16 CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=625142448 IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120} PIO modes: pio0 pio1 pio2 pio3 pio4 DMA modes: mdma0 mdma1 mdma2 UDMA modes: udma0 udma1 udma2 udma3 udma4 udma5 *udma6 AdvancedPM=yes: mode=0x80 (128) WriteCache=enabled Drive conforms to: unknown: ATA/ATAPI-2,3,4,5,6,7 With "blockdev --setra 8192" og "hdparm -tT": Timing buffered disk reads: 234 MB in 3.01 seconds = 77.69 MB/sec With "blockdev --setra 0" og "hdparm -tT": Timing cached reads: 4670 MB in 2.00 seconds = 2336.29 MB/sec Timing buffered disk reads: 14 MB in 3.06 seconds = 4.57 MB/sec ~~~~~~~~~~ With "blockdev --setra 0" og "hdparm --direct -tT": Timing O_DIRECT cached reads: 250 MB in 2.01 seconds = 124.45 MB/sec Timing O_DIRECT disk reads: 238 MB in 3.02 seconds = 78.80 MB/sec