web-dev-qa-db-ja.com

LUKS / CryptsetupおよびLVM:起動後にパスワードを入力できません

だから私は何度も成功してこの特定のチュートリアルを成功させました http://thesimplecomputer.info/full-disk-encryption-with-ubunt

2つのわずかに異なるもの:ubuntuではなくlubuntuを使用し、通常のドライブではなくUSBキーにインストールします。

しかし、新しいusbキーでこれを使用した私の最新の試みで、何かが起こりました。 apt-getを使用してdist-upgradeを実行するまで、使用の最初の数日間はすべて良好です。私は問題や中断なしにそれを完成させました。

ただし、基本的に起動すると、通常のLubuntuスプラッシュ画面が表示されますが、通常はパスワードを入力する入力フィールドはありません。

上下矢印キーを押して、ターミナルモードで入力できるかどうかを確認しようとしましたが、成功しませんでした。 「cryptsetup:lvm is not available」というメッセージが何度も繰り返されると、基本的にbusyboxモードが開始されます。

注:そのメッセージ、「cryptsetup:lvm is not available」は、他のusbキーでも何度もランダムに発生しました(同じcryptsetup + usbキーのlubuntu)問題のない暗号ボリューム。

だから、今どこに問題があるのか​​理解できません。 GRUBや起動の原因はないと思います。さもないと起動しません。

その最後のdist-upgradeが確実にこれを引き起こし、linuxヘッダーなどを更新したことがわかりましたが、この問題を理解できません。

まったく問題がある場合は、MBRパーティションテーブルを使用してディスクにインストールされたlubuntu yakketyを使用しています。

これを修正するにはどうすればよいですか? busybox経由でこの問題を修正する方法はありますか?私はその種の端末の使用の専門家ではありません


更新

以下の回答からの提案に従って、私はネオンのライブCDから次のことを試しました:

  • KDE Partition Managerを使用して、暗号化されたLUKSボリュームのロックを解除します。ここで、LVMをアクティブにする必要があります。 KDE Partition ManagerでF5(更新)を押すか、ターミナルでSudo vgchange -ayと入力します。これで、ルートファイルシステムが/ dev/mapper /にブロックデバイスとして表示されます。繰り返しますが、KDE ​​Partition Managerでは、ルートファイルシステムの名前を視覚的に見やすくすることができます。/dev/mapper/rootfsであるとしましょうが、以下のコマンドで正しいパスに置き換える必要があります。
  • 次に、次のコマンドを実行して、ルートファイルシステムにchrootします。

    Sudoマウント/ dev/mapper/rootfs/mnt1 Sudoマウント--bind/dev/mnt/dev Sudoマウント--bind/sys/mnt/sys Sudo chroot/mnt

最後に「Sudo update-initramfs -u -k all」を使用すると、次の出力が得られます。

update-initramfs: Generating /boot/initrd.img-4.8.0-32-generic
cat: /proc/cmdline: No such file or directory
/proc/devices: fopen failed: No such file or directory
Failed to set up list of device-mapper major numbers
Incompatible libdevmapper 1.02.130 (2016-07-06) and kernel driver (unknown version).
Command failed
cryptsetup: WARNING: failed to determine cipher modules to load for root
/proc/devices: fopen failed: No such file or directory
Failed to set up list of device-mapper major numbers
Incompatible libdevmapper 1.02.130 (2016-07-06) and kernel driver (unknown version).
Command failed
cryptsetup: WARNING: failed to determine cipher modules to load for swap
Warning: couldn't identify filesystem type for fsck hook, ignoring.
update-initramfs: Generating /boot/initrd.img-4.8.0-30-generic
cat: /proc/cmdline: No such file or directory
/proc/devices: fopen failed: No such file or directory
Failed to set up list of device-mapper major numbers
Incompatible libdevmapper 1.02.130 (2016-07-06) and kernel driver (unknown version).
Command failed
cryptsetup: WARNING: failed to determine cipher modules to load for root
/proc/devices: fopen failed: No such file or directory
Failed to set up list of device-mapper major numbers
Incompatible libdevmapper 1.02.130 (2016-07-06) and kernel driver (unknown version).
Command failed
cryptsetup: WARNING: failed to determine cipher modules to load for swap
Warning: couldn't identify filesystem type for fsck hook, ignoring.

更新2:

これは、すべてを削除して手順全体を繰り返した後の新しいエラー出力です。 GRUBブートメニューの後に表示できる2つの画面を含めます。

コマンド「update-initramfs -u -k all」の後、次のエラーログが表示されます。

root@lubuntu:/# update-initramfs  -u -k all
update-initramfs: Generating /boot/initrd.img-4.8.0-22-generic
device-mapper: table ioctl on root failed: No such device or address
Command failed
cryptsetup: WARNING: failed to determine cipher modules to load for root
device-mapper: table ioctl on swap failed: No such device or address
Command failed
cryptsetup: WARNING: failed to determine cipher modules to load for swap
W: Possible missing firmware /lib/firmware/i915/kbl_guc_ver9_14.bin for module i915
W: Possible missing firmware /lib/firmware/i915/bxt_guc_ver8_7.bin for module i915
Warning: couldn't identify filesystem type for fsck hook, ignoring.

そして、ここでは、起動後にlubuntuがどのように表示されるかを確認できますが、パスワード入力は表示されません

no input field for password

this is what I see if I hit F2 in the previous screen

3
user635976

すでにKDE Partition Manager 3.0をパッケージ化したNeon Live CDをダウンロードすることをお勧めします(ただし、Ubuntu 17.04にも含まれています)。次に、ターミナルウィンドウを開いてSudo apt update; Sudo apt install cryptsetup lvm2 partitionmanagerを実行します

  • KDE Partition Managerを起動して、暗号化されたLUKSボリュームのロックを解除します。または、ターミナルからそれを行うことができます:Sudo cryptsetup open /path/to/USB_device decrypted。このステップの後、/dev/mapper/decryptedにはLVM PVボリュームが含まれます。
  • ここで、LVMをアクティブにする必要があります。 KDE Partition ManagerでF5(更新)を押すか、ターミナルでSudo vgchange -ayと入力します。これで、ルートファイルシステムが/dev/mapper/のブロックデバイスとして表示されます。繰り返しますが、KDE ​​Partition Managerでは、ルートファイルシステムの名前を視覚的に見やすくすることができます。 /dev/mapper/rootfsであるとしましょう。ただし、以下のコマンドで正しいパスに置き換える必要があります。

次に、次のコマンドを実行して、ルートファイルシステムにchrootします。

  • Sudo mount /dev/mapper/rootfs /mnt
  • Sudo mount --bind /dev /mnt/dev
  • Sudo mount --bind /sys /mnt/sys
  • Sudo mount --bind /proc /mnt/proc
  • Sudo chroot /mnt
  • Sudo mount /boot

ここで、initramfsを再生成する必要があります。実行してみてください:

Sudo update-initramfs -u -k allおよび修正が必要なlvmに関するエラーが表示されるかどうかを確認します。後でもう少しリンクを見つけようとします...ここに表示されるエラーを投稿してください。

1