yashsingh1/xdaforums huggingface dataset:
[Nexus 7 (2013) General] k23m:
"GNUwin32 BIN folder"? What is it and what are you doing with it? CROSS and RESTOCK do not depend on user added paths, folders, apps, etc. You don't need to do anything extra manually. Simply ensure that AVG is indeed disabled and follow the instructions precisely.

"Download

CROSS2.zip

and unzip it then download

cross-update-XXX.zip

and unzip it to the CROSS folder, overwrite existing files."

RESTOCK USAGE

download the attached zip file (

Restock2.zip

)

unzip it

double-click on "restock.bat"

follow the prompts

Also...

"If you see errors (including wget), copy and report them.

Run getlog.bat

and include "getlog.log" in your post."

Incidentally, I note "Kingston eMMC detected..." - this does not look promising as the chip is very unreliable. If you had tried manual N7 update methods, and failed, then CROSS/RESTOCK scripts will not be any better on faulty hardware. But let's focus on the 'wget' issue first. Please post your "getlog.log".

🤞
[Nexus 7 (2013) General] UweRammelt:
Get the error messages

- E2001: Failed to update vendor image

- Failed to mount '\vendor' (Invalid argument).

Any idea what I can do?

---------------------------

Supplement: I did Restock (works) and Cross again: seems to work ...
[Nexus 7 (2013) General] balesteros:
Thanks for your reply K23M! That way I tried to get mget working again, without good results. But somehow a reboot and restock 2 managed to get it running again! Strangely enough my pc didn't recognise the Nexus anymore, but connecting it to another USB port got it right. And after turning on debugging Cross2 managed to get my 8 year old Nexus running on Android 11 making Family Link possible. My daughter (who is actually younger than this tablet) will be VERY grateful!
[Nexus 7 (2013) General] supaabzz:
1. on N7 select "Recovery mode" with volume button
2. on N7 press power button to boot Recovery
3. when you see TWRP main menu press any key to continue
(wait for TWRP main menu, not TWRP boot logo)

Wait...
***********************************************************************************************************************
***********************************************************************************************************************
***********************************************************************************************************************
***

How long does it get stuck on Wait after the steps listed above?

Mine has been doing for 30 minutes + and I am not sure what to do. I cancelled once, and retried stuck on same step.

EDIT:

I've managed to find the issue and get it sorted.

It seems the Wait *** were just due to trying to FASTBOOT to TWRP recovery failing. Looked at the script

echo Wait...
adb kill-server >nul 2>&1
:adbd
ping -n 3 127.0.0.1 >nul
set /p =*<nul
--updated the * to "waiting for reconnecting" check if it was the issue

I uninstalled the drivers from Device Manager on Windows, then just reconnected directly to Bootloader using Fastboot and it worked perfectly without an issue.
[Nexus 7 (2013) General] nintendo_:
After running the script, when I try to boot into recovery mode I keep getting the Google screen and nothing happens. Any ideas?
[Nexus 7 (2013) General] names:
@k23m Firstly, I want to thank you for creating this process and making it as easy as it is to flash. Everything works perfectly and I'm glad to see just how much faster this makes my device.

The only issue I am encountering is when flashing ElementalX-N7-6.17, as it causes my tablet to go into a boot loop. I left most of the settings as is when flashing, but mainly am trying to achieve OTG + Charging.

Any thoughts on a possible solution for this?
[Nexus 7 (2013) General] k23m:
I suppose you are trying to use the kernel with one of the latest LOS - it will not work.

The kernel is attached to this thread because it worked with LOS14 and an old CROSS script. For OTG + Charging, you can either get LOS14 or the stock ROM, or look for a different kernel.

(y)
[Nexus 7 (2013) General] dragonsamus:
Thank you so much! Breathes new life to this old tablet.
[Nexus 7 (2013) General] extremko:
Thank you for this wizardry, k23m!! :) I really hope to be able to send a message like the person above me :)

I'm coming from this thread: https://xdaforums.com/t/repartition...o-deb-16gb-32gb-ua-twrp.3844386/post-86215571

.. where you helpfully instructed me how to fix my own mess :)

And it worked like charm! Up to a point... Let me see if I can explain what happened. I think I'm in a much better position than I was so now I'm afraid to do anything more not to screw it up again.

This is what happened when I ran lineage-install-3-flox.bat: https://justpaste.it/9p5a0

// Edit:

// I read through the paste and noticed that I duplicated Step 2 content into Step 3. Please ignore. Bad copy/pasta

Step 4 is where the failure occurs. I cannot load into recovery.

I retried the script and then Step 2 failed as recovery cannot be written.

As I said, I think I'm in a better position than I was so I won't try to play around further not to screw something even further :)

I love the automation you've created! Can't even imagine how much testing it took to make it so fool-proof!
[Nexus 7 (2013) General] k23m:
Hi again, please run the

repartition.bat

script and select ultimate repartition. After a reboot run CROSS again and do not repartition anymore. If there is another error, run relog.bat and attach "relog-xxxxxx.zip" to your post.
[Nexus 7 (2013) General] extremko:
Repartition completed successfully. N7 rebooted. Ran lineage-install-3-flox.bat again and it failed at the same spot

> FAILED (remote: size too large)

I ran relog. The zip is attached.

If we make this work I'm taking you to dinner :-)
[Nexus 7 (2013) General] k23m:
Thank you for the log. You have "variant: flo 16G" and the ultimate repartition fails on it. I have only 32GB flos and had no chance to test it on the smaller N7 version. I need some time to update the script and may contact you via forum messages for testing if you don't mind.

Meanwhile, if you wish, you could try the following workaround:

1/ run RESTOCK2 and do "restore original partitions" with it.

2/ when finished, from Restock run the addons and install TWRP

3/ boot TWRP and install sysrepart-flox.zip

4/ reboot and run CROSS without repartitioning

Again, it is untested on 16GB flo.
[Nexus 7 (2013) General] extremko:
You did for me more than I'd ever expect someone to help! I'll go through the steps now and report back. Hopefully it makes the future experience better for owners of a smaller Flo :-)
[Nexus 7 (2013) General] extremko:
I finished the first 3 steps. Don't know which file to run for #4 :/

lineage-install-3-flox?

There are my notes "//" at the end of step 2, step 4, step 6, and step 8 :-) Nothing major, just some observations in case you find them useful.

I'll leave this for today as it's almost 1 am. And would like to thank you a lot for helping out the community like this!

What you've built is amazing!
[Nexus 7 (2013) General] k23m:
Yes, lineage-install-3-flox

In it, select: "Flash flox-TWRP?" YES and "Repartition?" NO

If there is a boot failure, run relog.bat and attach "relog-xxxxxx.zip" to your post.
[Nexus 7 (2013) General] redwoodie:
Great scripts. Install went very smoothly on DEB 32G. I have an LTE connectivity issue after installing LOS 18.1 with lineage-install3.bat. Initially it took a while for mobile data to connect after installing SIM from another stock DEB, not unheard of but usually devices connect in seconds here. Then it worked fine for a day or so. After a reboot I didn't have connectivity, but after removing and reinserting SIM it was restored. Today it mostly sat unused with wifi on, but when I turned off wifi then I couldn't get mobile data again. Oddly, the network status showed connected and the data icon showed signal, but the LTE letters next to it were missing as in image below. SIM status showed connected and signal strength also. Reinsertion of the SIM didn't fix it at first, but after a reboot and a reinsertion it finally came back. I didn't observe this issue on stock MOB30X prior to running the repartition/install script.

A few other details:

LOS version is 18.1-20211210-UNOFFICIAL-deb

Installed on stock/never modded/BL-unlocked DEB MOB30X

Ran CROSS2 (with update) lineage-install3.bat

Pico GAAPS open_gaaps-arm-11.0-pico-20211221.zip

TWRP 3.6.0_9-1-deb_followmsi.img

Magisk-v23.0.zip

Network settings are correct for carrier (Global, VZWINTERNET)

I tried using the Mobile Data Always On setting in Developer Options, it doesn't seem to affect the issue.

Any suggestions or ideas on how to resolve?

Thanks!
[Nexus 7 (2013) General] extremko:
Thank you! Just finished the install but Nexus is stuck on the booting animation. This line keeps going and going for 10 minutes now: https://www.muycomputer.com/wp-content/uploads/2017/01/Lineage-oS.jpg

I don't expect much of it. Will get logs soon.

There were several failures and errors when mounting /data. Magisk installer failed, too.

This is the log of lineage-install-3-flox process: https://justpaste.it/8jk73

I realized I forgot to link the log the last time, for the first 3 out of 4 steps I did:

> There are my notes "//" at the end of step 2, step 4, step 6, and step 8 :)

> Nothing major, just some observations in case you find them useful.

It's here, if needed: https://justpaste.it/7vbsl
[Nexus 7 (2013) General] extremko:
Here are the logs.

Also the screenshot of what went wrong during the installation. I don't know if all the TWRP output is in the logs on Justpaste.
[Nexus 7 (2013) General] k23m:
OK, sysrepart-flox.zip also fails on N7-16GB.

Please try the new, just released, sysrepart-ultimate-2.zip (test/beta version).

Install it in TWRP,

reboot N7!

, and run lineage-install-3-flox yet again.

If there is a boot failure, run relog.bat and attach "relog-xxxxxx.zip" to your post.

I am perplexed that nobody has reported these issues on N7-16GB for so many months, if not years. Perhaps the 16GB variant is very rare?
[Nexus 7 (2013) General] extremko:
SUCCESS!! :-)

New sysrepart ran without errors. Mounting errors were there before and after, but were gone after the reboot.

All the followup installations worked like charm, too - Lineage, Magisk, GApps... Not a single red line! Whatever you changed in the beta version worked! :-)

You probably don't need any logs for this, but it's here just in case: https://justpaste.it/8hpq2

I cannot talk about other parts of the world but back in early 2014 N7-32GB was an extremely rare find. I had to settle for 16GB.

I used Nexus Toolkit by WugFresh for ages.. But N7 had Android 6.0 as the last update and I haven't used it for a very long time. Then I noticed Lineage and figured it could be a good breath of fresh air to my old tablet and I could give it to my kid as a first device.

In the meantime, while I was writing all this, N7 rebooted and started successfully!

Going through the menus now, Lineage is asking me if I want to update Lineage Recovery alongside the OS. I'd appreciate your advice on this. I'm assuming once we got it working it's a good way to keep Lineage up to date but will defer to your decision.

Thank you for helping me out and for sticking with me for this long! :-)
[Nexus 7 (2013) General] k23m:
My deb seems OK in this context on the OFFICIAL ROM. We are resolving only install issues of various ROMs here. For a specific ROM's problems you need to check dedicated forum threads.

I'd not bother with recovery update as it is pointless unless a relevant bug was discovered. Not sure if the offered OS update plays well with Gapps though. Let me know if you try it :)

Cheers!
[Nexus 7 (2013) General] extremko:
If there's a relevant bug discovered I think the N7 community would rather rely on you anyway :-)

I'll try everything I can as now there's a way to fix anything that can go wrong. And to think I was so close to throwing the tablet away...

Thank you! I cannot say this enough :-)
[Nexus 7 (2013) General] redwoodie:
Can you post a Link for the OFFICIAL ROM you mention?

Thanks!
[Nexus 7 (2013) General] k23m:
You can get it here. 14.1 su is here. GApps 7.1 here.
[Nexus 7 (2013) General] jmgloude:
Thankyou k23m for posting this. Along with ReStock worked perfectly on my Nexus 7 to install LOS 18.1 flox.
[Nexus 7 (2013) General] WoozieJuank:
Excellent work! It has helped me a lot, but I have a question.

I have already installed and configured Kernel Elemental, but is it possible to make changes to the configuration later? Thanks . Cheers
[Nexus 7 (2013) General] k23m:
Hi, yes, either use EX Kernel Manager app or try to edit /init.elementalx.rc directly, and reboot.
[Nexus 7 (2013) General] taadow1030:
I used this script to finally convert my Deb (I don't need LTE) to 18.1 Flox after several unsuccessful manual attempts.. Before your script, I had regretted buying the Deb version of this tablet. THANK YOU for this!
[Nexus 7 (2013) General] gaja22:
Hello, I don't understand how to download "lineage-install-3-flox.bat" because I need this one please. Thank you very much.
[Nexus 7 (2013) General] k23m:
Hi, please follow the instructions...

If you run "lineage-install-3-flox.bat" alone, you will see...
[Nexus 7 (2013) General] poo706:
I'd like to install a ROM that requires a vendor partition. My flo has system repartitioned to 1380 and cache to 20. My USB port quit working long ago, so formatting the data partition is not an option. Would it be possible for me to create mmcblk0p31 vendor and have it rob from the system partition? Or would it have to rob from mmcblk0p30 userdata? Hopefully that makes sense.
[Nexus 7 (2013) General] k23m:
Firstly, the port is very easy to repair. Without a USB port, partition experiments can brick it.

A ROM may require a vendor partition but not actually use it. In this case you could try a simple trick, rename eg mmcblk0p24, which seems unused, to 'vendor' and maybe format it too.
[Nexus 7 (2013) General] poo706:
I think I should just leave well enough alone. I damaged the bezel a little bit trying to pry open my flo and said screw it and put it back together. This ROM does legitimately use the vendor partition, and it's about 67 MB. The misc partition that you suggested is only 1 MB.
[Nexus 7 (2013) General] killeriq:
Hi,

Please is there a way how can i use

"sysrepart-flox.zip - 1.5GB system, data is wiped, 'vendor' partition is added, automatically downloaded by LOS 17.1-flox script"

on LOS 18.1?

As i don't want to loose 4GB of storage and all my tries to do it manually failed, no clue why :(

https://xdaforums.com/t/official-li...i-repartition-only-flox.4255325/post-86871709

Thanks!
[Nexus 7 (2013) General] k23m:
Hello, from your other post...

There is no trick, you can check the source code of CROSS, the scripts work the same as standalone or in CROSS. Perhaps the error is due to the fact that 1.5GB 'system' may be too small nowadays. Do the ultimate 4GB and you will never have to worry about re-re-partitioning ever again.

Incidentally, the old versions of TWRP and Gapps flashed by CROSS are irrelevant. You could later update TWRP manually, and Gapps will auto-update online anyway.
[Nexus 7 (2013) General] killeriq:
hmm strange is that this errors comes even before i try to install any ROM.

1. Restock

2. Add some TWRP

3. repartition

4.. When i go to "Wipe" to try to clear cache , right away those errors

With this Clamor "repartition" which i was using formerly https://xdaforums.com/t/repartition-nexus-7-2013-repartition-flo-deb-16gb-32gb-ua-twrp.3844386/

i had to do "modify", then some formats , but no such errors afterwards

7. Format everything. (mount errors will not affect formatting!)
- In TWRP: Wipe > Format data
- Type yes
- Once this completes go to: Wipe > Advanced Wipe
- Tick all the boxes and wipe. There should be no further mount errors. (Thanks [user=7694808]@mr_rubbish[/user] for corrections in formatting).

With yours i dont see any instruction like this, so i assume is automated?
[Nexus 7 (2013) General] k23m:
Let's recap. You run:

1. Restock2

2. Add the old TWRP from Restock's addons

3. repartition with sysrepart-flox.zip

4. "When i go to "Wipe" to try to clear cache , right away those errors"

Correct? Note, I only support the components of Restock and CROSS, but not any other versions nor mods. So, if you still see those errors then...
[Nexus 7 (2013) General] killeriq:
I found time to repeat those steps again:

1. Restock2/restock.bat

2. Add the old TWRP from Restock's addons / twrp-3.4.0-0-flox.img

3. repartition with sysrepart-flox.zip

4. "When i go to "Wipe" to try to clear cache , right away those errors"

5. Restock2/relog.bat - attached

---

Maybe an additional option to your script to be able to pick which "repart" to use? it might do the trick.

Just want to use FLOX with NOT loosing 4GB due to "repart-ultimate" which is automatically added

Thanks!
[Nexus 7 (2013) General] k23m:
OK, I'll add re-partition options to the next update. Meanwhile let's resolve the errors. Note...

It seems you had used sysrepart-flox on non-original partitions hence the errors.

This is one of them :-)

Next, after "restocking" and "Restore original partitions" do a simple mod before CROSS. In your

Downloads\nex\CROSS\data

folder:

- delete sysrepart-ultimate.zip

- copy sysrepart-flox.zip

- rename sysrepart-flox.zip to sysrepart-ultimate.zip

Now you can run the CROSS script, choose sysrepart-ultimate repartition but actually sysrepart-flox will be used.

BTW note the following in lineage-install-3-flox.bat v2.5

::set EXDL=https://xdaforums.com/attachments/sysrepart-flox-zip.5173241
::set EXZN=sysrepart-flox.zip
set EXDL=https://xdaforums.com/attachments/sysrepart-ultimate-zip.5273007
set EXZN=sysrepart-ultimate.zip

Instead of renaming

CROSS\data

files you could delete the 2 ultimate lines and uncomment the 2 flox lines.
[Nexus 7 (2013) General] killeriq:
@k23m

Thanks for your analysis and "simple" trick will do the job ;) will try on next Tablet.

FYI: Soon as it failed i always used "Restock2" and started over again...

---

In the mean time i was trying various "repartitions" and seems like with Clamor which i downloaded from his repo is working fine on 1st try, even creates /Vendor, after i just need to do the Flo->Flox script and all works fine.
[Nexus 7 (2013) General] underflash:
Following my post and @k23m recomendations, I have manually repartitioned first back to stock with sysrepart-stock.zip and flashed TWRP-3.6.2_9-0-flo, then several reboots, 3-4 wipes of all partitions and data formats without a single error.

After sideloaded sysrepart-ultimate.zip without any problem and flashed TWRP-3.5.0_9-0-FLOX.

Then sideloaded lineage-18.1-20220620-nightly-flox-signed, open_gapps-arm-11.0-pico-20220215. After booting system and Play Store updates, disabled Play Protect and sideloaded Magisk-v25.1.zip (the only way to get PS certified). No errors during this process.

Attached my relog. There are some I/O errors. Are they signs of impending death?
[Nexus 7 (2013) General] k23m:
I see no relevant errors. N7's performance is now presumably OK?

Cheers!
[Nexus 7 (2013) General] Nilithium:
Hi! I might be missing something, but I first ran RESTOCK and then CROSS2 with the lineage-install-2.bat. However, the pico GApps did not install, saying there was no file or directory. I thought it was supposed to acquire them automatically? It got the other necessary packages without a hitch.
[Nexus 7 (2013) General] k23m:
Hello, please edit lineage-install-2.bat

replace
set GADL=https://jaist.dl.sourceforge.net/project/opengapps/arm/20211021/open_gapps-arm-10.0-pico-20211021.zip
set GAZN=open_gapps-arm-10.0-pico-20211021.zip

with
set GADL=https://jaist.dl.sourceforge.net/project/opengapps/arm/20220215/open_gapps-arm-10.0-pico-20220215.zip
set GAZN=open_gapps-arm-10.0-pico-20220215.zip

I'll release a CROSS update soon.
[Nexus 7 (2013) General] Nilithium:
Hi! I placed the latest version in the install directory, still no luck, so I manually flashed it onboard with TWRP. Good to know! I really have you to thank for the RESTOCK/CROSS tools. This saved my tablet from becoming e-waste and allowed me to reuse it for piloting my drones with Litchi! I'm not sure if you'd know how, but is there a way I can leverage root access to overclock the CPU for smoother app performance?
[Nexus 7 (2013) General] CityKev:
Having thanked the developer yesterday on the Restock thread as that got me out of jail I now offer my thanks for this amazing tool.

With my extremely limited skills I've been able to install Lineage 18.1 on my wife's old Nexus 7 to bring it back to life.

Incredible :)
[Nexus 7 (2013) General] jebise101:
I followed the official lineage thread to install 18.1 a while ago and just went ahead and updated to the latest release today, when reading the lineage 18.1 thread some users reported laggy performance when using the clmor repartition zip and said that is resolved with sysrepart-ultimate.zip.

Can I just flash sysrepart-ultimate.zip on my current working lineage OS? I don't care if it wipes my data just don't want to refresh the OS and GAPPS.
[Nexus 7 (2013) General] k23m:
No, sysrepart-ultimate.zip will wipe your current OS. Here is a workaround:

- do a TWRP backup

- transfer the backup to a PC or OTG storage

- install sysrepart-ultimate, reboot and restore the backup

Note that TWRP stays intact during the process: "sysrepart-ultimate.zip - ...'recovery' is enlarged to 64MB in-place and your current TWRP continues to function"
[Nexus 7 (2013) General] jebise101:
I'm not using twrp, using the official lineage recovery as I don't want to install recovery from random sources.
[Nexus 7 (2013) General] CityKev:
Having used CROSS several times already with no issues I have now found my device ends up hanging on the Google image when it tries to reboot.

I've started out from the same point each time by using Restock only now when I use any of the installation options it ends the same as above. I tried deleting the file and re-downloading it in case I had somehow corrupted it but no luck.

I have a functioning device as I've just used Restock but I'm baffled why I can't get CROSS to work again.
[Nexus 7 (2013) General] k23m:
The starting point must be always Restock2 + k23m-persist-fix2.zip

I have to release Restock3 with k23m-persist-fix2 in it ASAP as I am getting tired of repeating it ad nauseam.

Now, should k23m-persist-fix2 not resolve the problem, check the top post again, it goes...
[Nexus 7 (2013) General] CityKev:
Thanks again.

I was using Restock 2 OK I reckon with the persist fix installed so I deleted the CROSS files and reinstalled them. Using the install-2 bat for Lineage 17.1 I clicked no this time for the pre-installed file and it proceeded to download it into Cross. I then choose all the options other than install GApps as I know this doesn't work and it rebooted very quickly.

I'm going to stop playing around now I promise as I've taken more than enough of your time :)
[Nexus 7 (2013) General] wstevew:
Install question.

I have DL all files and unzipped to C:\CROSS

CROSS2.ZIP

cross-update-v2.5.ZIP

I have also downloaded these

parted.rar

sysrepart.zip

sysrepart-flox.zip

sysrepart-max.zip

sysrepart-stock.zip

sysrepart-ultimate.zip

sysrepart-ultimate-2.zip

sysrepartundo.zip

Do I just place them into C:\CROSS as is or unzip them, or one of them?
[Nexus 7 (2013) General] k23m:
Just follow the top post's instructions.
[Nexus 7 (2013) General] wstevew:
Thanks,

I understand, they are if I want to execute using recovery.

And thanks to OP k23m, I now have 18.1 flox on my N7 flo 32gb
[Nexus 7 (2013) General] Valaran:
Hi ! Man this script is a blast ! I had trouble partitionning so i used restock them cross for flox, and all had gone flawless ! Thanks a lot !
[Nexus 7 (2013) General] 3dfxvoodoo:
Hi Friends, I flash the stock image with fastboot then use the script for Flox and I have the last nightly + TWRP in my old Nexus 7, Thanks a lot to the developer