I placed a startup script into /bin/scriptname on ubuntu 24.04 server in order to unlock my LUKS encrypted OS drive using a usb key. Unfortunately I made a typo in the script, and the unlock fails. The messages of the failed unlock are interleaved with messages about the syntax error in the script and continue indefinitely, not allowing me to type the unlock passphrase with an attached keyboard. Also, I cannot ssh into the machine with dropbear while this is all going on so that option to unlock is also out.
I tried getting into single-user mode by pressing escape rapidly (also tried holding the shift key) to no avail, and I booted from a ubuntu 24.04 usb to try to mount the OS drive and examine it for the startup script. I can't find it on the unencrypted partitions of the drive, and the larger partition is encrypted and will not mount. Any ideas where I might find this script to edit it, or another way to salvage the system?
I tried getting into single-user mode by pressing escape rapidly (also tried holding the shift key) to no avail, and I booted from a ubuntu 24.04 usb to try to mount the OS drive and examine it for the startup script. I can't find it on the unencrypted partitions of the drive, and the larger partition is encrypted and will not mount. Any ideas where I might find this script to edit it, or another way to salvage the system?