I dropped a new script into /etc/init.d, and used update-rc.d to install it into the other rc#.d subdirectories. Unfortunately I made two stupid mistakes:
- The script runs a long-running command (netcat), but I forgot to put
- The script got installed early in the boot order (S10).
And now I can't ssh in. I think the problem is that my script is blocking the boot (since I forgot
&), so the rc script that starts sshd never runs.
But I'm stuck, because ssh is normally the only way I have of logging in to this board. I've tried connecting a USB keyboard and an HDMI monitor, but I never get anything on the display and can't log in. I think this board may have been configured to not even try to drive the display.
Anybody have any suggestions? Options that I can think of are:
- Re-image the board. (I don't want to do that.)
- Use an FTDI serial cable. (I don't have that cable, but I've ordered one from Digi-Key.)
- Mount the board as a USB filesystem on another machine, and remove the offending symlinks from /etc/rcS.d/. (This doesn't seem to work; I suspect this board is not configured for OTG.)
- Get the board to boot into single-user mode, bypassing rc scripts like mine. (Not at all sure how to do this, though.)
Anybody have any other suggestions? Anybody know if logging in over FTDI is likely to work, even though the boot hasn't completed?