Can't change permissions on file system (SD card) Solved

0

I have a SanDisk SD card (64 G). I had it loaded with berryboot and Kali Linux. I made the mistake of mounting the boot partition in fstab and when rebooted it gets stuck in a loop with berryboot’s config setup. I have tried to wipefs, dd if=/zero, and gparted to wipe the thing back to square one. Nothing worked because it’s a read-only file system. I have tried chmod and /dev/sdb mount -o remount,rw /dev/sdb and nothing. I can't seem to find a solution with my tools to get this back to being useable. Can somebody point me in the right direction or have any knowledge of any tools to get this writable? I have tried all of this as root. Here are some errors I have encountered:

from the command line:

sudo mount -o remount,rw /dev/sdb
mount: /dev/sdb: mount point not mounted or bad option.
 ✘ ⚙ arcarius@archlinux  ~  sudo chown arcarius:root /dev/sdb
 ⚙ arcarius@archlinux  ~  ls -l /dev/sdb
brw-rw---- 1 arcarius root 8, 16 Nov 14 19:52 /dev/sdb
 ⚙ arcarius@archlinux  ~  sudo chmod u+w /dev/sdb
 ⚙ arcarius@archlinux  ~  ls -l /dev/sdb         
brw-rw---- 1 arcarius root 8, 16 Nov 14 19:52 /dev/sdb
 ⚙ arcarius@archlinux  ~  Error while mounting /dev/sdb on /me: Read-only file system
✘ ⚙ arcarius@archlinux  ~  sudo wipefs /dev/sdb 
[sudo] password for root: 
DEVICE OFFSET TYPE UUID LABEL
sdb    0x1fe  dos       
 ⚙ arcarius@archlinux  ~  sudo wipefs --all --force /dev/sdb
wipefs: error: /dev/sdb: probing initialization failed: Read-only file system
 ✘ ⚙ arcarius@archlinux  ~  sudo wipefs --all --force /dev/sdb1
wipefs: /dev/sdb1: failed to erase vfat magic string at offset 0x00000036: Operation not permitted
 ✘ ⚙ arcarius@archlinux  ~  sudo dd if=/dev/zero of=/dev/sdb && sync status=progress                          
dd: failed to open '/dev/sdb': Read-only file system
 ✘ ⚙ arcarius@archlinux  ~  sudo dd if=/dev/urandom of=/dev/sdb && sync status=progress
dd: failed to open '/dev/sdb': Read-only file system
 ✘ ⚙ arcarius@archlinux  ~  sudo wipe -r /dev/sdb  
wipe: cannot open `/dev/sdb':Read-only file system
mount: 
/dev/sdb2 on /run/media/arcarius/berryboot type ext4 (ro,nosuid,nodev,relatime,data=ordered,uhelper=udisks2)
/dev/sdb1 on /mnt type vfat (ro,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)

Solved, davidgo was right. It was in fact the read-only switch. would have never thought of or had my eye open for such a thing.

filesystems
mount
file-permissions
read-only
asked on Super User Nov 14, 2017 by Joseph • edited Nov 15, 2017 by Joseph

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0