NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Mounting MSDOS partitions



Hi, I'm running NetBSD on sparc. I have a Canon digital camera, which has a 
4GB memory card. The memory card is formatted with MSDOS filesystem

[root@ultra10] fdisk sd2
Disk: /dev/rsd2c
NetBSD disklabel disk geometry:
cylinders: 3886, heads: 64, sectors/track: 32 (2048 sectors/cylinder)
total sectors: 7959552

BIOS disk geometry:
cylinders: 988, heads: 128, sectors/track: 63 (8064 sectors/cylinder)
total sectors: 7959552

Partition table:
0: Primary DOS with 32 bit FAT (sysid 11)
    start 8192, size 7951360 (3883 MB, Cyls 1/2/3-987/6/6)
1: <UNUSED>
2: <UNUSED>
3: <UNUSED>
No active partition.

To access images on the memory card, I take the card out, plug it into a USB 
adapter and plug the adapter into a USB slot on my computer. Then I mount 
MSDOS filesystem. This worked on Solaris, but fails to work on NetBSD.

Simply running 'mount -t msdos /dev/sd2c /mnt' fails with error 
message 'Invalid argument'. On sparc, c partition refers to the whole disk.

If I use disklabel to edit the label on the memory card and create a new 
partition and mark it MSDOS, etc. Then I can mount and access the memory 
card, but when I insert the card back into my digital camera, it tells me 
that it can't read memory card. Somehow running disklabel messes up partition 
table and I have to reformat the memory card, which wipes out all the images.

Anyone knows of a fix or workaround? In Solaris I didn't have to edit any 
partition tables, I simply had to have the following entry in vfstab to 
access C drive/partition.

/dev/dsk/c4t0d0s0:c - /canon pcfs - no rw

Can NetBSD work in a similar way?


Home | Main Index | Thread Index | Old Index