💾 Archived View for alaskalinuxuser.ddns.net › 2021-07-23_2.gmi captured on 2024-09-29 at 00:07:51. Gemini links have been rewritten to link to archived content

View Raw

More Information

-=-=-=-=-=-=-

Fastboot: ‘Not enough space to resize partition’

">

35w, https://alaskalinuxuser3.ddns.net/wp-content/uploads/2021/06/ulefone7-

196x300.png 196w" sizes="(max-width: 335px) 100vw, 335px" />

It’s been interesting getting back into Android development again, and in

particular, working with the newer phones. My wife and I got a matching pair of

Ulefone Armor 7s, and yet they had surprisingly different results when trying

to install a new custom ROM. In particular, it was interesting working with the

new “Super” partition.

Back in the old days, there were lots of partitions in the phone memory, and

from that you installed your custom ROM. Nowadays, a lot of phones use “Super”

partitions that have one large partition that contains several smaller logical

partitions. The benefit being that you can use fastbootd (in userspace) and

change the sizes within the super partition rather quickly, or even somewhat

dynamically.

I built my own version of Phhusson’s AOSP GSI, and flashed it on our phones. I

prefer going Gapp-less, and vanilla, and having super user permissions

installed and enabled. Flashing to my wife’s phone was fairly simple, no issues

were had at all. My phone, which is identical, raised the following error:

alaskalinuxuser@alaskalinuxuser-PowerEdge-R520:~$ ./platform-tools/fastboot

flash system ./system-roar-arm64-ab-vanilla.img \nResizing 'system'

FAILED (remote: 'Not enough space to resize partition')\nfastboot: error:

Command failed\nalaskalinuxuser@alaskalinuxuser-PowerEdge-R520:~$

But, a few minutes on the web brought me to an issue_discussion_with_Phhusson

and_Android2468_about_this_issue, and Phhusson recommended that Android2468

delete the product partition so there would be room to flash the system

partition. So, I followed suit:

alaskalinuxuser@alaskalinuxuser-PowerEdge-R520:~$ ./platform-tools/fastboot

delete-logical-partition product\nDeleting 'product'

OKAY [ 0.017s]\nFinished. Total time: 0.017s\nalaskalinuxuser@alaskalinuxuser-

PowerEdge-R520:~$ ./platform-tools/fastboot flash system ./system-roar-arm64-

ab-vanilla.img \nResizing 'system' OKAY

[ 0.002s]\nSending sparse 'system' 1/6 (262140 KB) OKAY

[ 8.351s]\nWriting 'system' OKAY

[ 1.447s]\nSending sparse 'system' 2/6 (262140 KB) OKAY

[ 8.390s]\nWriting 'system' OKAY

[ 1.570s]\nSending sparse 'system' 3/6 (262140 KB) OKAY

[ 8.466s]\nWriting 'system' OKAY

[ 1.566s]\nSending sparse 'system' 4/6 (262140 KB) OKAY

[ 8.387s]\nWriting 'system' OKAY

[ 1.557s]\nSending sparse 'system' 5/6 (262140 KB) OKAY

[ 8.507s]\nWriting 'system' OKAY

[ 1.665s]\nSending sparse 'system' 6/6 (221800 KB) OKAY

[ 7.094s]\nWriting 'system' OKAY

[ 1.458s]\nFinished. Total time: 58.464s\nalaskalinuxuser@alaskalinuxuser-

PowerEdge-R520:~$

And that worked! Can’t do much better than getting good advice from the legend

himself (Phhusson)! Still not sure why there was a difference between the two

identical phones, but it was nice that it was an easy fix.

Linux – keep it simple.