Full disk encryption with calamares: beware of last testing upgrade!
#1
I just upgraded my pinephone to the last testing via apt as always, and now the full disk encryption (calamares) passephrase prompt is looping with a "bad option" error. So I can no longer boot.

I have not investigated yet, just wanted to alert you.

I bet I can save myself by mounting the eMMC over USB, hopefully last time I had a similar issue I wrote about it: https://mdk.fr/blog/black-screen-at-boot...phone.html

Update:I tried another apt full-upgrade and a dpkg-reconfigure linux-image-6.6-sunxi64 over USB mass storage / chroot, no luck, but it seems a tad different, it now reads:

panel-sitronix-st7703 : ... midi_dsi_attach failed (-517) Is host ready?
pinephone-keyboard: Failed to read device ID: -6

Update: I noticed in my upgrade that phosh-osk-stub had an upgrade, so I downgraded it with `dpkg -i /var/cache/apt/archives/phosh-osk-stub_0.44.0-1_arm64.deb`, but no luck, still no keyboard at boot to decrypt my root fs Sad
  Reply
#2
Ask  devs in #mobian matrix room.  Share their fix.
 

Quote:Starting kernel ...

[  xx.xxxxxx] lima 1c40000.gpu: error -ENODEV: _opp_set_regulators: no regulator (mali) found
[  xx.xxxxxx] pinephone-keyboard 3-0015: Failed to read device ID: -6
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized
MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized


BusyBox v1.37.0 (Debian 1:1.37.0-4) built-in shell (ash)
Enter 'help' for a list of built-in commands.

(initramfs)
  Reply
#3
(Yesterday, 02:07 AM)dragonhospital Wrote: Ask  devs in #mobian matrix room.  Share their fix.
 

Quote:Starting kernel ...

MESA-LOADER: failed to open dri: /usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so: cannot open shared object file: No such file or directory (search paths /usr/lib/aarch64-linux-gnu/gbm, suffix _gbm)
ERROR: Could not create window/display: EGL not initialized




Hi, I have the same issue -- the core problem is in the absence of the library "dri_gbm.so", which is not copied during initramfs generation, I see the error below:




Code:
ln: failed to create symbolic link '/var/tmp/mkinitramfs_87Ugk3//usr/lib/aarch64-linux-gnu/dri/libdril_dri.so': File exists


I did a check of the initramfs contents, by copying it to the host and added `/usr/lib/aarch64-linux-gnu/gbm/dri_gbm.so` manually -- that requires unpack and pack of existing initramfs. After that, Pinephone booted well.


Looks like the issue is in initramfs generation scripts, so with `osk-sdl` the initramfs would be regenerated in wrong way.


In Matrix channel, there were a suggestion to switch to more recent OSK `unl0kr` and that helped in my case.

Safe steps:

  • change `/etc/crypttab` file, to point to proper keyscript `keyscript=/usr/share/initramfs-tools/scripts/unl0kr-keyscript`
  • install `unl0kr`, automatically regenerated initramfs will contain both OSKs
  • remove `osk-sdl` and initramfs will be regenerated again, but will contain only `unl0kr`




Good thing what initramfs is 3 times (!!!) less than with osk-sdl with all deps:


Code:
$ ls -lh /boot/initrd.img-6.12-sunxi64*
-rw-r--r-- 1 root root 29M Feb 14 18:53 /boot/initrd.img-6.12-sunxi64
-rw-r--r-- 1 root root 99M Feb 14 16:45 /boot/initrd.img-6.12-sunxi64.bak

Bad news -- the `unl0kr` doesn't support the Pinephone keyboard.
  Reply
#4
d4s  how is initramfs  unpacked&packed?

Your instructions is for everyone that has not booted. Trixie users do not  reboot!

First back up /etc/crypttab

Second change osk-sdl-keyscript in  /etc/crypttab to unl0kr-keyscript

Third sudo apt install --reinstall unl0kr


chroot steps if already rebooted and broke.

First  download 2023  mobian img from mobian.org

Second  write mobian img to  spare SD card

Third  put SD card in pinephone and boot while holding down volume button

Fourth when fresh mobian loaded use  password 1234  and connect to internet

Fifth  open terminal console  and sudo su

Sixth apt install cryptsetup-bin 

Seventh lsblk to find  boot and  encrypted  fs of onboard mmc

Eight cryptsetup luksOpen /dev/mmblkXpY  root    X and Y are numbers from lsblk

Ninth mount /dev/mapper/root /mnt

Tenth mount /dev/dev/mmblkApB /mnt/boot A and B are numbers from lsblk

Eleventh for i in /dev /dev/pts /proc /sys /run; do sudo mount -B $i /mnt$i; done

Twelfth sudo chroot /mnt

Thirteenth  back up /etc/crypttab and change osk-sdl-keyscript in  /etc/crypttab to unl0kr-keyscript

Fourteenth  sudo apt install --reinstall unl0kr

exit and reboot

unl0kr crashes w/USB keyboard. Bug. Use onscreen keyboard to unlock and boot.
Camera now broken too, can't load firmware. Bug.
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Upgrade to Mobian (Trixie) Staging biketool 13 1,479 12-29-2024, 10:35 AM
Last Post: biketool
  How to use an NVMe disk as rootfs Smaking 3 585 11-29-2024, 06:51 AM
Last Post: walter1950
  boot gets stuck shortly after disk decryption vortex 9 6,599 09-11-2024, 05:40 AM
Last Post: normangraves
  What actions needed to keep on mobian testing user641 3 2,912 09-05-2023, 06:44 AM
Last Post: Zebulon Walton
  Mobian boot failed with zstd message after upgrade. Mahgue 0 1,096 09-01-2023, 11:29 AM
Last Post: Mahgue
Wink Pinephone lost graphic during mobian system upgrade cmpin 4 3,370 03-01-2023, 04:45 PM
Last Post: anonymous
  No boot after upgrade: vibration, red LED, then 2 vibrations and yellow LED 3x5co 1 1,516 01-04-2023, 06:46 PM
Last Post: 3x5co
  Receive MMS fails after Nov 27 upgrade treebeard 17 9,917 12-12-2022, 05:09 AM
Last Post: anonymous
  beware chatty 0.7.0~rc0-1 treebeard 6 4,111 11-06-2022, 04:51 PM
Last Post: treebeard
  Calamares initialization failure GOOOFBALLL 4 2,824 10-21-2022, 05:33 AM
Last Post: merom

Forum Jump:


Users browsing this thread: d4s, 2 Guest(s)