[Instructions included] Need Internal Partitions (mmcblk0p1 to mmcblk0p5) - One (M8) Q&A, Help & Troubleshooting

I've been trying to partition my External SD card so I can use it for Link2SD. I don't have an SD card reader so I tried using the adb + parted command. I was following this tutorial but then I realised that /dev/block/mmcblk0 was my Internal Storage and not my external SD. I deleted the first 5 partitions on there and my phone isn't charging nor turning on even though it's fully charged. Have I completely broken my phone?
Edit: phone shows up as QHSUSB_BULK in device manager.
Could someone please upload the first 5 partitions as imgs? I'm trying to use Ubuntu to try and replace the partitions I deleted. I'm running 4.16.1540.8 as my firmware and CM12 nightlies.
Use this command to save partitions as imgs on SD.
dd if=/dev/block/mmcblk0p5 of=/sdcard/dump/mfg.img
Just replace the mmc number with 1,2,3,4,5 and the image name to something that lets me know which partition it's on.
Thanks

bump

did you have any joy getting the mmcblk0 and if so can you upload it please

Related

problem removing partitions

I have app2sd setup and due to some issue (perhaps unrelated) i want to remove it.
i've booted in to recovery and gone in to ADB shell and loaded up parted. when i do a print i see my 3 partitions. i use RM to remove them and i dont get any errors, just dumps back to the prompt. i do a print again and see no change.
I tried using the recover partition tool, but it doesnt work as well. i found a log and its doing the same thing i did by hand.
from recovery i mounted the SD to USB and tried to do it from there as well with disk manager and diskpart. with diskpart i never got any errors deleting, but, it didnt delete. with disk manager i could remove the ext and swap fine but not the fat, i just wasnt given the option.
is there some sort of lock or something im missing?
Its this program for windows i used it formats your sd card. I cant rememb er the name but i googled how to unpartition a micro sd card. Hope that helps a bit.
Sent from my PC36100 using XDA App
i wasnt able to find anything that did a full wipe of the SD. just format utilities that work with the already created partitions.
thanks

Partitions on Internal Storage

Dear ALL,
I have problem in restoring original partitions on my DIAMOND.
I've tried ANDROID (still pretty slow) on EXT2 partiton created on Internal Storage, but i want to restore original partitions.
I thought that there was only 1 FAT32 partition for all the storage so I did that, but when i did so i'm unable to flash ROMS from Internal Storage. It says "No Image File!" and trigers USB flashing.
Could some one please explore your dimond in partitioning tool and paste screenshots with original info (number of partitions, type of partitons, filesystem)?
Thank you
Actually, there is only one partition and it worked just fine for me. I used Minitool Partition Magic Home and it worked just fine.
Just delete the scrambled name partition in there,create a new one with fat32 and full space and name it to whatever you want and wait for it to finish.
After removing the cable, try rebooting the phone and plugging it in with the "Disk drive" option activated. The partition should show up.
jkayser said:
Dear ALL,
I have problem in restoring original partitions on my DIAMOND.
I've tried ANDROID (still pretty slow) on EXT2 partiton created on Internal Storage, but i want to restore original partitions.
I thought that there was only 1 FAT32 partition for all the storage so I did that, but when i did so i'm unable to flash ROMS from Internal Storage. It says "No Image File!" and trigers USB flashing.
Could some one please explore your dimond in partitioning tool and paste screenshots with original info (number of partitions, type of partitons, filesystem)?
Thank you
Click to expand...
Click to collapse
Originally there's only one FAT32 partition,but sometimes the phone wouldn't recognize it,that happened to me too,download HP Usb Format Tool (you can google it,you'll find it certainly),Then with it you have to format the internal storage to fat32,it fixed for me

[Q] Cannot Partition SD ext

Hi Guys, bought a sandisk 16 GB Card, i am trying to format the various partitions so far:
1. Using Clockwork it creates an unrecognised partition after FAT Partition
2. Tried Ubuntu - will format whole card in either FAT or EXT 2/3/4 but will not create an ext after the FAT Partition (again unknown partition format after FAT)
3. Tried minitool partition manager - Can fortmat whole card in either fat or EXT. Cannot create an EXT after FAT - Unknown partition format
4. Tried ADB, will create primary partition 1 but not an ext partition after
Card id new and i believe genuine
any help greatly appreciated
Well I use gparted boot cd and works fine
Sent from my HTC Desire using Tapatalk
ironjon said:
Well I use gparted boot cd and works fine
Sent from my HTC Desire using Tapatalk
Click to expand...
Click to collapse
+1
Otherwise flash amonra-recovery, create an ext2-partiton and upgrade this to an ext3-partition with this recovery.
Sent from my HTC Desire using XDA App
Have you tried Rom Manager? I used that to partition my 16GB sandisk
I used Ubuntu and it worked fine. Did you unmount the partitions in Ubuntu ?
Did you format the partition after you've created it ?
paul.c said:
I used Ubuntu and it worked fine. Did you unmount the partitions in Ubuntu ?
Did you format the partition after you've created it ?
Click to expand...
Click to collapse
Hi, thanks for the replies, yes i unmounted in ubuntu but i seem to only be able to create one (working) ext partition but it has to be the full card, or multiple Fat partitions. When i create an ext after the FAT32 partition all partition managers & ubuntu see the second partition as 'other' and it is full.
When creating an ext with ubuntu it indicates 'cannot mount invalid argument'.
I have not tried using AMON as i was unsure if it was dependent upon GSM or CDMA type phones and also any issues with Amoled or SLED (my desire is SLED).
Tried Rom Manager an it does not even attempt to create a partition, indicates complete but nothing when i view partitions with either partition managers or ubuntu.
Lastly, tried via ADB but again it threw an error when creating the second EXT Partition, it creates a partition of sorts but again unknown and full.
In all cases, i cannot format the ext partition with any tools i know - ubuntu, partition manager, Esaus, ADB
Never had this issue with my 8gb Nokia card
Many thanks for your help though guys & girls
hi,
i read you try to do this with adb.. did you try the folowing cmd?
Code:
Step 1: Connect your phone to your computer via USB. Reboot into recovery mode.
Command: adb shell reboot recovery (this will reboot your phone into Cyanogen’s recovery image. Or power on phone when holding home button)
Command: adb shell (type this after your phone has booted and on the recovery screen. it should take you to a # prompt)
Code:
Step 2: Open parted to partition your SD card.
Command: parted /dev/block/mmcblk0 (opens parted and mounts your SD card)
Code:
Step 3: Check the size and partitions of your SD card. The print command will display this info. You can see the size of my SD card is 7969 MB (8 GB). I have 1 partition which is fat32. If your SD card is blank and no partitions are listed, you can skip to Step 5.
Command: print (displays SD card information)
Code:
Step 4: Remove all existing partitions. If you have multiple partitions, remove each one at a time.
Command: rm 1 (deletes partition number 1)
Command: rm 2 (if needed. keep going till all partitions are removed)
Command: print (check when you are done to make sure all partitions are removed)
more info howTO parted there
hope this help
jamadant said:
Hi, thanks for the replies, yes i unmounted in ubuntu but i seem to only be able to create one (working) ext partition but it has to be the full card, or multiple Fat partitions. When i create an ext after the FAT32 partition all partition managers & ubuntu see the second partition as 'other' and it is full.
When creating an ext with ubuntu it indicates 'cannot mount invalid argument'.
I have not tried using AMON as i was unsure if it was dependent upon GSM or CDMA type phones and also any issues with Amoled or SLED (my desire is SLED).
Tried Rom Manager an it does not even attempt to create a partition, indicates complete but nothing when i view partitions with either partition managers or ubuntu.
Lastly, tried via ADB but again it threw an error when creating the second EXT Partition, it creates a partition of sorts but again unknown and full.
In all cases, i cannot format the ext partition with any tools i know - ubuntu, partition manager, Esaus, ADB
Never had this issue with my 8gb Nokia card
Many thanks for your help though guys & girls
Click to expand...
Click to collapse
The procedure should be this:
Insert SD, unmount. Create FAT, leave 1024, format FAT, format remaining as ext3/4.
fragargon said:
hi,
i read you try to do this with adb.. did you try the folowing cmd?
Code:
Step 1: Connect your phone to your computer via USB. Reboot into recovery mode.
Command: adb shell reboot recovery (this will reboot your phone into Cyanogen’s recovery image. Or power on phone when holding home button)
Command: adb shell (type this after your phone has booted and on the recovery screen. it should take you to a # prompt)
Code:
Step 2: Open parted to partition your SD card.
Command: parted /dev/block/mmcblk0 (opens parted and mounts your SD card)
Code:
Step 3: Check the size and partitions of your SD card. The print command will display this info. You can see the size of my SD card is 7969 MB (8 GB). I have 1 partition which is fat32. If your SD card is blank and no partitions are listed, you can skip to Step 5.
Command: print (displays SD card information)
Code:
Step 4: Remove all existing partitions. If you have multiple partitions, remove each one at a time.
Command: rm 1 (deletes partition number 1)
Command: rm 2 (if needed. keep going till all partitions are removed)
Command: print (check when you are done to make sure all partitions are removed)
more info howTO parted there
hope this help
Click to expand...
Click to collapse
Many thanks, tried this procedure again with the error message SEGV_MAPPER (Address not mapped to object) Aborted when i try to create EXT 2
Lost now
hi,
i look up the reason of that error, seems to be a bug from some lib.c inherited by parted but those are mention around 2006 amazing...
i know that the tut mentin ext2 as ext partition but why didn't try ext3 before doing this u can check out what does your actually partition says with
# fdisk -lu /dev/block/mmcblk0
give back the report plz
I suggest Amon-RA recovery.
It's very simple and fast
p.s: i don't suggest using Rom Manager, too much trouble
fragargon said:
hi,
i look up the reason of that error, seems to be a bug from some lib.c inherited by parted but those are mention around 2006 amazing...
i know that the tut mentin ext2 as ext partition but why didn't try ext3 before doing this u can check out what does your actually partition says with
# fdisk -lu /dev/block/mmcblk0
give back the report plz
Click to expand...
Click to collapse
Hi Thanks for your help, i tried to partition ext 2, 3 & 4 but get the same issue regardless of partition type. I believe that the card may be a fake as all the transferring from phone to usb card reader has started to make the branding 'rub off'.
Therefore, i have sent it back and will hopefully get a refund or replacement.
many thanks for your time & efforts
regards
jamadant
okay, so soon with new one anyway you know where to go if need it

SD Card Problem

Ok, so here's what I did.
1) My SD Card was partitioned.
I had used Darktremors a2sd a while back to put my apps on SD
2) Today, I copied the contents of my SD Card to my desktop
3) Then, I partitioned my SD Card (swap - 0MB; ext2 - 0MB; FAT32 - remainder)
4) Now, my computer doesn't recognize the SD Card AND Android doesn't work!?
Seriously, it will load to a wallpaper with battery, signal, and time. It even gives me the little USB icon. But, no shell or whatever.
Here is the error I was getting:
E:Can't mount /dev/block/mmcblk0p1 (or /dev/block/mmcblk0)
(No such file or directory)
E:Can't mount /sdcard
5) AmonRA will allow me to repartition the SD Card (or so it says), but this doesn't fix the problem.
6) I finally got Fastboot to recognize my device, however running the following commands didn't fix ****:
fastboot-mac oem enableqxdm 0
fastboot oem enableqxdm 0
7) Then, I tried selecting clear storage in the bootloader (why I did this on a rooted phone I'll never know), and now my phone doesn't do anything.
8) About all I have going for me is a working recovery and fastboot recognizing my device. No OS, no SD Card, and no way of flashing anything.
What do I do!?
Heres your first problem....
3) Then, I partitioned my SD Card (swap - 0MB; ext2 - 0MB; FAT32 - remainder)
Click to expand...
Click to collapse
You should have gave at least 1024MB to EXT.2.Thats where your apps are installed.Try that and let me know.
Just a thought
If you have a Card Reader, Remove the SD card from your phone and put it in a microSD adapter to see if your computer recognizes it that way.
Is it possible for you to repartition but put 1024 MBs onto an ext2 and try again? I thought our phones needed the ext2 partition.
Just throwing some suggestions around.
Or you can boot into the boatloader,by powering off,then hold the volume rocker in the down position,once in there,try to enter recovery,if not,connect to your computer through the bootloader.Yes you can repartition the sd card,only from inside recovery or from the computer using a partition application.
Why did you post this twice? You posted this same question in general as well I think your problem may be failure to read since you obviously didn't read the forum rules, if you searched Google you could have found the answer instead of asking a question that has been answered multiple times and not only did you not search but you posted the same question twice
We are legion, for we are many.

Cant Mount SD card in twrp

I successfully rooted and unlocked my verizon note 4 but for some reason my twrp 3.0.2 will not mount my sd card!
I already tried doing this fix mentioned here
http://forum.xda-developers.com/note-4-verizon/help/wiped-internal-everything-external-t3363814
maybe i didnt perform the fix correctly?
Any help is greatly appreciated!
Thanks,
deershoot3r
EDIT: Fixed retried the fix 2 more times and it finally went through
Um is it just me or am I not seeing the fix? I am perfectly rooted and have no issues except TWRP sees my ext SD card as 0mb. I cant mount it and nothing changes. I can see it on my phone and put files on it. Why does TWRP not recognize it? Any help would be appreciated. It isn't crippling by any means but it sure is frustrating.
Get sdcard reader..put it on your laptop or desktop.. Run cmd..format the drive (eg. E it might take 5 to 30 minutes...I believe it's due to the process of unlocking the bootloader the SD card got corrupted.
Sent from my SM-N910V using Tapatalk
I don't see the fix either.. has anyone found a fix?
I think this is more of a MM issue. I had to format my 128 GB with my Moto X Pure for it to even work in a MM rom. I'm guessing all of you are using 5.1.1 roms which is why it works fine for daily use? If so flash a CM13 rom and it should prompt you to format the sd card. Once you've formatted it within the rom it should also read it properly with the latest TWRP. Since my sd card was already formatted, I've had no issues with TWRP or 6.0.1 roms.
This is all my opinion. So please don't fuss if I'm wrong. But I believe the latest TWRP is built for MM and MM allows you to use your sd card as internal storage or as external storage. I prefer external storage. Internal means it's bound to your phone, it won't work with any other phone unless reformatted, and removing it could cause issues to your current rom.
Sent from my SM-N910V using Tapatalk
I might just try the whole CM13 thing. It is very strange because a lot of people would not be on MM so it should work both ways? However once it is formatted I am curious if I go back to 5.1.1 if it will stop working? My Sd card was originally corrupted by the transfer to dev edition method we all used. I was able to regain it by using the sd formatter. Since then my phone works very well with it but TWRP doesn't like it. I will try and switch roms then report back. Who knows maybe it is the fix we need.
Its the root process that killed the sd card, not your ROM, or TWRP. I tried a different sd card and works great with TWRP and all apps (running Jasmine ROM).... Format the one you used to root with your PC.
NOTE:
If you are someone who does not like or just doesn't choose to have Xposed installed, then this step will not work.
Lets go,
1.) Install Xposed Framework
2.) Download and install Wanap Xposed module
3.) Activate the module and reboot.
4.) Open Wanam and go to security hacks and check the box for SDcard RW permission, then reboot.
There may be other ways of going about the sd write/mount fix, but this method worked for me. Hope it works for you.
Guys, if people want to link to this post to resolve this issue, please feel free to do so.
The reason why your SD card becomes 'messed up' is because during the unlock, we do a clone of the first 256MB of your eMMC and write it 'raw' to your SD card. In the event your eMMC would get messed up and fail to boot, it would failover to your MicroSD. When we do this, the GPT/MBR (Partition Table) is cloned also, so it's only recognized the NON-HLOS (FAT) partition. Your card is actually perfectly fine but the partition table is telling the computer/phone that it's a different size. Here's the fix:
Code:
adb shell
su
dd if=/dev/zero of=/dev/block/mmcblk1 bs=512 count=524288
You MUST do mmcblk1 and NOT mmcblk0 (your eMMC) as that will wipe your internal storage. Once you execute the command, you can reformat like normal.
ryanbg said:
Guys, if people want to link to this post to resolve this issue, please feel free to do so.
The reason why your SD card becomes 'messed up' is because during the unlock, we do a clone of the first 256MB of your eMMC and write it 'raw' to your SD card. In the event your eMMC would get messed up and fail to boot, it would failover to your MicroSD. When we do this, the GPT/MBR (Partition Table) is cloned also, so it's only recognized the NON-HLOS (FAT) partition. Your card is actually perfectly fine but the partition table is telling the computer/phone that it's a different size. Here's the fix:
Code:
adb shell
su
dd if=/dev/zero of=/dev/block/mmcblk1 bs=512 count=524288
You MUST do mmcblk1 and NOT mmcblk0 (your eMMC) as that will wipe your internal storage. Once you execute the command, you can reformat like normal.
Click to expand...
Click to collapse
Thanks ryanbg but I can use my sd card just fine in my phone. Full storage and all. TWRP is the only place it won't recognize it. Tibu works with my sd card as well. Will this script fix the TWRP issue? I don't think it will but thought I would ask. You know more than I do
Sent from my SM-N910V using Tapatalk
ryanbg said:
Guys, if people want to link to this post to resolve this issue, please feel free to do so.
The reason why your SD card becomes 'messed up' is because during the unlock, we do a clone of the first 256MB of your eMMC and write it 'raw' to your SD card. In the event your eMMC would get messed up and fail to boot, it would failover to your MicroSD. When we do this, the GPT/MBR (Partition Table) is cloned also, so it's only recognized the NON-HLOS (FAT) partition. Your card is actually perfectly fine but the partition table is telling the computer/phone that it's a different size. Here's the fix:
Code:
adb shell
su
dd if=/dev/zero of=/dev/block/mmcblk1 bs=512 count=524288
You MUST do mmcblk1 and NOT mmcblk0 (your eMMC) as that will wipe your internal storage. Once you execute the command, you can reformat like normal.
Click to expand...
Click to collapse
ryanbg, thanks so much. This worked perfectly, and thanks for explaining how and why. Awesome!
Another fix for TWRP users who are unable to mount external storage:
None of the listed fixes worked for me so here is how I fixed the issue...
1. Insert your sd card into a MicroSD adapter and put into your PC
2. Run command prompt as administrator
3. In the command prompt window type the following commands:
Press Enter after each command -
diskpart
list disk
select disk 1 [enter the disk number assigned to your sd card. e.g. select disk 1]
clean
create partition primary
select partition 1
format quick fs=fat32 [If your sc card is larger than 32GB the change format quick fs=fat32 to format quick fs=ntfs]
exit
4. Remove your sd card and place it back in your phone, reboot/enter recovery and mount your external storage.
You should now see the full available storage space.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
ryanbg said:
Guys, if people want to link to this post to resolve this issue, please feel free to do so.
The reason why your SD card becomes 'messed up' is because during the unlock, we do a clone of the first 256MB of your eMMC and write it 'raw' to your SD card. In the event your eMMC would get messed up and fail to boot, it would failover to your MicroSD. When we do this, the GPT/MBR (Partition Table) is cloned also, so it's only recognized the NON-HLOS (FAT) partition. Your card is actually perfectly fine but the partition table is telling the computer/phone that it's a different size. Here's the fix:
Code:
adb shell
su
dd if=/dev/zero of=/dev/block/mmcblk1 bs=512 count=524288
You MUST do mmcblk1 and NOT mmcblk0 (your eMMC) as that will wipe your internal storage. Once you execute the command, you can reformat like normal.
Click to expand...
Click to collapse
Thank you for this but mine still shows as 0MB in TWRP. Everywhere else, I see full capacity. I've deleted partitions and reformatted multiple times, still no dice.
Any solution this issue? I have a 64gb card that I had used for the unlocking process. I had removed all the partitions and re-created a single one, but TWRP won't mount it, and shows the card as 0mb. It shows full capacity 59.61gb after booting into the OS on the phone, it works fine in Windows, heck I even put it in an SD adaptor and used it fine in my DSLR!
TWRP is the only thing that won't read it. It behaves as if there is no uSD inserted at all.
I'm attempting the diskpart instructions now.
Edit: OK, fixed it. Following the instructions in post #12 made it readable by TWRP, but couldn't write to it. Booted into the OS and it said the uSD card was messed up - allowed it to format. Rebooted into TWRP and was able to backup to it successfully!
newmartinr said:
None of the listed fixes worked for me so here is how I fixed the issue...
1. Insert your sd card into a MicroSD adapter and put into your PC
2. Run command prompt as administrator
3. In the command prompt window type the following commands:
Press Enter after each command -
diskpart
list disk
select disk 1 [enter the disk number assigned to your sd card. e.g. select disk 1]
clean
create partition primary
select partition 1
format quick fs=fat32 [If your sc card is larger than 32GB the change format quick fs=fat32 to format quick fs=ntfs]
exit
4. Remove your sd card and place it back in your phone, reboot/enter recovery and mount your external storage.
You should now see the full available storage space.
Click to expand...
Click to collapse
thank you and thank you thank you thank you :highfive::good::highfive::good::highfive:
SlothlyDX said:
Thanks ryanbg but I can use my sd card just fine in my phone. Full storage and all. TWRP is the only place it won't recognize it. Tibu works with my sd card as well. Will this script fix the TWRP issue? I don't think it will but thought I would ask. You know more than I do
Sent from my SM-N910V using Tapatalk
Click to expand...
Click to collapse
I get permission denied when attempting this.
Post #12 worked perfectly
Thanks!!:good:

Categories

Resources