I don’t think this is specifically a Toradex-related question but I’m asking here on the off chance that someone has come across this before and could offer a suggestion as to what I can do to resolve the issue.
I have a USB pen drive which is formatted using NTFS (for >4GB file sizes).
I have bit-baked a fresh V2.8b7 angstrom-qt5-x11-image, and included the ntfs-3g driver. I did previously try just enabling the default ntfs driver in the kernel but this had issues of its own (file sync issues between Linux and Windows, etc).
When the USB flash drive is connected to Windows, I can browse the NTFS drive nicely and I can create/edit/remove files/directories as you would typically expect.
However, when I connect the USB pen drive to the Ixora carrier board with an Apalis T30 module running the Angstrom image, weird things happen:
The drive ( /dev/sdb
, note the lack of partition) is mounted automatically to /media/sdb
however, I cannot browse this mount point - I get an error of "/media/sdb: Not a directory"
.
lsblk
shows:
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 447.1G 0 disk
└─sda1 8:1 0 447.1G 0 part /media/sda1
sdb 8:16 1 7.5G 0 disk /media/sdb
mmcblk0 179:0 0 7.3G 0 disk
├─mmcblk0p1 179:1 0 16M 0 part /media/mmcblk0p1
└─mmcblk0p2 179:2 0 7.3G 0 part /
mmcblk0boot0 179:8 0 4M 1 disk
mmcblk0boot1 179:16 0 4M 1 disk
mmcblk1 179:24 0 14.6G 0 disk
└─mmcblk1p1 179:25 0 14.6G 0 part /media/mmcblk1p1
Again, note no partition information for /dev/sdb
.
fdisk /dev/sdb
:
Disk /dev/sdb: 8053 MB, 8053063680 bytes
248 heads, 62 sectors/track, 1022 cylinders
Units = cylinders of 15376 * 512 = 7872512 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 124885 243005 908105142 72 Unknown
Partition 1 has different physical/logical beginnings (non-Linux?):
phys=(80, 13, 10) logical=(124884, 90, 21)
Partition 1 has different physical/logical endings:
phys=(371, 101, 51) logical=(243004, 44, 36)
Partition 1 does not end on cylinder boundary
/dev/sdb2 ? 125913 252971 976826554 6c Unknown
Partition 2 has different physical/logical beginnings (non-Linux?):
phys=(357, 43, 4) logical=(125912, 85, 11)
Partition 2 has different physical/logical endings:
phys=(367, 32, 52) logical=(252970, 235, 10)
Partition 2 does not end on cylinder boundary
/dev/sdb3 ? 1 1 0 0 Empty
Partition 3 has different physical/logical beginnings (non-Linux?):
phys=(0, 10, 0) logical=(0, 0, 1)
Partition 3 has different physical/logical endings:
phys=(0, 0, 0) logical=(279329, 74, 4)
Partition 3 does not end on cylinder boundary
/dev/sdb4 1803 1803 223+ 0 Empty
Partition 4 has different physical/logical beginnings (non-Linux?):
phys=(0, 0, 0) logical=(1802, 235, 1)
Partition 4 has different physical/logical endings:
phys=(0, 0, 0) logical=(1802, 242, 13)
Partition 4 does not end on cylinder boundary
I can delete all of the partitions using fdisk
and then create a new primary partition of type 7 (HPFS/NTFS)
fdisk /dev/sdb
Disk /dev/sdb: 8053 MB, 8053063680 bytes
248 heads, 62 sectors/track, 1022 cylinders
Units = cylinders of 15376 * 512 = 7872512 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 1022 7857105 7 HPFS/NTFS
Yet I still, I actually don’t have access to /dev/sdb1
to create a file system there…
lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 447.1G 0 disk
└─sda1 8:1 0 447.1G 0 part /media/sda1
sdb 8:16 1 7.5G 0 disk /media/sdb
mmcblk0 179:0 0 7.3G 0 disk
├─mmcblk0p1 179:1 0 16M 0 part /media/mmcblk0p1
└─mmcblk0p2 179:2 0 7.3G 0 part /
mmcblk0boot0 179:8 0 4M 1 disk
mmcblk0boot1 179:16 0 4M 1 disk
mmcblk1 179:24 0 14.6G 0 disk
└─mmcblk1p1 179:25 0 14.6G 0 part /media/mmcblk1p1
And its now that I keep going round in circles.
If I now connect the USB pen drive back to Windows, I can access the NTFS partition and read/write files again. When I plug the drive back into the Ixora carrier board, I now get:
lsblk
:
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 447.1G 0 disk
└─sda1 8:1 0 447.1G 0 part /media/sda1
sdc 8:32 1 7.5G 0 disk
└─sdc1 8:33 1 7.5G 0 part
mmcblk0 179:0 0 7.3G 0 disk
├─mmcblk0p1 179:1 0 16M 0 part /media/mmcblk0p1
└─mmcblk0p2 179:2 0 7.3G 0 part /
mmcblk0boot0 179:8 0 4M 1 disk
mmcblk0boot1 179:16 0 4M 1 disk
mmcblk1 179:24 0 14.6G 0 disk
└─mmcblk1p1 179:25 0 14.6G 0 part /media/mmcblk1p1
So, progress it would seem - nope. If I try and mount the /dev/sdc1
partition:
root@apalis-t30:~# mount -t ntfs-3g /dev/sdc1 /media/usb-drive/
ntfs-3g-mount: mount failed: Device or resource busy
And this is as far as I ever get. I’ve also tried using exFAT but the same issues apply.
Has anyone managed to successfully bring up and mount an NTFS partition and if so, could anyone share their tips and or processes? Thanks