|
<html><head><title>[Solved] Emergency Mode Due to Bad fstab in Raspberry Pi</title><meta name="URL" content="https://www.clarkle.com/notes/emergecy-mode-bad-fstab/#:~:text=To%20do%20that%2C%20enter%20mount,will%20panic%2C%20but%20it's%20fine."/> |
|
<meta name="Source" content="internet"/> |
|
<meta name="Category" content="interest"/> |
|
<meta name="Created" content="2023-05-09T15:18:00.000Z"/> |
|
<meta name="Already Read" content="false"/> |
|
<meta name="Name" content="[Solved] Emergency Mode Due to Bad fstab in Raspberry Pi"/> |
|
<meta name="parent" content="References"/> |
|
</head><body><H1>[Solved] Emergency Mode Due to Bad fstab in Raspberry Pi</H1><a href="https://www.notion.so/Solved-Emergency-Mode-Due-to-Bad-fstab-in-Raspberry-Pi-9b04ea5d88ae420bbf2331245d81edd4">Link to original Notion Page</a></p><table border='1'><tr><td><b>Property</b></td><td><b>Value</b></td></tr><tr><td>URL</td><td>https://www.clarkle.com/notes/emergecy-mode-bad-fstab/#:~:text=To%20do%20that%2C%20enter%20mount,will%20panic%2C%20but%20it's%20fine.</td></tr> |
|
<tr><td>Source</td><td>internet</td></tr> |
|
<tr><td>Category</td><td>interest</td></tr> |
|
<tr><td>Created</td><td>2023-05-09T15:18:00.000Z</td></tr> |
|
<tr><td>Already Read</td><td>false</td></tr> |
|
<tr><td>Name</td><td>[Solved] Emergency Mode Due to Bad fstab in Raspberry Pi</td></tr> |
|
<tr><td>parent</td><td>References</td></tr> |
|
</table> <div><p class='n_paragraph'>You can automatically mount a drive on your Raspberry Pi by editing your fstab file. <a href='https://community.linuxmint.com/tutorial/view/1513'>Learn how to automatically mount a drive on your Raspberry Pi here</a>.</p ><p class='n_paragraph'>But if you’re like me, editing fstab rarely works right the first time. This typically results in your system crashing on startup with a message saying that your Raspberry Pi has gone into “Emergency Mode”. You fix this by removing (or editing) the new line from your fstab file. But how do you do that if your system won’t start up?</p ><p class='n_paragraph'><b>Here’s how to get your Raspberry Pi out of Emergency Mode, and booting again:</b></p ><ul><li class='n_bulleted_list_item'>Take your SD card out of your Pi and mount it on another computer.</li ><li class='n_bulleted_list_item'>Open the boot partition, and the file <b>cmdline.txt</b></li ><li class='n_bulleted_list_item'>Add <b>init=/bin/sh</b> to the end of the line and save the file</li ><li class='n_bulleted_list_item'>Unmount, place back into your Pi, and power up your Pi. Your Pi will boot into a minimum shell environment as root.</li ><li class='n_bulleted_list_item'>At this point, you need to mount the actual filesystem, but without loading fstab. To do that, enter <b>mount -o remount,rw / –target /</b> and hit enter</li ><li class='n_bulleted_list_item'>Now, edit your fstab file by entering <b>vi /etc/fstab</b> and hitting enter</li ><li class='n_bulleted_list_item'>After you’ve made your edits, exit the file, then at the command line, type exit. The system will panic, but it’s fine.</li ><li class='n_bulleted_list_item'>Remove the SD card from your Pi and put it back into the other computer.</li ><li class='n_bulleted_list_item'>Open the boot partition, and the file <b>cmdline.txt</b></li ><li class='n_bulleted_list_item'>Remove <b>init=/bin/sh</b> from the end of the line and save the file</li ><li class='n_bulleted_list_item'>Unmount the SD card, place it back into your Pi, and power up your Pi. You should be good to go now.</li ></ul><p class='n_paragraph'>Alternatively, throw your Pi away and just grab a new <a href='https://amzn.to/2pEczUw'>Raspberry Pi 3 from Amazon</a>.</p ></div></body></html> |