I'm almost there but I cannot get my key to be accepted by the remote access setup, if I:
add my public key to /home/<user>/.ssh/authorized_keys
run sudo generate-zbm
reboot
try to login on port 222
i still get access denied (public key) when logging into to the remote unlock ssh server
I can login directly to the system using the key without any password so I assume that the key in authorized_keys is properly added.
Some shell output:
Login and update
❯ ssh -i ~/.ssh/my_private_key andre@192.168.1.XX
Enter passphrase for key '<redacted>':
Welcome to Ubuntu 22.04.1 LTS (GNU/Linux 5.15.0-58-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Sun 15 Jan 18:33:52 CET 2023
System load: 0.0 Temperature: 35.0 C
Usage of /home: unknown Processes: 229
Memory usage: 1% Users logged in: 1
Swap usage: 0% IPv4 address for enp0s31f6: 192.168.1.26
0 updates can be applied immediately.
Last login: Sun Jan 15 18:34:29 2023 from 192.168.1.249
user@machine:~$ sudo generate-zbm
[sudo] password for user:
No initramfs generator specified; using dracut
Creating ZFSBootMenu 2.1.0 from kernel /boot/vmlinuz.old
SPL (7b85bf2c) and system (457d327f) hostids do not match!
Created backup /boot/efi/EFI/ubuntu/vmlinuz.old-bootmenu -> /boot/efi/EFI/ubuntu/vmlinuz.old-bootmenu-backup
Created backup /boot/efi/EFI/ubuntu/initramfs-bootmenu.img -> /boot/efi/EFI/ubuntu/initramfs-bootmenu-backup.img
Created initramfs image /boot/efi/EFI/ubuntu/initramfs-bootmenu.img
Created kernel image /boot/efi/EFI/ubuntu/vmlinuz.old-bootmenu
Try to access remote unlock shell
❯ ssh -i ~/.ssh/my_private_key -p 222 user@192.168.1.XX
Welcome to the ZFSBootMenu initramfs shell. Enter "zbm" to start ZFSBootMenu.
Enter passphrase for key '~/.ssh/my_private_key`:
user@192.168.1.XX: Permission denied (publickey).
What happens if you connect to the remote unlock shell using: ssh root@192.168.1.XX -p 222
You should be using the root user to connect to the remote shell.
Hello,
Thank you for you work with this script!
I'm almost there but I cannot get my key to be accepted by the remote access setup, if I:
/home/<user>/.ssh/authorized_keys
sudo generate-zbm
222
access denied (public key)
when logging into to the remote unlock ssh serverI can login directly to the system using the key without any password so I assume that the key in
authorized_keys
is properly added.Some shell output:
Login and update
Try to access remote unlock shell
What am I missing?