Hi Uwe, Hi Jonas, At Fri, 15 Feb 2008 10:46:30 +0100, Uwe Menges <uwe.menges@xxxxxx> wrote: > > On Tuesday 12 February 2008 10:02:15 Jonas Meurer wrote: > >btw, i guess that the resize option is even more interesting, to support > >online resizing of LUKS devices. > > Erm... I'm a bit confused now. It seems that a lot of people already do LUKS > online resizing since quite a while, most of the time without problems (see > eg. > http://article.gmane.org/gmane.linux.kernel.device-mapper.dm-crypt/2214/ ) > > Do you state this is not safe? It definitely is possible, google "luks > resize", it boils down to something like > > lvresize -L +10g /dev/vg0/data > cryptsetup resize /dev/mapper/data > ext2online /dev/mapper/data > > Maybe you can clarify that a bit? I'm not able to reproduce any problems with resizing and LUKS devices. Also resizing seems to work when using an offset. At Wed, 6 Feb 2008 23:29:31 +0100, Jonas Meurer wrote: > # cryptsetup --size 4194304 resize test1 > Command failed: device-mapper: reload ioctl failed: invalid argument Jonas, the problem here is that --size specifies the size of the dm-crypt device, not the underlying block device. So if 4194304 is the size of the underlying device, the dm-crypt device can only be as large as 4194304 minus 1032, that's what LUKS usually uses as offset, (see "Payload offset" in luksDump) When using resize without --size, cryptsetup queries the underlying block device for its size and subtracts the offset currently in use to arrive at the size of the dm-crypt device. Sorry, this mail was supposed to be sent a week ago, but just now I found that it's still sitting in Drafts. -- Fruhwirth Clemens - http://clemens.endorphin.org --------------------------------------------------------------------- dm-crypt mailing list - http://www.saout.de/misc/dm-crypt/ To unsubscribe, e-mail: dm-crypt-unsubscribe@xxxxxxxx For additional commands, e-mail: dm-crypt-help@xxxxxxxx