yashsingh1/xdaforums huggingface dataset:
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] projectseahorse:
Hi,

Thank you so much for the help! I flashed the original TWRP 3.03 Recovery but was unable to boot into recovery mode. When I flash the original version, the flash was successful. However, when I was trying to boot into recovery, the screen was blank. I asked for help in the forum and another user told me the only one that works is this version, which is TWRP 3.0.2-2 signed. Below are the exchanges we had regarding this issue:

"Hi Oki,

Thanks for the tip, it helped a lot! I followed the instruction and was able to reach until step 23 where I needed to verify successful installation of TWRP by holding the volume up and the power button down sententiously for a couple of seconds. When I do this, it does not boot into recovery, it just turns off the phone instead of going into recovery menu. Everything else works fine. Does this mean that the installation was unsuccessful? What should I do? Thank you so much for the help!

PS: I think I should also mention that my device is not unlocked, could that be the cause? I'm currently on build B29 and all the unlock guides I found uses build B20 so I 'm not too sure how to unlock a build B29, any tips on that issue will also be greatly appreciate it! Many thanks and thank you for your kind help!

Response starts here: I am also in B29, with an A2017U. I found the same issue as you. But actually the system was not off, it was actually switching to edl mode because the recovery partition has a signature that doesn't match with the signature of the bootloader. So, the only way to do it is by flashing a signed TWRP. So the only one I have found is TWRP 3.0.2-2-signed by tenfar. just rename to recovery.bin and flash it with axon7tool +w recovery. That recovery will allow you to backup your Data partition before you unlock the boot loader.

Consider also doing a backup of the internal sdcard before unlocking the bootloader since unlocking the bootloader will corrupt all the data in the sdcard.

Be careful of not modifying the system partition, otherwise you will need to place again the stock recovery and flash the signed OTA ZIP files to recover the phone. "

Not to sure how to proceed from here as I'm very new to the whole flashing thing. Thank you guys so much!
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] lafester:
As far as I know you do need signed twrp with locked bl.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] projectseahorse:
I guess I'm just not understanding why I got the following error message when trying to install zip from sd card in twrp. It seems that everything else works fine.

Checking for Md5 file . . .

skipping MD5 check: no MD5 file found

assert failed: getprop("ro.product.name") == "p996a01

updater process ended with ERROR: 8

Error installing zip file "/external_sd/STEP-1-3-B20-FULL-OTA.zip

updating partition details . . .

. . . done

What could be triggering error 8 and how can I resolve it? Maybe if I flash the official TWRP 3.03? But since my BL is locked I need the signed version? (Sorry, I"m still super noob so I'm trying really hard to learn)Can anyone please guide me to the right places to get that?

thank you guys so much, this community is great! Happy holidays friends!
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] lafester:
You can't flash that file in twrp. Why are you trying to flash b20?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
just open the zip file and go to META-INF\........\....\ until you find updater-script

open that and remove the assert line and save

then flash it

use 7-zip for zip editing if you need
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] projectseahorse:
Hi Jcadduono,

thank you so much for the reply! I followed your instruction and navigated to the updater script you mentioned. I opened with MS words. Before I make any changes, I'd just like to confirm with you that I"m doing it right since I'm a noob (I'm really trying to learn everything by trial and error, I have no idea what I'm doing but I'm trying hard!) and your are an expert in this! I feel much better if I can run by your first~

So right now the only "assert" lines I found in the step 1 zip file is among these lines :

getprop("ro.product.device") == "ailsa_ii" || abort("This package is for "ailsa_ii" devices; this is a "" + getprop("ro.product.device") + "".");

assert(getprop("ro.product.name") == "P996A01");

ui_print("Target: ZTE/P996A01/ailsa_ii:6.0.1/MMB29M/20160707.171254:user/release-keys");

show_progress(0.850000, 180);

So you are saying that I should delete the entire second line, in particular the "assert(getprop("ro.product.name") == "P996A01");" line and deleted the space and save? And I should do that for the zip file for step 1, 2, 3 and 4 and 5 right? After that how do I make the change to be effective to the zip files? right now I have it unzipped with winrar and opening it directly from the winrar box. How can I do it so I can make the change? ( I suspect it has something to do with 7-zip so I have it downloaded and installed, but have not try to use it yet until I hear back from you first)

Thank you so much for your help and patience. I understand that it may be frustrated to answer stupid questions (and I'm sure some of my questions are probably just plain stupid), I'm really trying my best to learn everything as fast as possible! Thanks again everyone!
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
just remove that line like you said (in that file only), then flash it, then reboot back to recovery

you will then be in stock recovery instead of the broken signed twrp, and can continue on with any other steps.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] DrakenFX:
Before you even try to save the file, JUST DON'T.

Download and Install Notepad++ ,is the only one I recommend for you to Modified the "updater_script" or any other Android file ,other wise you'll end up with issues (I meant won't flash) when you try to flash the file.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] projectseahorse:
Hi DrakenFX,

Thank you so much, I have downloaded the notepad ++. So I just unzip the files as mentioned above. Right click on the files while it is still in the winrar box and chose open with notepad++ and I can saved it directly back to the zip file? Or do I have to extract all the files first in a folder, make the changes and zip all the files back into a zip?

Hi [MENTION=5672995]jcadduono[/MENTION],

I'm a little confused, am I suppose to only take out the "assert(getprop("ro.product.name") == "P996A01" from the first zip file only? Particularly the zip file named STEP_1_3-B20_FULL_OTA?

How about the rest of the zip files? In addition to the " STEP_1_3-B20_FULL_OTA" zip, there are also STEP_2-B20_UNLOCKABLE_BL zip, STEP_4-B20_to_B27 zip, and STEP_5-B27_to_B29 zip included in the unlock files. Do I need to take out "assert(getprop("ro.product.name") == "P996A01" from all the other zips as well?

Thank you all for your advises and guidance! Happy holidays to everyone here in the community!

---------- Post added at 07:10 PM ---------- Previous post was at 07:03 PM ----------

Hi lafester,

I'm trying to unlock the BL of my Axon 7 version B29 using the BL unlock kit provided by [MENTION=5672995]jcadduono[/MENTION] in this forum's first post and I was following the directions provided in the unlock kit. When I try to flash the first zip file I got that error message. Could it be that I'm doing something wrong or flashing something that I'm not suppose to? I'm really trying hard to not brick my phone (although I understand and accept the fact that there are always risks of bricking a device when messing with flashing and etc.)

Any advice, guidance is greatly appreciated! thank you very much for your time and help!
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] DrakenFX:
here i modded the file for you,

http://www.mediafire.com/file/1wx6hfw2n41tk60/META-INF.rar

YOU just need to Uncrompress that .rar file and replaced the old one with the new one....

use 7ZIP to compress it back just follow the next steps :

1- Select META-INF Folder (NEW ONE) and all the rest of the image files.

2- Right Click > 7-Zip > Add to Archive...

3-

Achive format : zip
Compression level : Normal
Compression method : Deflate
Dictionary size : 32 KB
Word size : 32

4- when is done , move the file to your device and flashed, at this point YOU'LL loose TWRP.

have fun with the rest of the guide.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] celoxocis:
ZTE actually provided us with new camera sensor blobs that work with AOSP base. You can look them up in the vendor repo history on Hax-on.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] tasar:
Is otg working in 3.0.3 here? On my oneplus 3 otg was broken with the new twrp.

Gesendet von meinem ZTE A2017U mit Tapatalk
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
Hello [MENTION=5672995]jcadduono[/MENTION],

For some reason, TWRP 3.0.3 fails when trying to flash the ZTE_A2017U.B29_StockSystem_by_DrakenFX.zip found in this post. On the other hand tenfar's signed TWRP 3.0.2-2 can flash it properly!!!!

It can be a problem in the ZIP file, but it can be also a bug in the new version 3.0.3. What do you think?

Thanks for your great work.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jimbo77:
What's the error you are getting? I'm on latest TWRP and I'm able to flash both boot stack and system with no issues
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
OK, after testing a little bit more, I have found the problem. When flashing that file with TWRP 3.0.3 the progress bar is always at 100% during all the time so it seemed as it was hanged. TWRP 3.0.2-2 signed shows a progressing progress bar. So the problem is a change in the progress bar behavior.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] JKSurf:
Flashed stock B29 from ZTE website. Stock recovery replaced TWRP. Fastboot command failed. Anyone know how I can get TWRP back?

"writing recovery failed

Remote unknown command"
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] shia786:
You will have to use the same method you used before as your bootloader isn't unlocked
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] JKSurf:
Sorry forgot to mention bootloader is unlocked. It seems the stock B29 blocks the recovery command.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] shia786:
Hmmm strange, maybe use [MENTION=243547]tel[/MENTION]nfer method to flash the recovery ?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jabeth407:
99% rooted but...

How is it possible that everything is good on the root but the "setuid attribute"?

I was using Root Explorer putting custom sounds into /system when the move failed. That caused me to use Root Checker which told me it didn't have the "root user account".

I used SuperSU to reinstall itself then rechecked it with Root Checker telling me everything is good, all in the green. I tried Root Explorer again with a slightly different failure, again. After looking into the details of the "root user ownership", I noticed it was missing its "setuid attribute". I also used Root Terminal to mount r/w /system, but that failed too. I logged diagnostics from Root Explorer, its developer told me, 'your device is rooted, my program calls for permissions and gets it'; then it fails.

I tried the bigger TWRP (not yours), that didn't work to install the su.zip. Took a little time to put recovery back to yours. Reinstalled the su, and that's where I'm at now. Testing the root user access of which a dozen programs are calling for and getting, I just can't write anything to the protected portions of the drive.

What a pain in the ass! Love the phone though!

---------- Post added at 11:27 PM ---------- Previous post was at 11:18 PM ----------

It didn't take all the way. I guess I'm going to have to take it back through the builds again. I've got a 99% rooted device that can't write anything to itself but everything else rooted works.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
Go to a terminal as root and type "reboot disemmcwp"

This tells the kernel to write a bit to somewhere in the ufs that tells the bootloader that next boot it should grant the kernel write access to protected partitions, including system.

I think it's a wonderful design. It's automatically disabled in recovery mode.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jabeth407:
Denied is trouble

My Root Terminal has su access, takes the su command no problem. However, when I use the cmd you've provided, I get a similar msg; 'reboot: Permission Denied'.

Do you think my dumb ass somehow messed up rewriting the builds, remember my conflict with recovery vs. bootstrap...

---------- Post added at 12:36 AM ---------- Previous post was at 12:29 AM ----------

How come TWRP's don't delve deeper into the drive's directories? Does it have something to do with my problem writing to the drive while the phone tells me I'm a superuser? I don't feel like one.

For instance; I can't get to the external SDcard through recovery. I can't get but one level into /system. I can't even see /storage or /mnt to find other paths to external storage.

All I want to do is add some files to my sound selections, is that so hard?

Damn big business and their infernal decisions, why can't all phones be rooted, or even better, not even have the concept of rooting.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] celoxocis:
Go to adb shell while in TWRP and enter:

adb reboot disemmcwp

Your kernel still has write protection enabled on those partitions. Like jcadduono said.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jabeth407:
I should've known

Thanks jcadduono for setting my slow ass straight. I started programming on 80x86 (&186) chipsets on IBM's & Tandy's (remember Radio Shack's computers?), before Apple II came out and I got away from it and didn't keep it up until I started using smartphones. My favorite is assembly, so tight, so portable! Now I'm playing catch up with quite a bit of time going over & over again.

And thanks to celoxocis for your input. I should of realized ADB would substitute the terminal somewhat, I wasn't thinking.

When I used your TWRP, I never noticed it has a (root, of course) terminal available. It's a good thing too because, the rooted(?) terminal emulator I have on the phone didn't quite get it.

As soon as I 'stumbled' upon your terminal, I used the command -=> POOF! Worked no problem.

Root Checker hasn't changed either, so the 'setuid attribute' didn't have anything to do with it as I'm sure you-all knew.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
To clarify that, it's not the kernel that has write protection :D It's actually bootloader level! The kernel just takes disemmcwp as an argument to reboot command as a hint to write the magic value and reboot so the bootloader can change the protection.

See: https://github.com/jcadduono/androi...0dbbaa6#diff-8b0f950df4f3b2bf90af319ffe98b201

You can make it *always* writable by adding a setup check in the kernel to check the emmcwp flag, then set write protection disabled bit and force a reboot, effectively double booting on each startup. I haven't added that feature but might if people want it.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] celoxocis:
This is actually interesting. I have a similar problem but i'm not sure if its related.

On my current project phone i successfully build TWRP but SuperSu is unable to write to the /data partition while installing systemless.

It keeps complaing about "Read only file system". Decryption of /data works and mounting too.

Could this somehow be related to the bootloader? (Bootloader is unlocked)

Installing SuperSu in "system mode works".

Here is the current discussion. https://xdaforums.com/showpost.php?p=70402963&postcount=290

If you could take a look at it jcadduono i can provide recovery.log and dmesg.log
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] gpz1100:
I was under the understanding that once the disemmcwp is executed, write permission remains between reboots until the enable write protection command is run - reboot enemmcwp (or whatever the enable command is)?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
Hi [MENTION=5672995]jcadduono[/MENTION],

I know you don't like F2FS, but after a few testing days, I am quite happy with the result. The only problem is the long load time for TWRP to boot. It is interesting since the system boot is not delayed at all, and the system is actually more agile when using F2FS.

But TWRP is very slow booting. This is the dmesg dump. It would be awesome if you could solve this issue. It doesn't happen in the TWRP for the LG G3 and Moto Z when both use F2FS.

By the way, I sent a PM to you regarding the F2FS patch. Thanks
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
this is normal for all devices, f2fs takes longer the more files you have on your /data partition. it's because disk usage checks on f2fs are really inefficient, where as they are really fast on ext4. whenever TWRP checks your disk usage (which happens on every boot, every wipe, etc.) it will take a long time. i think at some point it would be best for us to make the disk usage calculation have a thread of its own and update the UI/print to logs when its done. it should also happen with the G3 and Moto Z, maybe you just have less files on them?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
That was the issue, the LG G3 and Moto Z were empty, Axon 7 is my daily driver, I love it. However, the system boots quickly without taking that extra time to calculate the free space. Does the system use a separate thread for that?

By the way, have you read the PM I sent yo you?

Thanks
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
system doesn't care about it, the only reason TWRP does is for getting progress bars to work during backups and to show you the disk usage of each partition in backup pages.

for partitions other than data, an instant df call is fine, for data right now it calculates the size of everything, skipping over /data/media. this is why it takes so long. it could in theory just do a df call and then calculate /data/media size and subtract i guess. this would make it much faster i think.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
Who could implement it?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
me but im too lazy
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
I understand, programming is all about laziness. Programs just repeat things automatically so we do not have to go through those steps many times.

I'd do this mod myself, but I've never dig that much. By the way, why is this calculation done on boot? The result can be modified later by removing or adding files using the terminal, file manager or adb. Shouldn't it be done the first time you need that data, for instance when you are about to backing up or restore data?

Another nice addition to TWRP would be the possibility to backup and restore /data/media as if it was a partition.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jabeth407:
The "problem"

Mine seems opposite, SuperSU is writing everything but it doesn't quite get rooted permissions without any error kicking back. The root hasn't taken 100% on my phone, yet. Rebooting with 'dicemmcwp' did allow Root Explorer to r/w /system.

But some other root access programs are having mixed results. As I'm playing around with it, I use Root Terminal Emulator which gives me no change when moving into 'su', the '$' doesn't change into '#' and when mounting r/w onto part of the drive (say, /data or /system) it tells me I'm denied. I don't know if this matters, it is just different between TWRP's terminal and the Emulator's.

Hex Editor Pro tells me "write failed: EBDAF Bad file descriptor" when I try to give it root access. It refuses to write into any part of /data or /system.

Root Logger Pro tells me it cannot install BASH as I'm not rooted, check your root it says, in as far as I'm able to, it seems 100% but is really 99 or 99.9% rooted.

Everything has SuperSU permission and I've used TWRP terminal to boot with write permission while getting SuperSU to reinstall hoping that would give it more power to write. I tried the same thing for each of the abovementioned programs with exactly the same results.

---------- Post added at 06:45 AM ---------- Previous post was at 06:38 AM ----------

My early post #111 I mentioned not being able to gain access to SDcard, the actual one through TWRP.

After I used its terminal with rebooting disemmcwp permissions, the SDcard has opened up access to it.

Before I could see it in selections but couldn't get it to switch or change over. Now it does. Is there another level of write permissions in the bootstrap?

I think there must be two different areas of protection, one is written into the other isn't and the conflict isn't something all rooting programs are subject to because of the way they're getting "permission"... am I even close?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jawz101:
@JKSurf did you ever get this to work for you? I'm stuck in the same boat.

I'd unlocked my bootloader months ago using Tenfar's tool, installed CM13, and then decided to go back to stock for a little while - used the official OTA update from ZTE's product page.... but remembered I don't like stock 0_o.

Now, in bootloader mode when I try to do a fastboot flash recovery twrp....img I get

C:\zte\root>fastboot flash recovery twrp-3.0.3-0-ailsa_ii.img
< waiting for any device >
target reported max download size of 536870912 bytes
sending 'recovery' (16628 KB)...
OKAY [ 0.562s]
writing 'recovery'...
FAILED (remote: unknown command)
finished. total time: 0.593s

C:\zte\root>

I'm afraid we're going to see more instances of this if people decide to go back to stock when ZTE upgrades to Nougat, change their mind and then want to go back to a custom ROM... just like we've done.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] JKSurf:
Yeah.

Downloaded stock B20 and placed on SD card. Flashed stock B20 with stock recovery.

Rebooted

Use Tenfars root tool just like we did last time.

Use tenfars TWRP to flash official TWRP.

Restored from an old backup.

Flashed Drakkens boot stack.

Good luck fellow flashaholic!
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jawz101:
Thanks. Whew!

Did that roll back your baseband, btw? Mine is currently at

M8996FAAAANAZM-1.68528.1.71432.1
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] JKSurf:
Yeah mine is the same. Running CM at the moment. I haven't had the need to do any fastboot commands so not sure if that is still affected.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jawz101:
All I know is if ZTE remains this inconvenient about switching ROMs it will be my first and last ZTE device.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jawz101:
[MENTION=6827653]JKSurf[/MENTION] where did you get the b20 image ?
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] JKSurf:
https://xdaforums.com/axon-7/development/axon-7-chinese-stock-roms-t3436817

Full OTA thread in the Mega link.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] jcadduono:
It's also in the first post of this thread :|
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Oki:
There is no problem switching Roms. You can find all the stock Roms in this forum here.
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] Killerdog:
Hi, Did you know how i can revert System modification.

I following this guide for update twrp and don’t allow System modification, now i can’t use viper or xposed.

Not sure if it have a relation but i think.

Thanks

Envoyé de mon ZTE A2017G en utilisant Tapatalk
[ZTE Axon 7 ROMs, Kernels, Recoveries, & Other Deve] chas123:
Is there a mirror for the unlock kit in the 1st post? The server keeps kicking me off halfway through the download.