If your Linux drive runs out of space without warning. Use the recommended tip below followed by *** to recover to get your drive back to write mode instead of read only. I booted from the USB as suggested below
https://superuser.com/questions/1258525/how-do-i-list-my-devices-in-grub
grub> set pager=1
grub> ls
(hd0) (hd0,msdos2) (hd0,msdos1)
grub> ls (hd0,1)/
lost+found/ bin/ boot/ cdrom/ dev/ etc/ home/ lib/
lib64/ media/ mnt/ opt/ proc/ root/ run/ sbin/
srv/ sys/ tmp/ usr/ var/ vmlinuz vmlinuz.old
initrd.img initrd.img.old
Could follow instructions at
https://www.linuxtechi.com/boot-ubuntu-18-04-debian-9-rescue-emergency-mode/
Video may help https://www.youtube.com/watch?v=tGyM4A6BJ00
Useful video https://www.youtube.com/watch?v=yTp4t82SKPU
https://unix.stackexchange.com/questions/148041/recovering-from-grub-rescue-crash
**** Switch to read/write mode by executing https://coderwall.com/p/1qptsw/ubuntu-recovery-mode-r-w-file-system
This:
$ mount -o remount,rw /
Now I can fix whatever files I messed up earlier
also https://askubuntu.com/questions/150086/ubuntu-will-not-start-due-to-full-partitions
****This may work as well to download a Ubuntu IOS live version for your USB. Boot from the USB
Try booting with a live cd (or usb). You should be able to access your file system and free up some space so that it will boot.
I’m pretty sure Windows can only read EXT3/4 filesystems which is why it said that it is write protected.
Download a Ubuntu LIVE ISO from ubuntu.org Burn and flash the ISO on to a USB stick to flash with Etcher. https://www.balena.io/etcher/
Boot from the USB stick with your priority of the USB first over the primary drive. http://www.boot-disk.com/boot_priority.htm
ubuntu live usb mount hard drive https://askubuntu.com/questions/43718/how-do-i-access-a-hard-drive-from-a-live-cd
sudo fdisk -l
https://serverfault.com/questions/618317/unable-to-mount-dev-sda
In my case: sudo mount /dev/sda1 /mnt
cd /mnt
Also check partitions on drive parted -l https://serverfault.com/questions/618317/unable-to-mount-dev-sda
I removed large files and followed
https://help.ubuntu.com/community/Grub2/Installing
sudo grub-install /dev/sdX # Example: sudo grub-install /dev/sda
https://help.ubuntu.com/community/Grub2/Installing
I went with the Boot-Repair Graphic tool option
https://help.ubuntu.com/community/Boot-Repair Install it with
sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair && boot-repair
The boot repair GUI should up with option fix the bootable drive
The boot drive may still be read only which can be fixed with
sudo fsck -f /dev/sdxx
https://askubuntu.com/questions/1135389/how-to-fix-read-only-file-system-on-18-04
For older versions of Ubuntu https://askubuntu.com/questions/640639/ubuntu-boots-to-read-only-filesystem-after-upgrading
Noted that /var/cache/apt/archives/lock has been a problem.
https://askubuntu.com/questions/640639/ubuntu-boots-to-read-only-filesystem-after-upgrading
ubuntu linux remove drive write protection
For me, I was able to recover my old Python source files but had to re-install the drive with the latest Ubuntu linux.
NOTE I now post my TRADING ALERTS into my personal FACEBOOK ACCOUNT and TWITTER. Don't worry as I don't post stupid cat videos or what I eat!