View Single Post
Posts: 132 | Thanked: 40 times | Joined on Jan 2013 @ Nairobi Kenya
#21
Originally Posted by michaaa62 View Post
To make things clear: You lost all of your data and settings through this mess!

Now in rd mode:
You have to correct the partition table.
Code:
sudo gainroot
echo "unit: sectors
> /dev/mmcblk0p1 : start= 64, size= 44400640, Id=0
> /dev/mmcblk0p2 : start=44744704, size= 16211968, Id=0
> /dev/mmcblk0p3 : start= 60956672, size=  1572864, Id=82
> /dev/mmcblk0p4 : start=        0, size=        0, Id= 0 " > table
sfdisk --no-reread /dev/mmcblk0 < table
These are three commands:
#1 sudo ... to gain the rights you might drop this in rd-mode
#2 echo ... over those 5 lines to create a file containing the informations for the partition table
#3 sfdisk ... dumps the file's content to the partition table part of the MBR.
This will create a 23GB MyDocs partition, a 8GB partition for installable applications (and plenty of space for nitdroid ) and a 750MB swap space.

Then reboot to check if the partition table is written correctly.

After the reboot check the partition table
Code:
sudo gainroot
sfdisk -l
If the values are correct, make the partitions active and apply file systems
Code:
sfdisk -c /dev/mmcblk0 1 c
mkfs.vfat -F32 -s64 -n MyDocs /dev/mmcblk0p1
sfdisk -c /dev/mmcblk0 2 83
mkfs.ext3 -L optfs /dev/mmcblk0p2
Now you are set to flash the firmware and use your partitions
I tried the codes first before flashing my emmc; and on the steps to ammend the table, all went well with no errors, but on restarting and querying the table, its the same as I had sent via my second last post.
I ignored the fact that there is no change and went on with the code;
sfdisk -c /dev/mmcblk0 1 c - g - gave this, "mkfs.vfat 3.0.1 (23 Nov 2008)
/dev/mmcblk0p1: No such file or directory"
This mkfs.ext3 -L optfs /dev/mmcblk0p2 gave "could not stat /dev/mmcblk0p2 --- no such file or directory.
The device apparently does not exist; did you specify it correctly?"

This is my output....