Transcend 2GB 133X CF card -------------------------- 14-mar-2014 ----------- Card may have been reformatted with windows version of mkdosfs during the first CF tests. At the time we may have had problems with the power supply monitor. The card was re-formatted using a minolta D7 camera Where is the device [philippe@toad-sl61 ~]$ df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/vg_toadsl61-lv_root 16G 3.9G 11G 27% / tmpfs 947M 568K 947M 1% /dev/shm /dev/sda1 485M 74M 386M 17% /boot /dev/sdb1 1.9G 36M 1.9G 2% /media/disk Look at partition [root@toad-sl61 ~]# fdisk /dev/sdb WARNING: DOS-compatible mode is deprecated. It's strongly recommended to switch off the mode (command 'c') and change display units to sectors (command 'u'). Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 * 1 244 1957000+ 6 FAT16 Partition 1 has different physical/logical endings: phys=(1023, 254, 63) logical=(243, 162, 63) Re-partition Command (m for help): d Selected partition 1 Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-243, default 1): Using default value 1 Last cylinder, +cylinders or +size{K,M,G} (1-243, default 243): Using default value 243 Command (m for help): t Selected partition 1 Hex code (type L to list codes): 6 Changed system type of partition 1 to 6 (FAT16) Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: Re-reading the partition table failed with error 16: Device or resource busy. The kernel still uses the old table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8) WARNING: If you have created or modified any DOS 6.x partitions, please see the fdisk manual page for additional information. Syncing disks. Re-format [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 16 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) WARNING: Not enough clusters for a 16 bit FAT! The filesystem will be misinterpreted as having a 12 bit FAT without mount option "fat=16". mkdosfs: Too many clusters for filesystem - try more sectors per cluster [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 32 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) WARNING: Not enough clusters for a 16 bit FAT! The filesystem will be misinterpreted as having a 12 bit FAT without mount option "fat=16". mkdosfs: Too many clusters for filesystem - try more sectors per cluster [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 64 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) /dev/sdb1 has 255 heads and 63 sectors per track, hidden sectors 0x003f; logical sector size is 512, using 0xf8 media descriptor, with 3914001 sectors; drive number 0x80; filesystem has 2 16-bit FATs and 64 sectors per cluster. FAT size is 256 sectors, and provides 61147 clusters. There is 1 reserved sector. Root directory contains 1024 slots and uses 64 sectors. Volume ID is 7932c189, no volume label. Look at result [root@toad-sl61 ~]# dosfsck -v /dev/sdb1 dosfsck 3.0.9 (31 Jan 2010) dosfsck 3.0.9, 31 Jan 2010, FAT32, LFN Checking we can access the last sector of the filesystem Boot sector contents: System ID "mkfs.fat" Media byte 0xf8 (hard disk) 512 bytes per logical sector 32768 bytes per cluster 1 reserved sector First FAT starts at byte 512 (sector 1) 2 FATs, 16 bit entries 131072 bytes per FAT (= 256 sectors) Root directory starts at byte 262656 (sector 513) 1024 root directory entries Data area starts at byte 295424 (sector 577) 61147 data clusters (2003664896 bytes) 63 sectors/track, 255 heads 63 hidden sectors 3914001 sectors total Checking for unused clusters. /dev/sdb1: 0 files, 0/61147 clusters from Windows copy CMX ACE config files 17-mar-2014 ----------- Try in CMX power up --> no configuration happen with power on, pull out and re-plug CF card --> both BF ant TP configure from Windows 2,003,664,896 bytes (1.86 GB) capacity 37,093.376 bytes (35.3 MB) used from Linux Where is it [philippe@toad-sl61 ~]$ df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/vg_toadsl61-lv_root 16G 3.9G 11G 27% / tmpfs 947M 568K 947M 1% /dev/shm /dev/sda1 485M 74M 386M 17% /boot /dev/sdb1 1.9G 36M 1.9G 2% /media/7932-C189 Dismount [philippe@toad-sl61 ~]$ umount /dev/sdb1 Re-partition to full size [root@toad-sl61 ~]# fdisk /dev/sdb WARNING: DOS-compatible mode is deprecated. It's strongly recommended to switch off the mode (command 'c') and change display units to sectors (command 'u'). Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 243 1951866 6 FAT16 Command (m for help): d Selected partition 1 Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-243, default 1): Using default value 1 Last cylinder, +cylinders or +size{K,M,G} (1-243, default 243): Using default value 243 Command (m for help): t Selected partition 1 Hex code (type L to list codes): 6 Changed system type of partition 1 to 6 (FAT16) Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: If you have created or modified any DOS 6.x partitions, please see the fdisk manual page for additional information. Syncing disks. [root@toad-sl61 ~]# fdisk /dev/sdb WARNING: DOS-compatible mode is deprecated. It's strongly recommended to switch off the mode (command 'c') and change display units to sectors (command 'u'). Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 243 1951866 6 FAT16 Command (m for help): q Re-format [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 64 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) /dev/sdb1 has 255 heads and 63 sectors per track, hidden sectors 0x003f; logical sector size is 512, using 0xf8 media descriptor, with 3903732 sectors; drive number 0x80; filesystem has 2 16-bit FATs and 64 sectors per cluster. FAT size is 256 sectors, and provides 60986 clusters. There is 1 reserved sector. Root directory contains 1024 slots and uses 64 sectors. Volume ID is 42884e03, no volume label. from Windows 1,998,389,248 bytes (1.86 GB) capacity 0 bytes used copy ACE files 18-mar-2014 ----------- Tried on CMX, did not work on power up, but did work on re-insert Try re-partitioning to a smaller size (from linux MSUL1C) Where is the device? [root@msul1c ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/vg_msul1c-lv_root 50G 44G 3.3G 93% / tmpfs 7.8G 88K 7.8G 1% /dev/shm /dev/sda1 485M 94M 366M 21% /boot /dev/mapper/vg_msul1c-lv_home 405G 22G 364G 6% /home AFS 8.6G 0 8.6G 0% /afs /dev/sdb1 1.9G 36M 1.9G 2% /media/6D46-AC04 [root@msul1c ~]# umount /dev/sdb1 Re-partition [root@msul1c ~]# fdisk /dev/sdb WARNING: DOS-compatible mode is deprecated. It's strongly recommended to switch off the mode (command 'c') and change display units to sectors (command 'u'). Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 243 1951866 6 FAT16 Command (m for help): d Selected partition 1 Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-243, default 1): Using default value 1 Last cylinder, +cylinders or +size{K,M,G} (1-243, default 243): 50 Command (m for help): t Selected partition 1 Hex code (type L to list codes): 6 Changed system type of partition 1 to 6 (FAT16) Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 50 401593+ 6 FAT16 Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: If you have created or modified any DOS 6.x partitions, please see the fdisk manual page for additional information. Syncing disks. Re-format [root@msul1c ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 8 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) WARNING: Not enough clusters for a 16 bit FAT! The filesystem will be misinterpreted as having a 12 bit FAT without mount option "fat=16". mkdosfs: Too many clusters for filesystem - try more sectors per cluster [root@msul1c ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 16 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) /dev/sdb1 has 255 heads and 63 sectors per track, hidden sectors 0x003f; logical sector size is 512, using 0xf8 media descriptor, with 803187 sectors; drive number 0x80; filesystem has 2 16-bit FATs and 16 sectors per cluster. FAT size is 208 sectors, and provides 50171 clusters. There is 1 reserved sector. Root directory contains 512 slots and uses 32 sectors. Volume ID is 1c525ba2, no volume label. Look at the result [root@msul1c ~]# dosfsck -v /dev/sdb1 fsck.fat 3.0.26 (2014-03-07) fsck.fat 3.0.26 (2014-03-07) Checking we can access the last sector of the filesystem Boot sector contents: System ID "mkfs.fat" Media byte 0xf8 (hard disk) 512 bytes per logical sector 8192 bytes per cluster 1 reserved sector First FAT starts at byte 512 (sector 1) 2 FATs, 16 bit entries 106496 bytes per FAT (= 208 sectors) Root directory starts at byte 213504 (sector 417) 512 root directory entries Data area starts at byte 229888 (sector 449) 50171 data clusters (411000832 bytes) 63 sectors/track, 255 heads 63 hidden sectors 803187 sectors total Checking for unused clusters. /dev/sdb1: 0 files, 0/50171 clusters That's 391 MB Tried on CMX, still did not work on power up 25-Mar-2014 ----------- man fdisk -b sectorsize Specify the sector size of the disk. Valid values are 512, 1024, 2048 or 4096. (Recent kernels know the sector size. Use this only on old kernels or to override the kernel’s ideas.) Since util-linux-ng 2.17 fdisk differenti- ates between logical and physical sector size. This option changes both sec- tor sizes to sectorsize. -h Print help and then exit. -c Switch off DOS-compatible mode. (Recommended) -C cyls Specify the number of cylinders of the disk. I have no idea why anybody would want to do so. -H heads Specify the number of heads of the disk. (Not the physical number, of course, but the number used for partition tables.) Reasonable values are 255 and 16. -S sects Specify the number of sectors per track of the disk. (Not the physical num- ber, of course, but the number used for partition tables.) A reasonable value is 63. -l List the partition tables for the specified devices and then exit. If no devices are given, those mentioned in /proc/partitions (if that exists) are used. -u When listing partition tables, give sizes in sectors instead of cylinders. -s partition The size of the partition (in blocks) is printed on the standard output. -v Print version number of fdisk program and exit. Can we really specify the number of heads? [root@toad-sl61 ~]# fdisk -l /dev/sdb Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 50 401593+ 6 FAT16 [root@toad-sl61 ~]# fdisk -cl /dev/sdb Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 50 401593+ 6 FAT16 [root@toad-sl61 ~]# fdisk -cul /dev/sdb Disk /dev/sdb: 2004 MB, 2004516864 bytes 255 heads, 63 sectors/track, 243 cylinders, total 3915072 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 63 803249 401593+ 6 FAT16 [root@toad-sl61 ~]# fdisk -cul -H 16 /dev/sdb Disk /dev/sdb: 2004 MB, 2004516864 bytes 16 heads, 63 sectors/track, 3884 cylinders, total 3915072 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 63 803249 401593+ 6 FAT16 [root@toad-sl61 ~]# fdisk -cul -H 16 S 63 /dev/sdb Disk /dev/sdb: 2004 MB, 2004516864 bytes 16 heads, 63 sectors/track, 3884 cylinders, total 3915072 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 63 803249 401593+ 6 FAT16 Ok, re-partition with 1st partion roughly 1/4 of device [root@toad-sl61 ~]# fdisk -cu -H 16 -S 63 /dev/sdb Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 16 heads, 63 sectors/track, 3884 cylinders, total 3915072 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 63 803249 401593+ 6 FAT16 Command (m for help): d Selected partition 1 Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 16 heads, 63 sectors/track, 3884 cylinders, total 3915072 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First sector (2048-3915071, default 2048): 1 Value out of range. First sector (2048-3915071, default 2048): Using default value 2048 Last sector, +sectors or +size{K,M,G} (2048-3915071, default 3915071): 900000 Command (m for help): t Selected partition 1 Hex code (type L to list codes): 6 Changed system type of partition 1 to 6 (FAT16) Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 16 heads, 63 sectors/track, 3884 cylinders, total 3915072 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 2048 900000 448976+ 6 FAT16 Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: If you have created or modified any DOS 6.x partitions, please see the fdisk manual page for additional information. Syncing disks. Re-format [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 8 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) WARNING: Not enough clusters for a 16 bit FAT! The filesystem will be misinterpreted as having a 12 bit FAT without mount option "fat=16". mkdosfs: Too many clusters for filesystem - try more sectors per cluster [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 16 -r 512 -v /dev/sdb1 mkfs.fat 3.0.26 (2014-03-07) /dev/sdb1 has 62 heads and 62 sectors per track, hidden sectors 0x0800; logical sector size is 512, using 0xf8 media descriptor, with 897953 sectors; drive number 0x80; filesystem has 2 16-bit FATs and 16 sectors per cluster. FAT size is 224 sectors, and provides 56092 clusters. There is 1 reserved sector. Root directory contains 512 slots and uses 32 sectors. Volume ID is bb75dbb0, no volume label. What does it look like? [root@toad-sl61 ~]# dosfsck -v /dev/sdb1 dosfsck 3.0.9 (31 Jan 2010) dosfsck 3.0.9, 31 Jan 2010, FAT32, LFN Checking we can access the last sector of the filesystem Boot sector contents: System ID "mkfs.fat" Media byte 0xf8 (hard disk) 512 bytes per logical sector 8192 bytes per cluster 1 reserved sector First FAT starts at byte 512 (sector 1) 2 FATs, 16 bit entries 114688 bytes per FAT (= 224 sectors) Root directory starts at byte 229888 (sector 449) 512 root directory entries Data area starts at byte 246272 (sector 481) 56092 data clusters (459505664 bytes) 62 sectors/track, 62 heads 2048 hidden sectors 897953 sectors total Checking for unused clusters. /dev/sdb1: 0 files, 0/56092 clusters Note that it is not 16 heads but 62 heads from Windows 459,505,664 bytes (438 MB) capacity 0 bytes used copy ACE files 36,970,496 bytes used from Linux [philippe@toad-sl61 ~]$ df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/vg_toadsl61-lv_root 16G 4.0G 11G 28% / tmpfs 947M 376K 947M 1% /dev/shm /dev/sda1 485M 74M 386M 17% /boot /dev/sdb1 439M 36M 403M 9% /media/BB75-DBB0 What deos the partition look like now with no prodding [root@toad-sl61 ~]# fdisk -l /dev/sdb Disk /dev/sdb: 2004 MB, 2004516864 bytes 14 heads, 46 sectors/track, 6079 cylinders Units = cylinders of 644 * 512 = 329728 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 4 1398 448976+ 6 FAT16 Note this is showing 14 heads and 46 sectors per track Tested on CMX: still no automatic configuration at power up 31-Mar-2014 ----------- Try to format the whole device without a partition table Delete the partition table [root@toad-sl61 ~]# fdisk /dev/sdb WARNING: DOS-compatible mode is deprecated. It's strongly recommended to switch off the mode (command 'c') and change display units to sectors (command 'u'). Command (m for help): p Disk /dev/sdb: 2004 MB, 2004516864 bytes 14 heads, 46 sectors/track, 6079 cylinders Units = cylinders of 644 * 512 = 329728 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 4 1398 448976+ 6 FAT16 Command (m for help): d Selected partition 1 Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. Syncing disks. Format whole card [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 16 -r 512 -v /dev/sdb mkfs.fat 3.0.26 (2014-03-07) mkdosfs: Device partition expected, not making filesystem on entire device '/dev/sdb' (use -I to override) Override default [root@toad-sl61 ~]# mkdosfs -f 2 -F 16 -R 1 -S 512 -s 64 -r 512 -v -I /dev/sdb mkfs.fat 3.0.26 (2014-03-07) /dev/sdb has 62 heads and 62 sectors per track, hidden sectors 0x0000; logical sector size is 512, using 0xf8 media descriptor, with 3915072 sectors; drive number 0x80; filesystem has 2 16-bit FATs and 64 sectors per cluster. FAT size is 256 sectors, and provides 61163 clusters. There is 1 reserved sector. Root directory contains 1024 slots and uses 64 sectors. Volume ID is ff62f763, no volume label. Check outcome [root@toad-sl61 ~]# dosfsck -v /dev/sdb dosfsck 3.0.9 (31 Jan 2010) dosfsck 3.0.9, 31 Jan 2010, FAT32, LFN Checking we can access the last sector of the filesystem Boot sector contents: System ID "mkfs.fat" Media byte 0xf8 (hard disk) 512 bytes per logical sector 32768 bytes per cluster 1 reserved sector First FAT starts at byte 512 (sector 1) 2 FATs, 16 bit entries 131072 bytes per FAT (= 256 sectors) Root directory starts at byte 262656 (sector 513) 1024 root directory entries Data area starts at byte 295424 (sector 577) 61163 data clusters (2004189184 bytes) 62 sectors/track, 62 heads 0 hidden sectors 3915072 sectors total Checking for unused clusters. /dev/sdb: 0 files, 0/61163 clusters from Windows 2,004,189,184 bytes (1.86 GB) capacity 0 bytes used copy ACE files 37,093,376 bytes (35.3 MB) used from Linux [philippe@toad-sl61 ~]$ df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/vg_toadsl61-lv_root 16G 4.0G 11G 28% / tmpfs 947M 568K 947M 1% /dev/shm /dev/sda1 485M 75M 385M 17% /boot /dev/sdb 1.9G 36M 1.9G 2% /media/FF62-F763 There is no difference: no config on power up, but config on hot swap.