The One and the Many

Linux boot stuck at LSB: Raise network interfaces

I rebooted a Raspberry Pi running Raspbian yesterday and it didn't come back online. I plugged it into a monitor and discovered it was stuck at this point in its boot process:

A start job is running for LSB: Raise network interfaces

It showed a time remaining of "no limit" (38s / no limit for example).

I've seen this eventually time out before (such as if the network is legitimately unavailable). In this case, the boot never proceeded beyond this point. I left it going over night, and I came back to it saying something like "10h / no limit". Clearly it was not going to resolve itself.

I expected I could get past this point if I removed all interfaces listed in /etc/network/interfaces, so I thought about pulling the SD card and editing it on my desktop, but then I wondered whether there was a Magic SysRq key combination that would let me get to a terminal.

I tried Alt+Sys Req+e. This sends a SIGTERM to all processes except init. This stopped the stuck job and the boot completed.

I discovered that /etc/network/interfaces had an interface listed, eth0, that I was no longer using with this Pi. I had not rebooted it since reconfiguring my network. I commented all the eth0 lines out, and rebooted. Boot got stuck again.

There was one more odd setting in this file. Under iface wlan0, I had a line that said:

up /usr/sbin/service ssh start

I originally put this under eth0 so that I could ssh to the Pi. This was about a year ago, and I think was only necessary due to a bug. I found that without it, I could not ssh into the Pi, but with it I could.

I removed this line from under the wlan0 iface definition, and rebooted again. This time the Pi booted just fine. I verified I could ssh into it.

So if you get stuck booting like I did, Magic (SysRq) might help!

Back

Comment