All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [dm-crypt] reinstallation
@ 2009-08-11 22:40 Sam
  0 siblings, 0 replies; 16+ messages in thread
From: Sam @ 2009-08-11 22:40 UTC (permalink / raw)
  To: dm-crypt; +Cc: RaMaier

Your problem is then with your Linux installation.

I would be guessing that your device mapper is not setup properly, or best 
case is simply not loaded by default for some reason.

Try this as root:

modprobe dm_mod

That will load the device mapper module (driver) and should be enough.

Then try your luksOpen command again.

If you get the same errror, then try also all of these in addition to the 
dm_mod:

modprobe crypto_blkcipher
modprobe cbc
modprobe dm_crypt
modprobe aes_generic
modprobe aes_i586

Some of these might fail with an error, but that could be just that they are 
already built into your kernel (and thus are permanently loaded -- that is 
okay).

Now try the luksOpen again. If it still doesn't work, then I do not know. 
However, it really should have worked by now at least.

If it did work: note that you will need to add these commands to your 
/etc/init.d/boot.local file (just add them to the end just like you typed them 
in the terminal). This will cause them to be loaded upon startup each time.

Hope that helps.

Sam

> When I just enter
> cryptsetup luksOpen /dev/sda2 tresor
> I get the reply:
> Command failed: No setup backend available
>
> I guess it somehow has a relation to the mapper.
> Any idea ?
>
> Best regards
> Rainer
>
>
> -------- Original-Nachricht --------
>
> > Datum: Tue, 11 Aug 2009 23:42:29 +0200
> > Von: Arno Wagner <arno@wagner.name>
> > An: RaMaier@gmx.de
> > Betreff: Re: [dm-crypt] reinstallation
> >
> > I suspect luksFormat wipes the LUKS superblock and creates
> > a new one, i.e. all data is permanently lost. mkfs.ext3
> > will overwrote the filesystem metadata, i.e. the filesystem
> > structure is lost.
> >
> > However
> >
> > > cryptsetup luksOpen /dev/sda2 tresor
> > > mount /dev/mapper/tresor /tresor
> >
> > should work, with sda2 replaced with whatever the
> > LUKS container now is in. Basically you just do what you
> > did before to access (not create) the device, just
> > with a (potentially) different device identifier.
> >
> > As to preventing partition loss, make a sector-wise
> > backup copy, e.g. with dd or dd_rescue before risking it.
> >
> > Arno
> >
> > On Tue, Aug 11, 2009 at 11:25:16PM +0200, RaMaier@gmx.de wrote:
> > > Hi Hannes,
> > > in the documents I keep. I found that I had encrypted /dev/sda2. The
> >
> > procedure I recorded was:
> > > umount /dev/sda2
> > > cryptsetup luksFormat /dev/sda2
> > > cryptsetup luksOpen /dev/sda2 tresor
> > > mkfs.ext3 /dev/mapper/tresor
> > > mount /dev/mapper/tresor /tresor
> > >
> > > What will happen if I repeat the steps ?
> > > Should I just leave the mkfs.ext3 out ?
> > > Would I be able to access my old data again ?
> > > What does lufsFormat really do ? Format the partition ?
> > > As I staded the data is pretty valuable to me.
> > >
> > > thanks for your help.
> > > Best regards
> > > Rainer
> > >
> > >
> > > -------- Original-Nachricht --------
> > >
> > > > Datum: Tue, 11 Aug 2009 16:01:56 +0200
> > > > Von: Hannes Erven <h.e@gmx.at>
> > > > An: Rainer Maier <RaMaier@gmx.de>
> > > > CC: dm-crypt@saout.de
> > > > Betreff: Re: [dm-crypt] reinstallation
> > > >
> > > > Hi Rainer,
> > > >
> > > > > How can I reinstall LUKS on my new Debian (Lenny)?
> > > >
> > > > I guess the debian (and thus cryptsetup) installations on your old
> > > > machine weren't that up to date, right?
> > > >
> > > > With the new debian lenny, you don't need to install anything: LUKS
> > > > is already included in the default cryptsetup package you should
> > > > already have installed (http://packages.debian.org/lenny/cryptsetup
> > > > ).
> > > >
> > > > >>From http://code.google.com/p/cryptsetup/:
> > > >
> > > > "The former version of cryptsetup only had low-level operations for
> > > > dm-crypt ready, and around version cryptsetup-luks 1.0.5 was renamed
> >
> > to
> >
> > > > be the official version of cryptsetup. "
> > > >
> > > > You still might have to change your old scripts, if you have some, to
> > > > just call cryptsetup instead of cryptsetup-luks .
> > > >
> > > >
> > > > HTH, best regards
> > > >
> > > > 	-hannes
> > > >
> > > >
> > > >
> > > > _______________________________________________
> > > > dm-crypt mailing list
> > > > dm-crypt@saout.de
> > > > http://www.saout.de/mailman/listinfo/dm-crypt
> >
> > -
> >
> > > sicherer, schneller und einfacher!
> > > http://portal.gmx.net/de/go/atbrowser
> > > _______________________________________________
> > > dm-crypt mailing list
> > > dm-crypt@saout.de
> > > http://www.saout.de/mailman/listinfo/dm-crypt

^ permalink raw reply	[flat|nested] 16+ messages in thread
* [dm-crypt] reinstallation
@ 2009-08-11 13:40 Rainer Maier
  2009-08-11 14:01 ` Hannes Erven
  0 siblings, 1 reply; 16+ messages in thread
From: Rainer Maier @ 2009-08-11 13:40 UTC (permalink / raw)
  To: dm-crypt

Hi all,
I had LUKS installed on my old raid5 system (via 3ware - 9500S-LP4).
Then the PC broke and I installed my Debian on a new one.
The raid controller also moved and works again.
The raid system still contains the LUKS encrypted partition.
How can I reinstall LUKS on my new Debian (Lenny)?

Any hints or tutorials ?

I scanned the internet, but I didn't find a tutorial I would trust.
I am also afraid to damage the data.
The unencrypted Data on the 2nd. raid partition is very valuable to me.

Thanks.
Rainer

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2009-08-12 12:27 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-11 22:40 [dm-crypt] reinstallation Sam
  -- strict thread matches above, loose matches on Subject: below --
2009-08-11 13:40 Rainer Maier
2009-08-11 14:01 ` Hannes Erven
2009-08-11 21:25   ` RaMaier
2009-08-11 22:06     ` Moji
2009-08-11 22:40       ` RaMaier
2009-08-11 23:34         ` Jonas Meurer
2009-08-11 23:36           ` Jonas Meurer
2009-08-12  6:19           ` Rainer Maier
2009-08-12  9:39             ` Jonas Meurer
     [not found]     ` <20090811214229.GA4796@tansi.org>
2009-08-11 22:25       ` RaMaier
     [not found]         ` <200908111839.19827.samm@sammaloney.com>
2009-08-11 22:54           ` RaMaier
2009-08-11 23:01             ` Sam
2009-08-12  6:09               ` Rainer Maier
2009-08-12  6:51             ` Milan Broz
2009-08-12 12:25               ` Rainer Maier

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.