2

I need to get into a partition on an SD card, but it has no file system and I can't figure out how to mount it. When I type

parted /dev/sdc print

I get

Model: USB Mass  Storage Device (scsi)
Disk /dev/sdc: 129GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start   End     Size    Type     File system  Flags
 1      4194kB  62.9MB  58.7MB  primary  fat16        lba
 2      62.9MB  129GB   129GB   primary

I have not been able to figure out how to mount #2, but I really have to get to it.

Background: This is an SD card I used on a Raspberry Pi. The pi was acquiring video data and saving it to the file system. Like an idiot, I plugged in the SD card to my Ubuntu machine, it automounted both boot (#1) and the Linux file system (#2). I watched a few of the videos and they were awesome. I DID NOT copy the files over to my computer (big mistake). Now, after unmounting and coming back later, I can't get into #2. My videos are sitting there and I want them. The Pi will no longer boot on its own so I can't get in that way.

Trying to mount the partition with ext3, ext4, vfat, or msdos gives some variant of the following

mount -t ext4 /dev/sdc2 /media/pi

returns

mount: wrong fs type, bad option, bad superblock on /dev/sdc1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

And

dmesg | tail

gives

[2068799.476208] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00006520)
[2068799.476329] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00006c6c)
[2068799.476397] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00007620)
[2068799.485943] FAT-fs (sdc1): error, invalid access to FAT (entry 0x000076b3)
[2068799.486050] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00006e65)
[2068799.495272] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00006001)
[2068799.495389] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00004000)
[2068799.495505] FAT-fs (sdc1): error, invalid access to FAT (entry 0x00006573)
[2068799.495564] FAT-fs (sdc1): error, invalid access to FAT (entry 0x0000414d)
[2068946.845907] EXT4-fs (sdc2): VFS: Can't find ext4 filesystem

Trying to mount as vfat or msdos gives

dmesg | tail
[2069137.546806] FAT-fs (sdc2): bogus number of FAT structure
[2069137.546809] FAT-fs (sdc2): Can't find a valid FAT filesystem

Trying to mount as ntfs gives

NTFS signature is missing.
Failed to mount '/dev/sdc2': Invalid argument
The device '/dev/sdc2' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?

dmesg | tail

[2069279.102188] usb 2-6: reset high-speed USB device number 27 using ehci_hcd
[2069279.358047] usb 2-6: reset high-speed USB device number 27 using ehci_hcd
[2069279.490651] sd 26:0:0:0: [sdc] Unhandled error code
[2069279.490654] sd 26:0:0:0: [sdc]  Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[2069279.490657] sd 26:0:0:0: [sdc] CDB: Read(10): 28 00 00 01 e2 00 00 00 08 00
[2069279.490661] end_request: I/O error, dev sdc, sector 123392
[2069279.490665] Buffer I/O error on device sdc2, logical block 64
[2069279.605895] usb 2-6: reset high-speed USB device number 27 using ehci_hcd
[2069280.444934] sd 26:0:0:0: [sdc] No Caching mode page found
[2069280.444937] sd 26:0:0:0: [sdc] Assuming drive cache: write through
4
  • Your mount command is for sdc1. Commented Sep 18, 2015 at 0:56
  • Yes, that's a typo because I tried both sdc1 and sdc2. Will edit tomorrow with proper commands. Thank you for catching that. Commented Sep 18, 2015 at 1:14
  • What does 'file -s /dev/sdc2' show? Commented Sep 18, 2015 at 14:04
  • It shows /dev/sdc2: data. What kind of file system is that? Trying mount -t data says "unknown file system type 'data'" Commented Sep 20, 2015 at 14:26

1 Answer 1

1

but it has no file system and I can't figure out how to mount it.

If it has no filesystem then for sure you cannot mount it. Mounting it fundamentally an operation on a filesystem. (If there is no filesystem then there is nothing to mount.)

However, if you meant that it has an unknown filesystem type, rather than no filesystem at all, then I suggest this command to identify what type of filesystem it is:

file -Ls /dev/sdc2

If file is able to identify the filesystem type, then you will know what argument to pass to the -t option of mount. If file is unable to identify the filesystem type, then the block device might contain something else than a filesystem or it might be empty.

1
  • 2
    The response is "data." Commented Sep 20, 2015 at 14:32

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.