Active Topics

 


Reply
Thread Tools
Posts: 395 | Thanked: 509 times | Joined on Jan 2011 @ Brisbane, Australia
#11
@knarf, autorun.inf isn't used for that

Just to be clear, I know how to fix the problem. I'm asking if anyone knows /why/ this happened/is happening (empty in windows, sdx/sdx1 in linux, both 27gb). I formatted it to ntfs, accidentally- I meant to format the sd card which was the same size.

CSSU 21.2011.38-1Tmaemo5.1, testing
 

The Following 2 Users Say Thank You to azkay For This Useful Post:
Posts: 1,808 | Thanked: 4,272 times | Joined on Feb 2011 @ Germany
#12
@azkay,

Could you run (as root) "sfdisk -l" and "cat /proc/mounts" with the USB cable unplugged?

Then plug the cable, select mass storage mode, and repeat the above commands (OK, without the sfdisk because it will give you the exact same results anyway).

Post here the output, please.
 

The Following 2 Users Say Thank You to reinob For This Useful Post:
Posts: 395 | Thanked: 509 times | Joined on Jan 2011 @ Brisbane, Australia
#13
Code:
Nokia-N900:~# sfdisk -l

Disk /dev/mmcblk1: 973968 cylinders, 4 heads, 16 sectors/track
Warning: The partition table looks like it was made
  for C/H/S=*/255/63 (instead of 973968/4/16).
For this listing I'll assume that geometry.
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/mmcblk1p1          0+   2860-   2860-  22970880    c  W95 FAT32 (LBA)
/dev/mmcblk1p2       2860+   3880-   1020-   8190976    b  W95 FAT32
/dev/mmcblk1p3          0       -       0          0    0  Empty
/dev/mmcblk1p4          0       -       0          0    0  Empty

Disk /dev/mmcblk0: 977024 cylinders, 4 heads, 16 sectors/track
Units = cylinders of 32768 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/mmcblk0p1          1  884864  884864   28315648    c  W95 FAT32 (LBA)
/dev/mmcblk0p2     884865  950400   65536    2097152   83  Linux
/dev/mmcblk0p3     950401  974976   24576     786432   82  Linux swap / Solaris
/dev/mmcblk0p4          0       -       0          0    0  Empty
Unplugged:
Code:
Nokia-N900:~# cat /proc/mounts
rootfs / rootfs rw 0 0
ubi0:rootfs / ubifs rw,bulk_read,no_chk_data_crc 0 0
proc /proc proc rw 0 0
sysfs /sys sysfs rw 0 0
tmpfs /tmp tmpfs rw,noatime,size=1024k 0 0
tmpfs /var/run tmpfs rw,nosuid,noatime,size=256k,mode=755 0 0
none /dev tmpfs rw,noatime,size=10240k,mode=755 0 0
devpts /dev/pts devpts rw,gid=5,mode=620 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev,noatime,size=65536k 0 0
/dev/mmcblk0p2 /home ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /opt ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
cgroup /syspart cgroup rw,freezer,memory,cpu 0 0
nodev /sys/kernel/debug debugfs rw 0 0
/dev/mmcblk0p2 /usr/lib/python2.5 ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/share/pyshared ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/lib/pyshared ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/share/python-support ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/lib/python-support ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk1p1 /media/mmc1 vfat rw,nosuid,nodev,noatime,nodiratime,uid=29999,fmask=0000,dmask=0000,allow_utime=0022,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,rodir,errors=remount-ro 0 0
/dev/mmcblk0p1 /home/user/MyDocs vfat ro,nosuid,nodev,noatime,nodiratime,uid=29999,fmask=0000,dmask=0000,allow_utime=0022,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,rodir,errors=remount-ro 0 0
Plugged:
Code:
Nokia-N900:~# cat /proc/mounts
rootfs / rootfs rw 0 0
ubi0:rootfs / ubifs rw,bulk_read,no_chk_data_crc 0 0
proc /proc proc rw 0 0
sysfs /sys sysfs rw 0 0
tmpfs /tmp tmpfs rw,noatime,size=1024k 0 0
tmpfs /var/run tmpfs rw,nosuid,noatime,size=256k,mode=755 0 0
none /dev tmpfs rw,noatime,size=10240k,mode=755 0 0
devpts /dev/pts devpts rw,gid=5,mode=620 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev,noatime,size=65536k 0 0
/dev/mmcblk0p2 /home ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /opt ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
cgroup /syspart cgroup rw,freezer,memory,cpu 0 0
nodev /sys/kernel/debug debugfs rw 0 0
/dev/mmcblk0p2 /usr/lib/python2.5 ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/share/pyshared ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/lib/pyshared ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/share/python-support ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
/dev/mmcblk0p2 /usr/lib/python-support ext3 rw,noatime,errors=continue,commit=1,data=writeback 0 0
Nokia-N900:~#
 

The Following 2 Users Say Thank You to azkay For This Useful Post:
pichlo's Avatar
Posts: 6,445 | Thanked: 20,981 times | Joined on Sep 2012 @ UK
#14
@azkay,
Your sdisk output looks legit to me.

FWIW, I've had a similar problem, only with my SD card. It blew up when I was trying to copy a large file to it (using a stand-alone card reader in Windows, not related to the N900). Eventually I put it to my N900 and reformatted in GParted. After that, my N900 could use it normally, but neithet Windows (XP) nor Linux (Debian Lenny) would recognize it as a valid partition. I ended up reformatting it again in Windows Explorer and now it seems to work fine.

My only explanation is that GParted created the FAT partition but did not actually initialize the sectors. It was OK for the N900 but a more fussy system like desktop Linux or Windows recognized there was something wrong and refused to mount the partition.

Of course, I may be talking utter BS
 

The Following 2 Users Say Thank You to pichlo For This Useful Post:
Posts: 1,808 | Thanked: 4,272 times | Joined on Feb 2011 @ Germany
#15
Originally Posted by azkay View Post
But if I mount, the partition is empty. If I SFTP, /home/user is empty also.
OK there are two issues here. When you say "if I mount, the partition is empty", does it mean plugging the N900 via USB in mass storage mode, or what exactly are mounting, and who is doing that? (you from N900, you from PC, PC automatically, etc.)

The second issue is weirder. If you can access /home/user (do you mean Mydocs or really /home/user, they are separate partitions) from your N900 (i.e. locally), you should be able to access it via SSH, as the N900 doesn't do anything (mount or unmount) when being accessed via SSH.

Given that your sfdisk and /proc/mounts output looks OK, I'd suggest you connect via SSH and then do cat /proc/mounts again and post the output here.

I'm assuming you're connecting via SSH using WLAN. If you're using bluetooth or USB or any other means, then please state that as well.
 

The Following User Says Thank You to reinob For This Useful Post:
Posts: 395 | Thanked: 509 times | Joined on Jan 2011 @ Brisbane, Australia
#16
I meant /home/user/MyDocs, but since then it works now over sftp so I don't know what it's problem was. When I say "mount", I >Mass Storage.

Last edited by azkay; 2012-10-25 at 23:38.
 

The Following User Says Thank You to azkay For This Useful Post:
Posts: 1,808 | Thanked: 4,272 times | Joined on Feb 2011 @ Germany
#17
@azkay,

OK, if the sftp is not an issue anymore (or was never an issue), then your problem is "only" that when you connect per USB using mass storage mode, your PC see an empty 27gb partition.

You said that under Linux you see everything OK if you mount /dev/sdb (i.e. the whole "disk"), whereas /dev/sdb1 doesn't give you anything (not even an error?).

When you connect per USB the N900 exposes MyDocs as a disk (e.g. /dev/sdb), but somehow both Windows and Linux are trying to be "smart" and attempt to mount /dev/sdb1, which doesn't make sense, unless gparted actually made a partition table *on a partition* (i.e. not in the MBR).

I think you should reformat your MyDocs with a sane program (i.e. nothing with a "g" or a "k" in its name). mkdosfs (in your N900) should deal with it just fine.
 

The Following User Says Thank You to reinob For This Useful Post:
Posts: 395 | Thanked: 509 times | Joined on Jan 2011 @ Brisbane, Australia
#18
It shall forever remain a mystery.
I just File Manager > N900 > Format'd.

All is well now.
 

The Following 2 Users Say Thank You to azkay For This Useful Post:
pichlo's Avatar
Posts: 6,445 | Thanked: 20,981 times | Joined on Sep 2012 @ UK
#19
Sorry to revive an old(ish) thread, but I have some observations and facts to add to this post of mine:

Originally Posted by pichlo View Post
I've had a similar problem, only with my SD card. It blew up when I was trying to copy a large file to it (using a stand-alone card reader in Windows, not related to the N900). Eventually I put it to my N900 and reformatted in GParted. After that, my N900 could use it normally, but neithet Windows (XP) nor Linux (Debian Lenny) would recognize it as a valid partition. I ended up reformatting it again in Windows Explorer and now it seems to work fine.
It turned out that I spoke too soon. My card only appeared to work fine (read: the N900 could read from and write to it properly, all my files were there etc). Until, that is, I plugged the phone to a USB port and tried to copy some files off the card to the PC. To my big surprise, they were not there! In Linux, the card appeared to contain only two files, autorun.inf and .n900.ico (both I put there immediately after the format as per above). In Windows, the card appeared unformatted. Unplug, kick off File Manager on the N900, all my files are there, but autorun.inf and .n900.ico are not!

To cut the long story short, I've figured out what the problem was. At some point before my last reformat, I partitioned the card. I do not remember whether I did it in a stand-alone card reader or in the N900, but the upshot is,

Code:
mount /dev/mmcblk1 /media/mmc1
showed one set of files (my files), while

Code:
mount /dev/mmcblk1p1 /media/mmc1
showed another (just the two files mentioned above). I guess the N900 is for some reason mounting the card as unpartitioned and the PC is mounting a partition on the card.

Unfortunately I did not figure it out until after I seriously screwed things up by trying to fixed them by running dosfsck on the card from the PC, so now I have a few days' worth of work to get my files back, but that's a different story.

I wonder if the OP's problem was caused by something similar.
 

The Following 2 Users Say Thank You to pichlo For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 06:46.