[systemd-devel] [PATCH] cryptsetup-generator: allow specifying options in /proc/cmdline
Harald Hoyer
harald at redhat.com
Mon Aug 19 01:34:56 PDT 2013
On 08/18/2013 06:15 PM, Tom Gundersen wrote:
> The main usecase for this is to make it possible to use cryptsetup in
> the initrd without it having to include a host-specific /etc/crypttab.
>
> Cc: Harald Hoyer <harald at redhat.com>
> Tested-by: Thomas Bächler <thomas at archlinux.org>
> ---
>
> Hi guys,
>
> This allows us to use systemd in the initrd for encrypted root in Arch. I
> didn't look much into how this is done in dracut, so comments on whether
> or not this will work for you would be welcome.
>
> Cheers,
>
> Tom
>
Hmm, the naming "luks.options" is IMHO poorly chosen. "options" as an option
name... hmm. Also crypttab can contain more encryption modes, than LUKS.
If you want to reflect crypttab, why not specify something like:
[rd.]crypttab=<name>;<device>;<password>;<options>
As for dracut, here is what we currently have:
https://www.kernel.org/pub/linux/utils/boot/dracut/dracut.html#_crypto_luks
$ man dracut.cmdline
crypto LUKS
rd.luks=0
disable crypto LUKS detection
rd.luks.uuid=<luks uuid>
only activate the LUKS partitions with the given UUID. Any "luks-"
of the LUKS UUID is removed before comparing to <luks uuid>. The
comparisons also matches, if <luks uuid> is only the beginning of
the LUKS UUID, so you don't have to specify the full UUID. This
parameter can be specified multiple times.
rd.luks.allow-discards=<luks uuid>
Allow using of discards (TRIM) requests for LUKS partitions with
the given UUID. Any "luks-" of the LUKS UUID is removed before
comparing to <luks uuid>. The comparisons also matches, if <luks
uuid> is only the beginning of the LUKS UUID, so you don't have to
specify the full UUID. This parameter can be specified multiple
times.
rd.luks.allow-discards
Allow using of discards (TRIM) requests on all LUKS partitions.
rd.luks.crypttab=0
do not check, if LUKS partition is in /etc/crypttab
More information about the systemd-devel
mailing list