Author Topic: New versions of fdisk and e2fsprogs  (Read 21148 times)

TonyOlsen

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
    • http://www.userdimensions.com/Tony/Resume.html
New versions of fdisk and e2fsprogs
« Reply #60 on: September 27, 2004, 03:08:26 pm »
I repartitioned the drive with only 1 100MB partition just to see if size was an issue.  The card still acted the same way it did before.

I just read your posts above.  I'll try those out and post the results.,

(Thanks  )
Tony Olsen
Ferris@Myself.Com
Resume
Zaurus SL-C860 QTopia
2 GB Static CF
1 GB MMC (although it isn't working yet)
My Quest: To get an x86 emulator working on my Zaurus and to have my Zaurus replace my laptop as my MAIN computer
Publically available Videos for the default Zaurus SL-C860 video player

TonyOlsen

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
    • http://www.userdimensions.com/Tony/Resume.html
New versions of fdisk and e2fsprogs
« Reply #61 on: September 27, 2004, 03:36:22 pm »
I'm still trying the stuff you mentioned.  I reformated using File System Type #4 "FAT16 <16MB" (eventhough I have 1024 MB).  All of the old test directories I had made all appeared back on the list.  (How do you "format" a drive and whipe the file allocation table clean?... mkfs.msdos didn't appear to do that).

The same problems as before.

One thing I noticed, though... the Documents directory points to itself.  I don't think it's a symlink, but instead it appears to be some form of corruption in the FAT table.  doing things like "find -name blah" will finally error out because "/Documents/Documents/Documents/ ... /Documents" is too long of a path name.  Could this be the cause of the freezing up?  (OS attempts to write data to the Documents directory and is never able to due to the infinite loop).

How do you wipe a FAT clean of its history?

I'm getting the other tests...
Tony Olsen
Ferris@Myself.Com
Resume
Zaurus SL-C860 QTopia
2 GB Static CF
1 GB MMC (although it isn't working yet)
My Quest: To get an x86 emulator working on my Zaurus and to have my Zaurus replace my laptop as my MAIN computer
Publically available Videos for the default Zaurus SL-C860 video player

iamasmith

  • Hero Member
  • *****
  • Posts: 1248
    • View Profile
New versions of fdisk and e2fsprogs
« Reply #62 on: September 27, 2004, 04:06:11 pm »
OK Tony,

I think this is getting conclusive, either there's a problem with your SD/MMC slot or there's a driver issue with this card.

Don't suppose you have another card you can try with the Z to rule out the possibility of a duff SD slot ?

- Andy
« Last Edit: September 27, 2004, 04:06:37 pm by iamasmith »
OpenBSD 4.2 -current on full 4Gb of SL-C3000
Microdrive replaced with 4Gb SanDisk Extreme III card

TonyOlsen

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
    • http://www.userdimensions.com/Tony/Resume.html
New versions of fdisk and e2fsprogs
« Reply #63 on: September 27, 2004, 05:30:38 pm »
The card works fine from windows, so I would venture that it isn't the card itself.
Tony Olsen
Ferris@Myself.Com
Resume
Zaurus SL-C860 QTopia
2 GB Static CF
1 GB MMC (although it isn't working yet)
My Quest: To get an x86 emulator working on my Zaurus and to have my Zaurus replace my laptop as my MAIN computer
Publically available Videos for the default Zaurus SL-C860 video player

TonyOlsen

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
    • http://www.userdimensions.com/Tony/Resume.html
New versions of fdisk and e2fsprogs
« Reply #64 on: September 27, 2004, 05:53:27 pm »
Hm... you mentioned "cf", but I assumed you mean't "card".  Let me know if you wanted me to take you literally there or not...

Code: [Select]
# mount /mnt/card
mount: Mounting /dev/mmcda1 on /mnt/card failed: Device or resource busy
# mount
/dev/root on / type jffs2 (ro)
/proc on /proc type proc (rw)
/dev/ram1 on /dev type minix (rw)
/dev/mtdblock3 on /home type jffs2 (rw,noatime)
none on /dev/shm type tmpfs (rw)
none on /dev/pts type devpts (rw)
/dev/mmcda1 on /usr/mnt.rom/card type vfat (rw)
# cd /
# touch /mnt/card/testfile    
# mkdir /mnt/card/testdir
# touch /mnt/card/testfile2
touch: /mnt/card/testfile2: Read-only file system
# ls -rtl /mnt/card
lrwxrwxrwx    1 root     root           17 Nov 27  2003 /mnt/card -> /usr/mnt.rom/card
# mkdir /mnt/card/testdir2
mkdir: Cannot create directory `/mnt/card/testdir2': Read-only file system
# umount /mnt/card
# mount /mnt/card  
Tony Olsen
Ferris@Myself.Com
Resume
Zaurus SL-C860 QTopia
2 GB Static CF
1 GB MMC (although it isn't working yet)
My Quest: To get an x86 emulator working on my Zaurus and to have my Zaurus replace my laptop as my MAIN computer
Publically available Videos for the default Zaurus SL-C860 video player

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
New versions of fdisk and e2fsprogs
« Reply #65 on: September 27, 2004, 06:47:57 pm »
Yeah sorry for the confusion.

I'm afraid I'm out of suggestions.

The only other thing I can add is that when using pdaXrom (and I think Cacko also to an extent) I used to get io errors on my mmc card when trying to install stuff (making dirs, etc.). This has *never* happened to me using OZ. I've no idea what's different between the two but I presume there's something.

I'm running OZ on my 5500 and 750 so if I can give you any info to compare I'm more than glad to help out.

Sorry I can't be of more help,


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

Yasen

  • Full Member
  • ***
  • Posts: 107
    • View Profile
    • http://
New versions of fdisk and e2fsprogs
« Reply #66 on: September 28, 2004, 04:52:56 am »
Tony If I were you I would make this:
Code: [Select]
#umount /mnt/card
#mkfs.msdos  /dev/mmcda
#fdisk /dev/mmcda
Create new empty dos partition table and new partition
Code: [Select]
#mkfs.msdos  /dev/mmcda1
#mount /mnt/card
I think this will wipe fat tables and if that is the problem you'll have a ok MMC card.
Just an idea don't know if it is good or bad someone of the gurus must say.
[span style=\'font-size:8pt;line-height:100%\']SL-5600 PXA-250
noname 256 MB MMC fat,
SanDisk 1GB  CF vfat
[/span]

kopsis

  • Sr. Member
  • ****
  • Posts: 329
    • View Profile
    • http://kopsisengineering.com
New versions of fdisk and e2fsprogs
« Reply #67 on: September 28, 2004, 08:25:59 am »
Quote
How do you wipe a FAT clean of its history?
If you want to *really* start over from scratch, you may want to try the following:

Code: [Select]
$ su
# umount /dev/mmcda1
# dd if=/dev/zero of=/dev/mmcda bs=512 count=20480

That last command will overwrite the first 10MiB of the card with zeros, thoroughly destroying what's left of your MSDOS filesystem. Be prepared for the command to take several minutes (i.e. make sure you're running on AC power and have timed power off set to a large timeout).

If the dd command fails to complete, then you have a hardware/driver problem and no amount of fdisk/mkfs work is going to help. If the dd command succeeds, then partitioning/reformatting should work at that point.

TonyOlsen

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
    • http://www.userdimensions.com/Tony/Resume.html
New versions of fdisk and e2fsprogs
« Reply #68 on: September 28, 2004, 01:43:11 pm »
Instead what I did is repartitioned the disk and had that new partition start at cylinder 2 instead of 1 (wasting the first cylinder).  Now there aren't any directories... but it's still back to the same old problem.

I'm guessing it's some driver issue.
Tony Olsen
Ferris@Myself.Com
Resume
Zaurus SL-C860 QTopia
2 GB Static CF
1 GB MMC (although it isn't working yet)
My Quest: To get an x86 emulator working on my Zaurus and to have my Zaurus replace my laptop as my MAIN computer
Publically available Videos for the default Zaurus SL-C860 video player

iamasmith

  • Hero Member
  • *****
  • Posts: 1248
    • View Profile
New versions of fdisk and e2fsprogs
« Reply #69 on: September 29, 2004, 04:39:30 am »
OK, that was an interesting portion of the thread, sorry we couldn't help out more Tony.

My main reason for updating these tools was to see if we could effect a positive outcome for people with 'dead cards'.

Unofrtunately it seems that the problem is a little more fundamental and could be either driver related or something related to spec of card/card reader in Z (write voltage for card ?, clocking discrepency ?).

Anyway the tools do seem better at a couple of things, sizing large cards - getting the geometry right and maintaining ext3 file systems.

I think Tony's case illustrates, however, that you still need to be careful with your choice of card and your decision as to format it/repartition it or not.

- Andy
OpenBSD 4.2 -current on full 4Gb of SL-C3000
Microdrive replaced with 4Gb SanDisk Extreme III card

TonyOlsen

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
    • http://www.userdimensions.com/Tony/Resume.html
New versions of fdisk and e2fsprogs
« Reply #70 on: September 30, 2004, 04:48:21 pm »
Yasen, I tried your idea...

Code: [Select]
bash-2.05$ su
# umount /mnt/card
# mkfs.msdos  /dev/mmcda
mkfs.msdos 2.8 (28 Feb 2001)
mkfs.msdos: Attempting to create a too large file system
# fdisk /dev/mmcda  
Unable to read /dev/mmcda
#        

I'll try more later...
Tony Olsen
Ferris@Myself.Com
Resume
Zaurus SL-C860 QTopia
2 GB Static CF
1 GB MMC (although it isn't working yet)
My Quest: To get an x86 emulator working on my Zaurus and to have my Zaurus replace my laptop as my MAIN computer
Publically available Videos for the default Zaurus SL-C860 video player

iamasmith

  • Hero Member
  • *****
  • Posts: 1248
    • View Profile
New versions of fdisk and e2fsprogs
« Reply #71 on: November 22, 2004, 02:17:30 pm »
*BUMP*

Offroad geek, do you think this may be better on the download section ?

- Andy
OpenBSD 4.2 -current on full 4Gb of SL-C3000
Microdrive replaced with 4Gb SanDisk Extreme III card

cavit8

  • Newbie
  • *
  • Posts: 48
    • View Profile
    • http://
New versions of fdisk and e2fsprogs
« Reply #72 on: January 05, 2005, 11:24:12 pm »
I've read this thread over after bricking a 256M Sandisk SD card.  I think I did it by suspending the zaurus before the card had finished loading.

I keep getting an error 'Attempting to create a too large file system' regardless if I use mkfs.msdos or .vfat.  I think it may be how I'm trying to size the partition.  How would I go about formatting the card for 256M?  Using the defaults (1-976) doesn't work.  I've also tried inputting +255M (256 gives me an error).

I also get an additional message when first running fdisk
'Warning: invalid flac 0x0000 of partition table 4 will be corrected by w(rite).

Any suggestions would be helpful

(Sharp 3.1, fdisk v2.12a)
Zaurus 5500
Sharp 3.1
SD 256M
Big box: Zenwalk 1.2

kopsis

  • Sr. Member
  • ****
  • Posts: 329
    • View Profile
    • http://kopsisengineering.com
New versions of fdisk and e2fsprogs
« Reply #73 on: January 06, 2005, 06:56:48 am »
Sounds like your partition table is hosed. You might want to try the following command (as root) to zero out the card's partition table:
Code: [Select]
dd if=/dev/zero of=/dev/mmcda bs=512 count=1After that you should be able to use fdisk (on /dev/mmcda) to create a "primary" partition, set its type, and save the partition table. Then you can mkfs.* on /dev/mmcda1 (your new partition) and it should work.

The thing that sometimes trips folks up is that the target for the fdisk and dd commands above is /dev/mmcda but the target for the mkfs.* commands is /dev/mmcda1.

cavit8

  • Newbie
  • *
  • Posts: 48
    • View Profile
    • http://
New versions of fdisk and e2fsprogs
« Reply #74 on: January 06, 2005, 09:09:08 am »
Hi Kopsis

I had actually done that from your previous post using

Code: [Select]
dd if=/dev/zero of=/dev/mmcda bs=512 count=20480
with no joy.  I don't have the offending card with me at work, but I'll play around with it a bit more when I get home.

I'll document the sequence of steps I've taken a little more clearly than I did in my preceding post.
Zaurus 5500
Sharp 3.1
SD 256M
Big box: Zenwalk 1.2