yashsingh1/xdaforums huggingface dataset:
[Nexus 7 (2013) Original Android Development] jhford:
Unable to mount storage

I have 3 debs. I know; I'm crazy. I frequently get the TWRP error, "unable to mount storage," and I want to make sure my partitions are correct. The logs are attached. Please note that the metadata section in one log is different than the other two logs.

Thank you
[Nexus 7 (2013) Original Android Development] Clamor:
[MENTION=263313]jhford[/MENTION] all three are good.
[Nexus 7 (2013) Original Android Development] jhford:
Thanks. But maybe you didn't notice that line 30 of partition-3.log does not say ext4.
[Nexus 7 (2013) Original Android Development] Clamor:
[MENTION=263313]jhford[/MENTION] I did, it is fine.
[Nexus 7 (2013) Original Android Development] ZACHARiAS_:
Just dropping by after a few years of absence to give you my thanks for ya work: life saver.

Cheers.
[Nexus 7 (2013) Original Android Development] maruchandd:
Hi, I have a flo and I tried to update to the latest TWRP. I have TWRP 2.8.7.0 installed already.

I put twrp-3.3.1-1_UA-flo into the sdcard and tried to install it from within twrp but it said failed and the console gave no extra info.

So I try from adb on my computer, got it to connect/upload the image, and this is the error it gave

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.

C:\Windows\system32>cd c:\adb\platform-tools

c:\adb\platform-tools>adb reboot bootloader

c:\adb\platform-tools>fastboot flash recovery twrp-3.3.1-1_UA-flo.img
target didn't report max-download-size
sending 'recovery' (10498 KB)...
OKAY [ 0.337s]
writing 'recovery'...
FAILED (remote: size too large)
finished. total time: 0.342s

c:\adb\platform-tools>

"remote: size too large" huh? Anyone know what's up? I tried to backup boot and system and it gave another error, if that would help figure out what's wrong I can reproduce it here

still love this device as an e-reader and have no intentions of parting with it. Great to see it still being worked on.
[Nexus 7 (2013) Original Android Development] adstraylight:
I think this is because the ua twrp requires a larger recovery partition than stock, and this is why the OP says to run the resize zip before updating the recovery image to the ua custom version. The error is the remote device (your tablet) saying that the image is too large for the existing partition.
[Nexus 7 (2013) Original Android Development] maruchandd:
Later on I also tried twrp-3.3.1-0-flo.img from the twrp website (which is about 2mb smaller) and got the same problem Edit: It turned out that repartitioning was not necessary to flash this sized rom into recovery.

Here's a quote of my original post to make reading easier since the thread is on a new page

edit to add in case it helps others, this technique fixed my problem

https://xdaforums.com/android/general/how-to-fix-unable-to-mount-data-t3830897

After doing this process I was able to flash the newest twrp recovery image. NOTE! Installing the new 3.1.1.0 img didn't work from within my old 2.8.x.x TWRP version even after successully fixing my file system as noted in the guide above. Oddly, 2.8.xx twrp did flash the image successfully but when I tried to boot into recovery it just restarted back to bootloader without any error or message! Luckily I was able to load the device into its old version of cyanogenmod, enable usb debugging, reboot into bootloader through adb and flash the image from my PC and the newest twrp is working without problems

to clarify, the process described above in bold text is explained here under "Fastboot install method (no root required)" https://twrp.me/asus/asusnexus72013wifi.html
[Nexus 7 (2013) Original Android Development] ichinii:
Hi,

I tried to repartition twice , once when I was with custom rom and twrp 3230, and twice With stock.

I had the same problem, I follow the tutorial.

Once I installed the script repartition, I directly tried to install twrp from posted above, as written in the description, but file too large.

I think I miss something..

Sorry but the tutorial is not very clear for me...

Please somebody can make a clear list to what to do exactly? From a clean stock rom.

Thanks.
[Nexus 7 (2013) Original Android Development] maruchandd:
Did you try this? https://xdaforums.com/android/general/how-to-fix-unable-to-mount-data-t3830897

here's what I did

1 make backups of files and apps

2 follow steps 1-8 described in above link (fixed "cant mount" and "not enough storage" errors)

3 booted into my old rom, which was factory reset. set it up real quick without creating accounts

4 enabled usb debugging once booted in

5 connect to pc and follow the process here under "fastboot install method" https://twrp.me/asus/asusnexus72013wifi.html

Note again, this process didn't fully format the ROM already on it. For me the rom reverted to factory settings so you should backup any data on your sd card before doing this
[Nexus 7 (2013) Original Android Development] ichinii:
Hello,

it worked with your help.

Thanks for your Time :)
[Nexus 7 (2013) Original Android Development] Dee-Dee:
I followed step 1 to 5, but original TWRP recovery seem to not startup. Then I installed twrp-3.3.1-1_UA-flo.img from fastboot, but when it loaded, adb couldn't see my Nexus 7 anymore.

I succeded to install a ROM via sideload, but still adb won't recognize my device. How can I solve it?
[Nexus 7 (2013) Original Android Development] Z'ha'dum:
I'm stuck

Hi,

I am absolutely new to this and and must have made a mistake I just can't figure out.

I applied the script by flashing from TWRP 3.3.1.0 (org) and and repartioned via terminal / code word. After reboot to TWRP my "FLO" is extremy slow (after several restarts). I tried mounting, it failed due to 0MB size. I tried wiping the partitions but I am getting nowhere - all formats / mounts fail.

I cannot copy the partition.log script to my device so I used ADB / parted for fetching the partion table below.

My goal now: return to the default / stock configuration. Can anyone please help me with this. I am really stuck!

Model: MMC 016G92 (sd/mmc)

Disk /dev/block/mmcblk0: 15758000128B

Sector size (logical/physical): 512B/512B

Partition Table: gpt

Number Start End Size File system Name Flags

1 67108864B 156745727B 89636864B fat16 radio

2 201326592B 204472319B 3145728B modemst1

3 204472320B 207618047B 3145728B modemst2

4 268435456B 283795455B 15360000B ext4 persist

5 335544320B 336343039B 798720B m9kefs1

6 336343040B 337141759B 798720B m9kefs2

7 402653184B 403451903B 798720B m9kefs3

8 403451904B 406597631B 3145728B fsg

9 469762048B 471298047B 1536000B sbl1

10 471298048B 472834047B 1536000B sbl2

11 472834048B 474931199B 2097152B sbl3

12 474931200B 480174079B 5242880B aboot

13 480174080B 480698367B 524288B rpm

14 536870912B 553648127B 16777216B boot

15 603979776B 604504063B 524288B tz

16 604504064B 604505087B 1024B pad

17 604505088B 606041087B 1536000B sbl2b

18 606041088B 608138239B 2097152B sbl3b

19 608138240B 613381119B 5242880B abootb

20 613381120B 613905407B 524288B rpmb

21 613905408B 614429695B 524288B tzb

22 614429696B 2187293695B 1572864000B system

23 2187293696B 2263875583B 76581888B cache

24 2263875584B 2264924159B 1048576B misc

25 2264924160B 2281701375B 16777216B recovery

26 2281701376B 2281709567B 8192B DDR

27 2281709568B 2281717759B 8192B ssd

28 2281717760B 2281718783B 1024B m9kefsc

29 2348810240B 2348843007B 32768B metadata

30 2348843008B 2610987007B 262144000B vendor

31 2610987008B 15757983231B 13146996224B userdata

(parted)

Thank you!
[Nexus 7 (2013) Original Android Development] herlayu:
Partition corruption

I think my partition table also is corrupted, Followed the steps up to flashing Clamor's repartition script, and got the "Not nexus 7 (2013)" error message

here is the output of the partition log utility Clamor provided

Model: MMC HBG4e (sd/mmc)
Disk /dev/block/mmcblk0: 31272730624B
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number Start End Size File system Name Flags
1 67108864B 156745727B 89636864B fat16 radio
2 201326592B 204472319B 3145728B modemst1
3 204472320B 207618047B 3145728B modemst2
4 268435456B 283795455B 15360000B ext4 persist
5 335544320B 336343039B 798720B m9kefs1
6 336343040B 337141759B 798720B m9kefs2
7 402653184B 403451903B 798720B m9kefs3
8 403451904B 406597631B 3145728B fsg
9 469762048B 471298047B 1536000B sbl1
10 471298048B 472834047B 1536000B sbl2
11 472834048B 474931199B 2097152B sbl3
12 474931200B 480174079B 5242880B aboot
13 480174080B 480698367B 524288B rpm
14 536870912B 553648127B 16777216B boot
15 603979776B 604504063B 524288B tz
16 604504064B 604505087B 1024B pad
17 604505088B 606041087B 1536000B sbl2b
18 606041088B 608138239B 2097152B sbl3b
19 608138240B 613381119B 5242880B abootb
20 613381120B 613905407B 524288B rpmb
21 613905408B 614429695B 524288B tzb
22 671088640B 1551892991B 880804352B ext4 system
23 1551892992B 2139095551B 587202560B ext4 cache
24 2147483648B 2148532223B 1048576B misc
25 2214592512B 2225078271B 10485760B recovery
26 2281701376B 2281709567B 8192B DDR
27 2281709568B 2281717759B 8192B ssd
28 2281717760B 2281718783B 1024B m9kefsc
29 2348810240B 2348843007B 32768B metadata
30 2415919104B 5570068479B 3154149376B ext4 system
31 5637144576B 31272713727B 25635569152B ext4 userdata

Any help would be greatly appreciated!
[Nexus 7 (2013) Original Android Development] opensourceeddie:
Trying to install Lineage OS 17.1 on my Nexus 7 2013 (flo)

Hello. I have not tinkered with Android in a long time. It has been a while since I used TWRP, fastboot, adb, or any of that stuff. I recently started using my Nexus 7 2013 (flo) again with Google's stock Android Marshmallow (factory image). I decided to try out Android 10 on this old tablet so I flashed the latest TWRP recovery and attempted to install Lineage OS 17.1 expecting it to work flawlessly. I got ERROR 7. I read that the Nexus 7 2013 has to be re-partitioned in order to run Android 9 and above due to these newer Android versions being too big for the stock partition space. I am new to re-partitioning. I read through the guide earlier but honestly, it is confusing and I'm scared to even try anything right now (I'm afraid to brick my Nexus:silly:) which is weird because I don't usually get scared when tinkering with Nexus devices since they are meant to be rooted and are supposed to be easy to mess with. Someone please explain to me in an easier way to understand what I have to do to re-partition :) :p Thank you.
[Nexus 7 (2013) Original Android Development] Z'ha'dum:
Hello Everyone. I think I am back in the game. Multi-appliying "Wipes" in got "Internal Storage" back ready for mount, which I used to upload the repartitioning script - et voila: I am back to stock. Thanks!
[Nexus 7 (2013) Original Android Development] RosarleathSunny:
after flashing flo-deb_clamor_repartition.zip, it says "Can not extract updater-script/ Do you have it in package?"

---------- Post added at 06:27 PM ---------- Previous post was at 06:05 PM ----------

oh, i fixed it.

just wiping whole storage (include internal sdcard) solved the problem
[Nexus 7 (2013) Original Android Development] MerkinMcGee:
I am getting stuck trying to get from TWRP 3.2.1-0 to 3.3.1-1. I keep getting an error "Size of image is larger than target device. Looked through the whole thread, and doesn't seem people have gotten that specific error.
[Nexus 7 (2013) Original Android Development] Adalberaht:
First time using a repartition tool, when you say to flash the repartition zip you mean sideloading? Or ADB push it in System or somewhere and then "install" it?

Thanks in advance.
[Nexus 7 (2013) Original Android Development] ipdev:
I thought it was noted but, that may have been a different thread.

I know I have in other threads.

This script also increases the size of the recovery partition, UA version of TWRP is a little bigger so it will not fit on the stock recovery sized partition.

The stock recovery partition on flo/deb is 10M.

If I did the math right, the recovery partition is 16M after the partitioning.

You have to use the official (ordinary recovery) TWRP to use the script, once done you then can install the UA version to format and use the vendor partition.

Make sure you use the newest TWRP from twrp.me to run the script.

TWRP

Nexus 7 (2013) WiFi (flo) twrp.me - Link

Nexus 7 (2013) LTE (deb) twrp.me - Link

Hope that answers your question.

PS.

Here it is, #5 in the second post.

xdaPost Post # 2 - Link

Not sure if sideload is a recommended way but, I used it the other day on my hammerhead to run Clamor's script for Nexus 5.

Modified to stock and Stock to modified.

I'm not sure how I originally did it. Probably pushed the zip to /tmp, /sideload or /sdcard and installed from there.

The note to not install from OTG, recommends pushing the zip file to /sdcard and then installing from there.

#6 in the second post. xdaPost Post # 2 - Link

Hope it helps answer your question.

Cheers all. :cowboy:
[Nexus 7 (2013) Original Android Development] Adalberaht:
[MENTION=5424240]Clamor[/MENTION]

I pushed flo-deb_clamor_repartition.zip in /sdcard/, installed it and typed "modify" in Terminal as asked.

Then I did the same with unified_clamor_partition_log.zip and it failed to mount system, data and cache. Also cache has different End and Size than those posted in the FAQ.

Here's the log:

Model: MMC HBG4e (sd/mmc)
Disk /dev/block/mmcblk0: 31272730624B
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number Start End Size File system Name Flags
1 67108864B 156745727B 89636864B fat16 radio
2 201326592B 204472319B 3145728B modemst1
3 204472320B 207618047B 3145728B modemst2
4 268435456B 283795455B 15360000B ext4 persist
5 335544320B 336343039B 798720B m9kefs1
6 336343040B 337141759B 798720B m9kefs2
7 402653184B 403451903B 798720B m9kefs3
8 403451904B 406597631B 3145728B fsg
9 469762048B 471298047B 1536000B sbl1
10 471298048B 472834047B 1536000B sbl2
11 472834048B 474931199B 2097152B sbl3
12 474931200B 480174079B 5242880B aboot
13 480174080B 480698367B 524288B rpm
14 536870912B 553648127B 16777216B boot
15 603979776B 604504063B 524288B tz
16 604504064B 604505087B 1024B pad
17 604505088B 606041087B 1536000B sbl2b
18 606041088B 608138239B 2097152B sbl3b
19 608138240B 613381119B 5242880B abootb
20 613381120B 613905407B 524288B rpmb
21 613905408B 614429695B 524288B tzb
22 614429696B 2187293695B 1572864000B system
23 2187293696B 2263875583B 76581888B cache
24 2263875584B 2264924159B 1048576B misc
25 2264924160B 2281701375B 16777216B recovery
26 2281701376B 2281709567B 8192B DDR
27 2281709568B 2281717759B 8192B ssd
28 2281717760B 2281718783B 1024B m9kefsc
29 2348810240B 2348843007B 32768B metadata
30 2348843008B 2610987007B 262144000B vendor
31 2610987008B 31272713727B 28661726720B userdata
[Nexus 7 (2013) Original Android Development] ipdev:
[MENTION=10685943]Adalberaht[/MENTION]

Hi again.

It appears yours is a 32Gig and uses a Hynix chip. (There are three different chips that were used.)

If you look in the zip file, you will find the script(s) that does the partitioning.

flo-deb_hynix_repartition_32GB.sh looks like the one that ran for your device.

mkpart primary 2187293696B 2263875583B

name 23 cache

From your log, it appears to have run properly.

I'm not sure were the example comes from.
[MENTION=5424240]Clamor[/MENTION] will have to shed lite on that one.

As far as I found, the only difference between all the variants of flo/deb was only the end of the device.

All (stock) partitions started and ended at the same location except for the end of userdata, this was different between 16/32G and chip manufacture.

If you are wondering about the gaps in-between some of the partition, why they are not consecutive.

This device is riddled with free (unallocated) space. I partitioned mine before this script was available, it was pointed out to me only about six months ago why all the free space.

These devices were set on a 64MB (67108864B) partition boundaries/alignment. Basically adding the free space will make the partition (or two) prior divisible by 64MB (67108864B)

Will leave it at that but, it may have been a work-a-around for weaker emmc chips.

Don't forget to do the format and wipe steps. ;)

Cheers. :cowboy:

PS.

Sorry for the slight OT.
[Nexus 7 (2013) Original Android Development] Clamor:
[MENTION=10685943]Adalberaht[/MENTION] if you get error in mounting any partitions, format them and that should fix issue.

[MENTION=7280276]ipdev[/MENTION] thanks for your answers!
[Nexus 7 (2013) Original Android Development] Adalberaht:
Thank both of you.

Still, wiping worked for /system and /cache but not for /data. It goes like this:

Same thing if I try to wipe Internal Storage.
[Nexus 7 (2013) Original Android Development] kwijl:
When using TWRP 3.2.1 after typing the command in terminal it says its unable to unount /system.

So I try to flash recovery with attached TWRP UA version but it says 'size too large'.

What am i missing?
[Nexus 7 (2013) Original Android Development] Clamor:
[MENTION=10653295]herlayu[/MENTION] you have moded your partition table manually, thus you have 3GB second system partition before /userdata.
[Nexus 7 (2013) Original Android Development] someguykenadams:
The repartition zip worked and I also updated TWRP from 3.3.1-0 to 3.3.1-1 successfully and got everything all set. Currently installing another ROM on my tablet at this time. This pleases me.
[Nexus 7 (2013) Original Android Development] Robexuk:
Everything went smooth followed instructions, thank you so much!
[Nexus 7 (2013) Original Android Development] blueoval50:
I had the same issue and used Nexus Root Toolkit and followed instructions for " Full driver installation automatic and manual". I also had to go into Developer Options on the Nexus and re-select MTP under USB configuration, even though it was already selected.
[Nexus 7 (2013) Original Android Development] FaTlip82:
Excuse me, i have tried to backup persist and EFS of my Nexus device. After backup there is a message that files are located somewhere in the /sd/backup folder, but Nexus has no external slot. So i can not find those files anywhere.

Can you please tell me how i can backup it properly? Thank you.
[Nexus 7 (2013) Original Android Development] Gene August:
No file system after repartitioning.

After running the Repartitioning tool on a stock Nexus 7(2013)(flo), there is no file system left on the device. TWRP 3.3.1-1 was successfully installed, but I was not able to mount partitions with TWRP, nor was I able to drop the 'lineage-17.1-20200415-UNOFFICIAL-flo.zip' file onto the Nexus with USB. It appears be read only.

Any help would be appreciated.

Thanks,

Gene
[Nexus 7 (2013) Original Android Development] Cvjack:
Hello. I am very glad that on my Nexus 7 (flo) I can now install other firmware, thanks to your package, thank you very much for that. Is there a similar package for Nexus 7 2012? I can’t find any instructions for him.
[Nexus 7 (2013) Original Android Development] Clamor:
[MENTION=5764550]Gene August[/MENTION] format your partitions in TWRP, if doesn't help, take partition log
[Nexus 7 (2013) Original Android Development] Gene August:
Attempted formatting from TWRP hadn't worked, but when I rebooted a startup screen appeared asking for initial user input then wifi connection info, then image from another device to copy. When that failed after 3 attempts a "Never mind" message appeared; then without further input from me the system re-installed the original 6.01. I'm pretty sure it was my error at the repartitiong step. Repetition of the procedure with needed correction of my error was successful! Thank you very much for your efforts. Gene
[Nexus 7 (2013) Original Android Development] ashcraft:
Nevermind. It finally let me wipe and all seems to be working out muddily.
[Nexus 7 (2013) Original Android Development] ipdev:
For future reference.. (to your original post.)

adb reboot bootloader

TWRP-> Reboot-> Bootloader (If asked do NOT install the TWRP App.)

Cheers. :cowboy:
[Nexus 7 (2013) Original Android Development] ashcraft:
So I ran into an issue again. I tried to install the Pixel Experience rom. It installed but hung at the boot logo for hours so I finally tried to redo everything to rule out error on the install. Now I've repartitioned, it told me to type "stock", then it rebooted.

Now after the reboot it wont go back to TWRP. It only boots to bootloader and when I select reboot to recovery on bootloader screen it just loops back to the bootloader. Any ideas? I've been away from android in general for a few years now. Thanks in advance and sorry for being an idiot.
[Nexus 7 (2013) Original Android Development] Robexuk:
Try reflesh the twrp in fastboot after flash reboot first to bootloader and then to recovery.
[Nexus 7 (2013) Original Android Development] ashcraft:
It'll only boot into fastboot, is there a tutorial I can follow to reflash?
[Nexus 7 (2013) Original Android Development] Robexuk:
Just connect your N7 to the PC via USB cable while you in fastboot mode and using command " fastboot flash recovery recoveryname.img " after the flash first reboot the bootloader and then choose to boot into recovery, you should be able to boot into the twrp recovery.
[Nexus 7 (2013) Original Android Development] ashcraft:
I got it to "flash" finally, but it hangs at the google logo on reboot.

I couldn't flash the repartitioned TWRP as it said the file size was too large but it seems to flash the smaller 4mb one fine. Still though, I have a borked tab stuck at the google logo now. I can boot back into fastboot but I'm at a loss.
[Nexus 7 (2013) Original Android Development] ashcraft:
Ok, so I can get it to boot into the patched recovery via fastboot boot recovery.img, but I still can't install the patched recovery, even after reapplying the partition. It tells me the size of image is larger than target device.
[Nexus 7 (2013) Original Android Development] DjangoOne:
Hello and thanks for the good instructions,

i have searched the whole thread, but unfortunately I can't see how to restore persist and EFS?

Could someone please help me with the command lines (the 3 images are ready in /sdcard...)? Thanks a lot :)

- Django
[Nexus 7 (2013) Original Android Development] Robexuk:
Look at the repartition Nexus 5 thread before last post it may give you idea....?
[Nexus 7 (2013) Original Android Development] DjangoOne:
That works perfectly. Thank you Robexuk!