首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >解密密钥槽时的luks IO错误

解密密钥槽时的luks IO错误
EN

Server Fault用户
提问于 2018-04-08 21:13:14
回答 1查看 1.4K关注 0票数 1

我试图使用加密设置来加密一些分区,但是得到了错误的IO error while decrypting keyslot.

命令和输出是:

代码语言:javascript
复制
root@rescue ~ # cryptsetup --debug --verbose --cipher aes-xts-plain64 --key-size 256 --hash sha256 --iter-time 6000 luksFormat  /dev/sda3
# cryptsetup 1.6.6 processing "cryptsetup --debug --verbose --cipher aes-xts-plain64 --key-size 256 --hash sha256 --iter-time 6000 luksFormat /dev/sda3"
# Running command luksFormat.
# Locking memory.
# Installing SIGINT/SIGTERM handler.
# Unblocking interruption on signal.

WARNING!
========
This will overwrite data on /dev/sda3 irrevocably.

Are you sure? (Type uppercase yes): YES
# Allocating crypt device /dev/sda3 context.
# Trying to open and read device /dev/sda3.
# Initialising device-mapper backend library.
# Timeout set to 0 miliseconds.
# Iteration time set to 6000 miliseconds.
# Interactive passphrase entry requested.
Enter passphrase: 
Verify passphrase: 
# Formatting device /dev/sda3 as type LUKS1.
# Crypto backend (gcrypt 1.6.3) initialized.
# Detected kernel Linux 4.9.85 x86_64.
# Topology: IO (512/0), offset = 0; Required alignment is 1048576 bytes.
# Checking if cipher aes-xts-plain64 is usable.
# Using userspace crypto wrapper to access keyslot area.
IO error while decrypting keyslot.
# Releasing crypt device /dev/sda3 context.
# Releasing device-mapper backend.
# Unlocking memory.
Command failed with code 5: IO error while decrypting keyslot.

我确实找到了抛出这个错误的代码,这里,但是它没有给我提供任何洞察力。

正如您从输出中看到的,分区被格式化了,但是键槽没有被写入。

/dev/sda是一个3 3ware数组,分区表由debian安装程序写入设备。我发现(错误的),我可以在整个设备上创建一个LUKS容器,但这对我来说不是一个可行的解决办法,因为它是服务器上唯一的存储设备,我需要一个未加密的/boot分区。

EN

回答 1

Server Fault用户

发布于 2018-04-08 22:35:51

我理解了这一点,在问题中的命令之前,我在通过uuid指定分区时尝试了相同的操作,如下所示:

代码语言:javascript
复制
cryptsetup <options> luksFormat /dev/disk/by-uuid/<disk uuid>

在此操作期间,uuid将更改。我不理解细节,但我最终得到了一个损坏的分区表。

票数 1
EN
页面原文内容由Server Fault提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://serverfault.com/questions/906660

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档