Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post here if you are a new Porteus member and you're looking for some help.
mmortal03
White ninja
White ninja
Posts: 9
Joined: 19 Sep 2022, 16:41
Distribution: x86_64/Porteus-v5.0

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#1 by mmortal03 » 20 Sep 2022, 10:59

I created a save.dat, 4095 MB, tried both xfs and ext4. Porteus will not successfully use either. See error message below. The save.dat is saved in the porteus directory, and I've edited the cfg file appropriately:
APPEND changes=/mnt/sdb1/porteus/save.dat

This is on a GPT, FAT32 formatted drive, using UEFI boot. I've tested using this identical configuration, but with an unencrypted save.dat file, and that works fine.

The boot screen error output is:

searching for porteus-v5.0-x86_64.cfg file
using Porteus data from /mnt/sdb1/porteus
setting up directory for changes
found encrypted.dat container
/dev/mapper/control: open failed: no such device
Failure to communicate with kernel device-mapper driver.
Check that device-mapper is available in the kernel.
Cannot initialize device-mapper. Is dm_mod kernel module loaded?
checking /dev/mapper/crypt for errors
sh: xfs: unknown operand
sh: ext: unknown operand
sh: rei: unknown operand
detected unsupported fs - skipping fsck
changes not writable, using memory instead

User avatar
babam
Warlord
Warlord
Posts: 526
Joined: 16 Nov 2016, 10:30
Distribution: Porteus 5.0rc3 Xfce K6.1.1
Location: Rainy city

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#2 by babam » 20 Sep 2022, 13:27

Use the xfs, ext4 is broken.
Sorry, my English is bad.

mmortal03
White ninja
White ninja
Posts: 9
Joined: 19 Sep 2022, 16:41
Distribution: x86_64/Porteus-v5.0

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#3 by mmortal03 » 20 Sep 2022, 13:51

babam wrote:
20 Sep 2022, 13:27
Use the xfs, ext4 is broken.
Neither worked.

User avatar
babam
Warlord
Warlord
Posts: 526
Joined: 16 Nov 2016, 10:30
Distribution: Porteus 5.0rc3 Xfce K6.1.1
Location: Rainy city

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#4 by babam » 20 Sep 2022, 13:53

mmortal03 wrote:
20 Sep 2022, 13:51


Neither worked.
Yes, ext4 doesn't work.
Sorry, my English is bad.

mmortal03
White ninja
White ninja
Posts: 9
Joined: 19 Sep 2022, 16:41
Distribution: x86_64/Porteus-v5.0

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#5 by mmortal03 » 20 Sep 2022, 15:50

babam wrote:
20 Sep 2022, 13:53
mmortal03 wrote:
20 Sep 2022, 13:51
Neither worked.
Yes, ext4 doesn't work.
I understand that ext4 doesn't work, but you said to use xfs, when xfs does not work, either.

User avatar
AcnapyxoB
Samurai
Samurai
Posts: 191
Joined: 24 Dec 2014, 10:15
Distribution: Porteus 5.01
Location: Planet Earth

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#6 by AcnapyxoB » 20 Sep 2022, 17:51

mmortal03 wrote:
20 Sep 2022, 13:51
Neither worked
Try with this: initrd.xz
Porteus v5.01 KDE x86_64

tome
Contributor
Contributor
Posts: 675
Joined: 26 Jun 2013, 14:03
Distribution: x64 Openbox
Location: Russia is causing the immense damage to humanity
Contact:

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#7 by tome » 21 Sep 2022, 13:16

Mayby this or similar: TODO list before Porteus 5 final release (Post by tome #87879)
Encrypted files work with Porteus 3.1
You have mind and feelings. Be wise and clever.

mmortal03
White ninja
White ninja
Posts: 9
Joined: 19 Sep 2022, 16:41
Distribution: x86_64/Porteus-v5.0

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#8 by mmortal03 » 21 Sep 2022, 14:34

AcnapyxoB wrote:
20 Sep 2022, 17:51
mmortal03 wrote:
20 Sep 2022, 13:51
Neither worked
Try with this: initrd.xz
Thanks, that works on xfs! I haven't tested it on ext4 yet. What are the modifications in there?
tome wrote:
21 Sep 2022, 13:16
Mayby this or similar: TODO list before Porteus 5 final release (Post by tome #87879)
Encrypted files work with Porteus 3.1
Link doesn't work.

User avatar
AcnapyxoB
Samurai
Samurai
Posts: 191
Joined: 24 Dec 2014, 10:15
Distribution: Porteus 5.01
Location: Planet Earth

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#9 by AcnapyxoB » 21 Sep 2022, 15:39

mmortal03 wrote:
21 Sep 2022, 14:34
What are the modifications in there?
I don't know ! I found it somewhere in the forum.
With above initrd.xz I use save.dat file (encrypted ext4) created with Porteus 4.0.
Porteus v5.01 KDE x86_64

User avatar
ncmprhnsbl
DEV Team
DEV Team
Posts: 3924
Joined: 20 Mar 2012, 03:42
Distribution: v5.0-64bit
Location: australia
Contact:

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#10 by ncmprhnsbl » 28 Sep 2022, 03:42

ok folks, i've figured it out:
the problem was in the build configuration for busybox: an incorrect(or incomplete) value(s) for the modprobe applet..
therefore the kernel module needed for deencryption wasn't being loaded..
please test with this: initrd.xz
(this contains busybox-1.35, updated libs and bins(e2fsck, ntfs-3g) and script fixes)

thanks to AcnapyxoB, for providing the hint that helped me narrow this down to busybox and thanks to an old debian bug report, i managed to set the busybox build config correctly.
Forum Rules : https://forum.porteus.org/viewtopic.php?f=35&t=44

User avatar
AcnapyxoB
Samurai
Samurai
Posts: 191
Joined: 24 Dec 2014, 10:15
Distribution: Porteus 5.01
Location: Planet Earth

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#11 by AcnapyxoB » 28 Sep 2022, 05:07

ncmprhnsbl wrote:
28 Sep 2022, 03:42
please test with this: initrd.xz
Confirmed, new initrd.xz working for creating and using encrypted ext4 save file.
Thanks ncmprhnsbl
Porteus v5.01 KDE x86_64

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#12 by Ed_P » 28 Sep 2022, 20:41

ncmprhnsbl wrote:
28 Sep 2022, 03:42
please test with this: initrd.xz
Works for me booting my FAT32 USB drive. :happy62:
Ed

ydyote
White ninja
White ninja
Posts: 7
Joined: 15 Mar 2023, 19:09
Distribution: porteus 5 lxde

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#13 by ydyote » 19 Mar 2023, 10:32

ncmprhnsbl wrote:
28 Sep 2022, 03:42
ok folks, i've figured it out:
the problem was in the build configuration for busybox: an incorrect(or incomplete) value(s) for the modprobe applet..
therefore the kernel module needed for deencryption wasn't being loaded..
please test with this: initrd.xz
(this contains busybox-1.35, updated libs and bins(e2fsck, ntfs-3g) and script fixes)

thanks to AcnapyxoB, for providing the hint that helped me narrow this down to busybox and thanks to an old debian bug report, i managed to set the busybox build config correctly.

Fresh user of porteus here

This fix is still not integrated to the official release of porteus 5.0

I'm using Porteus-LXDE-v5.0-i586.iso 5.18.8-porteus

at first I didn't want to take the "initrd.xz" which is posted here, because it seemed way different than the one in the iso, so I tried Porteus Kernel Builder (Post by Blaze #85938) but I guess I did it wrong so that didn't help me

I also tried it with x64 version but that didn't work either

then I applied the "initrd.xz" which I quoted and that seems to work fine on the i586 version I didn't test the x64 version

but I have no idea how much different is the original "initrd.xz" from the iso and this one here..

I used xfs save dat file with field "Savefile size (Mb)" set to 100 in the create new save container wizard

USB flash drive partition formatted as NTFS
booting via ventoy and replacing the porteus.cfg via ventoy to have an entry with parameters:

APPEND changes=EXIT:LABEL:Ventoy/_Porteus/Storage/main_storage_encrypted.dat


Thanks for the hard work, porteus seems cool, wanted to replace my puppylinux installation and this seems to be the best alternative

edit:
correction, it finds the file, takes my password but it doesn't properly mount the storage so porteus starts as fresh with no persistence, tested i586 and also x86_64 so I guess back to problem solving
Last edited by ydyote on 19 Mar 2023, 12:05, edited 1 time in total.

User avatar
Blaze
DEV Team
DEV Team
Posts: 3869
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus current ☯ all DEs ☯
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#14 by Blaze » 19 Mar 2023, 10:51

ncmprhnsbl wrote:
28 Sep 2022, 03:42
please test with this: initrd.xz
(this contains busybox-1.35, updated libs and bins(e2fsck, ntfs-3g) and script fixes)
ncmprhnsbl, in the General Announcements section Porteus-v5.0 updates
There is also an updated version of the initrd.xz that is not handled by the updater at this point and must be manually downloaded and replaced.
Location: <mirror>/x86_64/Porteus-v5.0/updates/core/20220924
Location of initrd.xz: <USB>/boot/syslinux/
changes for initrd.xz:
rebuilt busybox to fix using encrypted savefiles (corrected wrong build config option)
fixed fsck cheatcode

As always, backing up the original modules first is never a bad idea.
I don't found <mirror>/x86_64/Porteus-v5.0/updates/core/20220924 at the http://ftp.vim.org/ftp/os/Linux/distr/p ... 0/updates/
Where we can get a new initrd.xz?

Thanks
Linux 6.6.11-porteus #1 SMP PREEMPT_DYNAMIC Sun Jan 14 12:07:37 MSK 2024 x86_64 Intel(R) Xeon(R) CPU E3-1270 v6 @ 3.80GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Navi 23 [Radeon RX 6600] [1002:73ff] (rev c7) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

ydyote
White ninja
White ninja
Posts: 7
Joined: 15 Mar 2023, 19:09
Distribution: porteus 5 lxde

Can't boot using an encrypted xfs or ext4 dat file: /dev/mapper/control: open failed: no such device

Post#15 by ydyote » 19 Mar 2023, 12:43

Blaze, I found out that last mirror in the mirror list seems to have the ./updates/core directory

https://linux.rz.rub.de/porteus

https://linux.rz.rub.de/porteus/x86_64/ ... /20220924/

but yeah not all mirrors have it also not all are https

gonna try it whether that fixes my issue

Post Reply