Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have an old casper-rw file I'd like to loop mount but I can't determine what filesystem it was created with. What I do know is that I used UNetbootin to create it.

I tried to mount it with all the ones I could think of off the top of my head, ext4, ext3, ext2, ReiserFS, and vFAT...something tells me that it might be squashfs, but I don't know what argument to use to mount it with squash.

share|improve this question

2 Answers 2

Have you tried using file to determine the file type? It also recognizes lots of filesystems.

file casper-rw
share|improve this answer
    
Great idea. Works for two of my live Ubuntu memory sticks. –  John S Gruber Aug 9 '12 at 13:00
    
That comes back with casper-rw: data what does that mean? –  leeand00 Jan 5 '13 at 18:23
    
It means the most specific thing file has to say about that is that it's data. In other words: it couldn't identify it. –  bseibold Jan 5 '13 at 23:41

From the unetbootin source on Launchpad I believe it is formatted as a EXT2 file. See approximately line 4126 in src/unetbootin/unetbootin.cpp in the source from the project git repository.

I gather that on various setups this can either be a file or a separate file system.

I think the way this is done is sort of standard. I'm a bit more familiar with sticks created by Startup Disk Creator. The main and first partition (maybe only partition) has MS formatting. Unless there is a separate partition labeled casper-rw there is a casper-rw file, which itself is a disk image of an EXT file system (for unetbootin EXT2, directions for other live boot sticks have examples of EXT3 and EXT4).

You shouldn't necessarily expect to see much on this file system. It only contains files in the live systems / file system that have been changed or created. There's some magic that uses a special file system that overlays the read-only root file system from the CD with the changes made to the file system embeded on the casper-rw file.

On one of my sticks made last year with Startup Disk Creator I was able to mount the DOS file system on the stick and enter the commands:

sudo losetup /dev/loop0 casper-rw
mkdir /tmp/a
sudo mount /dev/loop0 /tmp/a

and examine the contents of /tmp/a to see the files created or changed when running from the memory stick.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.