All of lore.kernel.org
 help / color / mirror / Atom feed
* [dm-crypt] cryptsetup alignment
@ 2013-06-29  3:21 Christoph Anton Mitterer
  2013-06-29  8:47 ` Milan Broz
  0 siblings, 1 reply; 3+ messages in thread
From: Christoph Anton Mitterer @ 2013-06-29  3:21 UTC (permalink / raw)
  To: dm-crypt

[-- Attachment #1: Type: text/plain, Size: 984 bytes --]

Hi Milan, et al.

Can I find out why cryptsetup created my LUKS devices with a payload
offset of 4096?
I mean these are 512B sectors right?... I though all tools would
nowadays align to 1 MiB  but that would be 2048 S.

The only possible reason I could see would be the following:
Topology
physical disc   ->
MBR partition /dev/sda1 at 2048S   ->
LVM PV on /dev/sda1 with alignment to 2048S    ->
LUKS on an LV on that PV with 4096S

So the data of the LV starts at 4096S which is 2 MiB.
The extent size of the VG is 4 MiB.

So when LUKS uses another 4096S (aka 2MiM).. then the (e.g.) filesystem
on top of LUKS will not only be aligned to the blocks of the disk (even
to any potential 4K disk blocks)... but also to the physical extents of
the LVM...


Is it _really_ that smart that it auto detected this and also included
the LVM's PE size into it's calculations?

If so please warn me to take a seat before I read your "yes"... ;-)


Thanks,
Chris.

[-- Attachment #2: smime.p7s --]
[-- Type: application/x-pkcs7-signature, Size: 5165 bytes --]

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

end of thread, other threads:[~2013-06-29 14:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-29  3:21 [dm-crypt] cryptsetup alignment Christoph Anton Mitterer
2013-06-29  8:47 ` Milan Broz
2013-06-29 14:07   ` Christoph Anton Mitterer

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.