I'm logged in via ssh(which I thought should not even be in recovery mode?) since my raspberry pi doesn't have monitor or keyboard. I've been having to remount the root directory as rw and there are lots of admin commands that are acting weird.
I could technically connect my pi to hardware and see what happens during Grub but I was just wondering if it's possible to do it just via terminal.
Asked
Active
Viewed 3,825 times
2
shriek
- 187
- 4
- 16
1 Answers
4
Is there a way to tell if Ubuntu is running in recovery mode via terminal?
From the webpage How to check a current runlevel of your Linux system:
Debian distribution has it runlevel 2-5 dedicated to full multi-user with graphical managers and console login whereas Redhat/Fedora has two separate runlevels for each mode. To check the runlevel of you system you can use runlevel command with no arguments:
runlevel
This answer says that the default runlevel in Ubuntu is 2, but for me it is 5. Anyway, recovery mode is a different number.
I've been having to remount the root directory as
rw
Probably your system remounted it to ro because there were I/O errors on the device. You should schedule a fsck and maybe consider buying a new SD card.
Andrea Lazzarotto
- 8,164