From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mail.saout.de (Postfix) with ESMTP for ; Thu, 27 Aug 2009 19:03:35 +0200 (CEST) Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n7RH3Yi7011671 for ; Thu, 27 Aug 2009 13:03:34 -0400 Received: from [10.34.32.183] (mazybook.englab.brq.redhat.com [10.34.32.183]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id n7RH3Xq3022569 for ; Thu, 27 Aug 2009 13:03:33 -0400 Message-ID: <4A96BC64.9020308@redhat.com> Date: Thu, 27 Aug 2009 19:03:32 +0200 From: Milan Broz MIME-Version: 1.0 References: <20090827145703.GA11409@fancy-poultry.org> <4A96A9D8.4070904@gmail.com> <20090827162838.GB24973@resivo.wgnet.de> In-Reply-To: <20090827162838.GB24973@resivo.wgnet.de> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [dm-crypt] volume unrecognized List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dm-crypt@saout.de Jonas Meurer wrote: >> cryptsetup luksDump $DEVICE >> >> Find the payload number >> >> dd if=$DEVICE of=luks_header_bakup count=$PAYLOAD >> >> To restore them just reverse if and of in dd >> >> dd if=$luks_header_backup of=$DEVICE count=$PAYLOAD > > you should add bs=1 to the dd commandline. default is 512, which would > result in $PAYLOAD*512 bytes being read/written. Nope, payload offset in dump _is_ in 512 byte sector units. bs=512 is correct. (You will save all (even unused) keyslots here, but this is not problem) Milan