ALT Linux Bugzilla
– Attachment 5643 Details for
Bug 28082
initrd. Брать название luks устройств из /etc/crypttab
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
Патч на make-initrd 0.7.9-alt1
make-initrd-patch2.patch (text/plain), 1.66 KB, created by
timonbl4@altlinux.org
on 2012-11-21 16:17:23 MSK
(
hide
)
Description:
Патч на make-initrd 0.7.9-alt1
Filename:
MIME Type:
Creator:
timonbl4@altlinux.org
Created:
2012-11-21 16:17:23 MSK
Size:
1.66 KB
patch
obsolete
>diff --git a/features/luks/config.mk b/features/luks/config.mk >index 9564bc6..a625d37 100644 >--- a/features/luks/config.mk >+++ b/features/luks/config.mk >@@ -1,6 +1,7 @@ > CRYPTSETUP_BIN ?= /usr/sbin/cryptsetup >+CRYPTTAB_FILE ?= /etc/crypttab > LUKS_DATADIR ?= $(FEATURESDIR)/luks/data > LUKS_CIPHERS ?= aes > LUKS_BLOCKCIPHERS ?= cbc > LUKS_HASHES ?= sha256 >-LUKS_MODULES = dm-crypt $(LUKS_CIPHERS) $(LUKS_BLOCKCIPHERS) $(LUKS_HASHES) >\ No newline at end of file >+LUKS_MODULES = dm-crypt $(LUKS_CIPHERS) $(LUKS_BLOCKCIPHERS) $(LUKS_HASHES) >diff --git a/features/luks/data/lib/handlers/050-luks b/features/luks/data/lib/handlers/050-luks >index 7deac8b..91ed056 100755 >--- a/features/luks/data/lib/handlers/050-luks >+++ b/features/luks/data/lib/handlers/050-luks >@@ -55,6 +55,16 @@ readkey() { > handler() { > nameluks="${LUKS_ROOT##*/}-luks" > >+ if [ -r /etc/crypttab ]; then >+ LUKS_ROOT_UUID=$(blkid -o value -s UUID "$LUKS_ROOT") >+ while read crypttab_name crypttab_block crypttab_specifies crypttab_options; do >+ if [ x"$crypttab_block" = x"$LUKS_ROOT" ] || [ x"$crypttab_block" = x"UUID=$LUKS_ROOT_UUID" ]; then >+ nameluks=$crypttab_name >+ break >+ fi >+ done < /etc/crypttab >+ fi >+ > # skip if $nameluks has already exist > ! dmsetup info "$nameluks" >/dev/null 2>&1 || > exit 0 >diff --git a/features/luks/rules.mk b/features/luks/rules.mk >index 0dc9d18..f701949 100644 >--- a/features/luks/rules.mk >+++ b/features/luks/rules.mk >@@ -5,6 +5,7 @@ $(call require,devmapper,depmod-image) > luks: devmapper > @echo "Adding LUKS support ..." > @put-file "$(ROOTDIR)" $(CRYPTSETUP_BIN) >+ @put-file "$(ROOTDIR)" $(CRYPTTAB_FILE) > @put-tree "$(ROOTDIR)" $(LUKS_DATADIR) > > depmod-image: luks
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 28082
: 5643