So, I have a weird laptop that won't correctly boot from my USB3.0 stick. Grub and
initramfs load up, but then miraculously the stick is not mounted. If I just wait, the machine drops to the busybox shell.
blkid doesn't list my stick. But if I before that happens, at the correct time, replug that stick, Ubuntu boots up correctly.
So I thought, let's automate that. I got myself a restart_usb shell script, put it in
/etc/initramfs-tools/scripts/init-premount, and ran
Now comes the funny part: the script is executed while generating the new
initramfs, thus resetting usb and by that, leaving a running linux with no access to any of its partitions. Only hard reset helps there.
So my question is: how do I put a script that runs before we try to mount
/ into the
initramfs without it being executed by
Edit: I'm running a fresh install (not updated) of Ubuntu 14.04.