Hey I need help updating my phone. Using a SM-G900v, noticed I had an update for my device. I've downloaded the singed file but where can I find it to install in TWRP?
Simon.SJC said:
Hey I need help updating my phone. Using a SM-G900v, noticed I had an update for my device. I've downloaded the singed file but where can I find it to install in TWRP?
Click to expand...
Click to collapse
Should boot to TWRP, and update automatically. If not the file is here:
/data/data/org.lineageos.updater/app_updates
jhedfors said:
Should boot to TWRP, and update automatically. If not the file is here:
/data/data/org.lineageos.updater/app_updates
Click to expand...
Click to collapse
I searched that on ES File Explorer, also in recovery mode. Got nothing. I think I'm gonna have to download it manually by PC/laptop. Is there a way to not lose data while updating? I'm clearly a noob @ this. This is my first phone with a custom ROM and recovery.
Simon.SJC said:
I searched that on ES File Explorer, also in recovery mode. Got nothing. I think I'm gonna have to download it manually by PC/laptop. Is there a way to not lose data while updating? I'm clearly a noob @ this. This is my first phone with a custom ROM and recovery.
Click to expand...
Click to collapse
You would need a file explorer with root access to find the file while booted. However the file is definitely accessible via TWRP, and is definitely there of you see "INSTALL" in the updater. Just make sure you get the path right - it is not in the "SDCARD" directory - you will need to go up to the root directory first, before going to data/data/...etc.
I think there is an existing bug affecting some some devices regarding the recovery script that should allow this to happen automatically.
Just dirty flash - as long as you are not explicitly/intentionally wiping data partition, your data will be fine.
jhedfors said:
You would need a file explorer with root access to find the file while booted. However the file is definitely accessible via TWRP, and is definitely there of you see "INSTALL" in the updater. Just make sure you get the path right - it is not in the "SDCARD" directory - you will need to go up to the root directory first, before going to data/data/...etc.
I think there is an existing bug affecting some some devices regarding the recovery script that should allow this to happen automatically.
Just dirty flash - as long as you are not explicitly/intentionally wiping data partition, your data will be fine.
Click to expand...
Click to collapse
Awesome. Probably is a bug, I'll try later today. Thanks
I'm trying for a month ago and nothing
pecko18 said:
I'm trying for a month ago and nothing
Click to expand...
Click to collapse
Trying what for a month?
Signing Issue
jhedfors said:
Trying what for a month?
Click to expand...
Click to collapse
Maybe jhedfors could help out in my case too..
I upgraded my unlocked rooted Sony Experia V from Cm to LineageOS by following instructions given to use experimental first & then upgrade to first real LineageOS. After that I only get Signature error, update aborted. This goes for all updates except the first.
So i sideloaded (adb) latest update, No problems doing this.. Then I tried to update to latest lineage-14.1-20170324-nightly-tsubasa-signed.zip ( Today) & got this signing issue again. Seems like I have to sideload all updates..
Verifying Downloaded file gives wiki.lineageos.org/verifying-builds.html
~/Desktop# keytool -list -printcert -jarfile lineage-14.1-20170324-nightly-tsubasa-signed.zip
Signer #1:
Signature:
Owner: CN=LineageOS, OU=LineageOS, O=LineageOS, L=Seattle, ST=Washington, C=US
Issuer: CN=LineageOS, OU=LineageOS, O=LineageOS, L=Seattle, ST=Washington, C=US
Serial number: xxxxxxxxxxxx
Valid from: Sat Jan 07 05:21:25 CET 2017 until: Wed May 25 06:21:25 CEST 2044
Certificate fingerprints:
MD5: F2:CA:AA:A7:2F6:34:FE:707:5C:41:43:6C:5E:14
SHA1: 9B:6D:F9:06:2A:1A:76:E6:E0:07:B1:1F:C2:EF:CB:EF:4B:32:F2:23
SHA256: 51:83:25:EF:7F:96:C01:19:4C:2E:85:6B:04:0D:63:61:66:FF:B8:46:71:7D:72:FA:87:F4:FA:E5:BE:7B:BB
Signature algorithm name: SHA1withRSA
Version: 3
Extensions:
#1: ObjectId: 2.5.29.35 Criticality=false
AuthorityKeyIdentifier [
KeyIdentifier [
0000: 72 96 32 27 D6 6C 4C 4D 5F A0 91 6A C2 2C 79 3C r.2'.lLM_..j.,y<
0010: D4 5F 43 5C ._C\
]
]
#2: ObjectId: 2.5.29.19 Criticality=false
BasicConstraints:[
CA:true
PathLen:2147483647
]
#3: ObjectId: 2.5.29.14 Criticality=false
SubjectKeyIdentifier [
KeyIdentifier [
0000: 72 96 32 27 D6 6C 4C 4D 5F A0 91 6A C2 2C 79 3C r.2'.lLM_..j.,y<
0010: D4 5F 43 5C ._C\
]
]
Nordlenning said:
Maybe jhedfors could help out in my case too..
I upgraded my unlocked rooted Sony Experia V from Cm to LineageOS by following instructions given to use experimental first & then upgrade to first real LineageOS. After that I only get Signature error, update aborted. This goes for all updates except the first.
So i sideloaded (adb) latest update, No problems doing this.. Then I tried to update to latest lineage-14.1-20170324-nightly-tsubasa-signed.zip ( Today) & got this signing issue again. Seems like I have to sideload all updates..
Verifying Downloaded file gives wiki.lineageos.org/verifying-builds.html
~/Desktop# keytool -list -printcert -jarfile lineage-14.1-20170324-nightly-tsubasa-signed.zip
Signer #1:
Signature:
Owner: CN=LineageOS, OU=LineageOS, O=LineageOS, L=Seattle, ST=Washington, C=US
Issuer: CN=LineageOS, OU=LineageOS, O=LineageOS, L=Seattle, ST=Washington, C=US
Serial number: xxxxxxxxxxxx
Valid from: Sat Jan 07 05:21:25 CET 2017 until: Wed May 25 06:21:25 CEST 2044
Certificate fingerprints:
MD5: F2:CA:AA:A7:2F6:34:FE:707:5C:41:43:6C:5E:14
SHA1: 9B:6D:F9:06:2A:1A:76:E6:E0:07:B1:1F:C2:EF:CB:EF:4B:32:F2:23
SHA256: 51:83:25:EF:7F:96:C01:19:4C:2E:85:6B:04:0D:63:61:66:FF:B8:46:71:7D:72:FA:87:F4:FA:E5:BE:7B:BB
Signature algorithm name: SHA1withRSA
Version: 3
Extensions:
#1: ObjectId: 2.5.29.35 Criticality=false
AuthorityKeyIdentifier [
KeyIdentifier [
0000: 72 96 32 27 D6 6C 4C 4D 5F A0 91 6A C2 2C 79 3C r.2'.lLM_..j.,y<
0010: D4 5F 43 5C ._C\
]
]
#2: ObjectId: 2.5.29.19 Criticality=false
BasicConstraints:[
CA:true
PathLen:2147483647
]
#3: ObjectId: 2.5.29.14 Criticality=false
SubjectKeyIdentifier [
KeyIdentifier [
0000: 72 96 32 27 D6 6C 4C 4D 5F A0 91 6A C2 2C 79 3C r.2'.lLM_..j.,y<
0010: D4 5F 43 5C ._C\
]
]
Click to expand...
Click to collapse
Not completely sure, but you could try this if you still have the migration build...
1. Backup
2. Flash migration build
3. Flash latest nightly
I seem to recall there was an issue with the signing a few weeks ago that could have messed you up. Just a wild guess however...
jhedfors said:
Not completely sure, but you could try this if you still have the migration build...
1. Backup
2. Flash migration build
3. Flash latest nightly
I seem to recall there was an issue with the signing a few weeks ago that could have messed you up. Just a wild guess however...
Click to expand...
Click to collapse
I tried to flash 3rd or 4th update from migration build, but that did not work.
Maybe I have to settle with fewer updates with adb sideload.
Thanks for reply
Nordlenning said:
I tried to flash 3rd or 4th update from migration build, but that did not work.
Maybe I have to settle with fewer updates with adb sideload.
Thanks for reply
Click to expand...
Click to collapse
... It is not so bad to clean wipe once in a while either
Since I already have lineage-14.1-20170317 installed & get this error trying to update to lineage-14.1-20170324 this seems strange.
What connection is there to the migration build & the signing of new builds & I have sideloaded latest zip update... Hmmm
Just curious..
Nordlenning said:
Since I already have lineage-14.1-20170317 installed & get this error trying to update to lineage-14.1-20170324 this seems strange.
What connection is there to the migration build & the signing of new builds & I have sideloaded latest zip update... Hmmm
Just curious..
Click to expand...
Click to collapse
I wish i could tell you. Maybe it could be helpful if you could attach recovery logs that show the error when attempting to flash. If it is signature verification error, I can only think that a clean flash can fix it. I have seen it suggested before to disable zip verification in TWRP...
jhedfors said:
recovery logs show the error when attempting to flash. ...
Click to expand...
Click to collapse
Where can I locate those logs, names? from TWRP , I have disabled zip verification in TWRP to no effect.
Nordlenning said:
Where can I locate those logs, names? from TWRP , I have disabled zip verification in TWRP to no effect.
Click to expand...
Click to collapse
Under Advanced menu in TWRP. Select copy logs, and it will place them in the root of your sdcard directory.
This from recovery.log
|:Set page: 'flash_zip'
I;operation_start: 'Flashing'
Installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Checking for MD5 file...
Skipping MD5 check: no MD5 file found
minzip: Not a Zip archive (found 0xb919c702)
minzip: Parsing archive 0xb493f5f4 failed
Zip file is corrupt!
Error installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Updating partition details...
**************************
I;operation_start: 'Flashing'
Installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Checking for MD5 file...
Skipping MD5 check: no MD5 file found
Verifying zip signature...
I:read key e=3 hash=20
I:1 key(s) loaded from /res/keys
E:footer is wrong
I:Zip signature verification failed: 1
Zip signature verification failed!
Error installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Updating partition details...
Nordlenning said:
This from recovery.log
|:Set page: 'flash_zip'
I;operation_start: 'Flashing'
Installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Checking for MD5 file...
Skipping MD5 check: no MD5 file found
minzip: Not a Zip archive (found 0xb919c702)
minzip: Parsing archive 0xb493f5f4 failed
Zip file is corrupt!
Error installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Updating partition details...
**************************
I;operation_start: 'Flashing'
Installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Checking for MD5 file...
Skipping MD5 check: no MD5 file found
Verifying zip signature...
I:read key e=3 hash=20
I:1 key(s) loaded from /res/keys
E:footer is wrong
I:Zip signature verification failed: 1
Zip signature verification failed!
Error installing zip file '/data/data/org.lineageos.updater/app_updates/lineage-14.1-20170324-nightly-tsubasa-signed.zip'
Updating partition details...
Click to expand...
Click to collapse
Yeah, something odd for sure is going on that I am not sure you are going to resolve without clean flash. You could backup, and try to clean flash, and then test if you can flash on top if that. Sorry, I don't have any other suggestion. Something could have gotten corrupted in your data.
Do you have an updated TWRP version?
Do you have an updated TWRP version?
I'm using TWRP 3.1.0.0
EDIT
Just wiped & formatted my installation & installed Latest LOS with TWRP.
No problems observed. Latest installed & working with root..
So the waiting game begins until next update
thank you
thank you so much
Nordlenning said:
Since I already have lineage-14.1-20170317 installed & get this error trying to update to lineage-14.1-20170324 this seems strange.
What connection is there to the migration build & the signing of new builds & I have sideloaded latest zip update... Hmmm
Just curious..
Click to expand...
Click to collapse
I kept getting zip verification fail on latest builds of LOS13 and LOS14 on Samsung S4 Mini, which I couldn't understand, anyhow it turned out to be TWRP 3.0.3-3 I was using which I had recently updated as well. Previous TWRP ver I used, 3.0.1, worked fine. Anyhow, I updated TWRP to 3.1.0 (which is still a test ver on my S4 Mini) and it flashed the Linage ROM's no problem. What ver of TWRP you on?
Edit: oh now see you are on latest TWRP
Related
I was flashing my yakjuxw over to yakju, when fastboot started failing to load system.img.
I have tried 4.0.2 and 4.0.1. Every image except for system.img works.
Code:
[[email protected] yakju-itl41f]# fastboot flash system system.img
error: cannot load 'system.img'
And it doesn't work using the zip either;
Code:
[[email protected] yakju-itl41f]# fastboot update *.zip
archive does not contain 'boot.sig'
archive does not contain 'recovery.sig'
failed to allocate 325426112 bytes
error: update package missing system.img
I am running Archlinux.
Somewhere in the ./flash-all.sh script my ``sdcard'' was wiped, so I've lost my nandroid(s), but I can boot CWM from my PC. Help?
Open the zip file in a explorer-window somewhere and locate the system.img file and then try the first one over again.
None of these files are magic and they are pretty easy to explore to find the components you are looking for.
Are you sure you've unpacked things correctly?
What does the output from "ls -la" run in the the same folder say?
josteink said:
Open the zip file in a explorer-window somewhere and locate the system.img file and then try the first one over again.
None of these files are magic and they are pretty easy to explore to find the components you are looking for.
Are you sure you've unpacked things correctly?
What does the output from "ls -la" run in the the same folder say?
Click to expand...
Click to collapse
I unpacked the zip, so all the images in it are in this folder, but here's the output:
Code:
[[email protected] yakju-itl41f]# ls -la
total 663156
drwxr-x--- 2 david users 4096 Jan 18 20:17 .
drwxr-xr-x 4 david users 4096 Jan 18 20:07 ..
-rw-r----- 1 david users 93 Nov 21 18:20 android-info.txt
-rw-r--r-- 1 david users 4151296 Jan 1 2009 boot.img
-rw-r----- 1 david users 2363392 Nov 24 09:44 bootloader-maguro-primekj10.img
-rwxr-x--- 1 david users 831 Nov 24 09:44 flash-all.sh
-rw-r----- 1 david users 189165717 Nov 24 09:44 image-yakju-itl41f.zip
-rw-r----- 1 david users 12583168 Nov 24 09:44 radio-maguro-i9250xxkk1.img
-rw-r--r-- 1 david users 4491264 Jan 1 2009 recovery.img
-rwxrwxrwx 1 david users 325426112 Jan 1 2009 system.img
-rw------- 1 david users 140856312 Nov 22 11:09 userdata.img
Did you actually ever unlock fast boot? Just guessing here, at this point.
Sent from my Galaxy Nexus using Tapatalk
redownload stock images?
just an update, this is solved. The solution was found in rebooting my pc, which is something I, as a Linux user, seldom do, and my laptop cannot be trusted to boot due to its buggy BIOS.
Sent from my Galaxy Nexus
Korntoff said:
just an update, this is solved. The solution was found in rebooting my pc, which is something I, as a Linux user, seldom do, and my laptop cannot be trusted to boot due to its buggy BIOS.
Sent from my Galaxy Nexus
Click to expand...
Click to collapse
Ridiculously old thread, I realize, so I feel kinda bad bumping it, but it's an early result on Google when searching for this problem, so I'll update a bit.
Rebooting will work, but isn't necessary, and is inconvenient. You just need to kill fastboot, it's hung with another process.
In linux, open up a terminal.
Code:
ps ax|grep fastboot
Note the PID(s)
Code:
kill -9 <PID1> <PID2>...<PIDn>
Another reason for this error is if you have device encryption enabled. In order to restore factory image, you first need to format /data to remove encryption.
I have no idea why this causes the error "cannot load system.img", but it definitely does.
Cerinthus said:
Ridiculously old thread, I realize, so I feel kinda bad bumping it,
In linux, open up a terminal...
Click to expand...
Click to collapse
Thanks for posting this.
In windows, I used task manager to find the ADB process and killed it, and then it worked fine.
groopk said:
Thanks for posting this.
In windows, I used task manager to find the ADB process and killed it, and then it worked fine.
Click to expand...
Click to collapse
To do this without searching thought task manager , just type "adb kill server " and then " adb start server" :thumbup:
Sent from my SCH-I605 using Tapatalk
quite an old thread again, but replying anyway.
The "failed to allocate ***** bytes" message means that it failed on memory of your computer, not on the storage of your phone.
Code:
fastboot.c
...
void *unzip_file(zipfile_t zip, const char *name, unsigned *sz)
{
...
*sz = get_zipentry_size(entry);
datasz = *sz * 1.001;
data = malloc(datasz);
if(data == 0) {
fprintf(stderr, "failed to allocate %d bytes\n", *sz);
return 0;
}
...
If it turns out that your machine has too small memory(unfortunately, which was also my case), you could unzip the file containing img files and flash system, boot and recovery images one by one. It's just the same.
great help
On the verge of flashing lolipop on my beloved n5, I got stuck with that stupid errror.
Thanks for the helpfull post.
downgrade to 4.4.4
just downgrade to 4.4.4 and then flash android 5.... mine worked....
FreakyTux said:
quite an old thread again, but replying anyway.
The "failed to allocate ***** bytes" message means that it failed on memory of your computer, not on the storage of your phone.
Code:
fastboot.c
...
void *unzip_file(zipfile_t zip, const char *name, unsigned *sz)
{
...
*sz = get_zipentry_size(entry);
datasz = *sz * 1.001;
data = malloc(datasz);
if(data == 0) {
fprintf(stderr, "failed to allocate %d bytes\n", *sz);
return 0;
}
...
If it turns out that your machine has too small memory(unfortunately, which was also my case), you could unzip the file containing img files and flash system, boot and recovery images one by one. It's just the same.
Click to expand...
Click to collapse
This was it! Thanks for posting!
Update ADB. That worked for me
same problem
i tried everything above but nothing works ..... can anyone help me out here
Alternate Way that always works..!!
1. Install TWRP recovery.
2. Mount USB Storage
3. Copy the system.img to phone storage
4. Select Install and then Select Install Image
5. Select the system.img file
6. Select partition as system
7. Confirm install
Done..
Korntoff said:
I was flashing my yakjuxw over to yakju, when fastboot started failing to load system.img.
I have tried 4.0.2 and 4.0.1. Every image except for system.img works.
Code:
[[email protected] yakju-itl41f]# fastboot flash system system.img
error: cannot load 'system.img'
And it doesn't work using the zip either;
Code:
[[email protected] yakju-itl41f]# fastboot update *.zip
archive does not contain 'boot.sig'
archive does not contain 'recovery.sig'
failed to allocate 325426112 bytes
error: update package missing system.img
I am running Archlinux.
Somewhere in the ./flash-all.sh script my ``sdcard'' was wiped, so I've lost my nandroid(s), but I can boot CWM from my PC. Help?
Click to expand...
Click to collapse
rakesh.aggarwal said:
1. Install TWRP recovery.
2. Mount USB Storage
3. Copy the system.img to phone storage
4. Select Install and then Select Install Image
5. Select the system.img file
6. Select partition as system
7. Confirm install
Done..
Click to expand...
Click to collapse
with lots of thanks and much love!! fixed my device yeeyyyy!!!!
Hey guys
I have a BIG problem with TWRP.
I have a CM13 installed but since nightly 19.12.2015 my phone won't flash the update correctly. It's stock on this :
Updating partition details
...done
Full SELinux support is present
Installing '/sdcard/CM_Downloader/cm13.0-20151221-NIGHTLY-D855.zip...
Checking for MD5 file...
Skipping MD5 check: no MD5 file found
Target : lge/g3_global_com/g3:5.0/LRX21R.A149207951/1419207951:user/relase-keys
detected filesystem ext4 for /dev/block/platform/msm_sdcc.1/by-name/system
So i tried to reinstall the TWRP but didn't work.
Can someone help me ?
Wipe System Partion and see if it still gives the same error
i try to install the zip on twrp the error i got is
cheaking for md5 file.....
skipping mds cheak : no md5 file found
RED (E :Error executing updater binary in zip sdcard/xposed-v86-sdk21-x86.zip
error flashing zip sdcard\xposted.zip
updating partition details.
done.
FAILD
what i do wrong? :/
Korskyn said:
i try to install the zip on twrp the error i got is
cheaking for md5 file.....
skipping mds cheak : no md5 file found
RED (E :Error executing updater binary in zip sdcard/xposed-v86-sdk21-x86.zip
error flashing zip sdcard\xposted.zip
updating partition details.
done.
FAILD
what i do wrong? :/
Click to expand...
Click to collapse
U try to install the x86 version of Xposed on M9, which is a arm64 system.
Get the ARM64 version!
Also, check SDK version: SDK21 is Android 5.0 (Lollipop), SDK22 is Android 5.1 (also Lollipop) and SDK23 is Android 6.0 (Marshmallow).
A good place to start reading is here:
http://forum.xda-developers.com/showthread.php?t=3034811
Good luck!
Fain11 said:
U try to install the x86 version of Xposed on M9, which is a arm64 system.
Get the ARM64 version!
Also, check SDK version: SDK21 is Android 5.0 (Lollipop), SDK22 is Android 5.1 (also Lollipop) and SDK23 is Android 6.0 (Marshmallow).
A good place to start reading is here:
http://forum.xda-developers.com/showthread.php?t=3034811
Good luck!
Click to expand...
Click to collapse
thanks for your post!
i've tryed befor the 64arm sdk21 but its faild to the error i had is
full selinux support is present
installing sdcard/xposed-v86-sdk21-arm64.zip
cheaking for md5 file
skipping md5 cheak : no md5 file found
xposed freamework installer zip
mouting system and vendor read write mount : cant find system in proc mounts
faild system could not be mounted
E: ERROR executing updater binary in zip 'sdcard\xposted\v86-sdk21-arm64.zip
error flashing zip sdcard\xposted-v86-sdk21-arm64.zip
updateing partition detalis
Korskyn said:
thanks for your post!
i've tryed befor the 64arm sdk21 but its faild to the error i had is
full selinux support is present
installing sdcard/xposed-v86-sdk21-arm64.zip
cheaking for md5 file
skipping md5 cheak : no md5 file found
xposed freamework installer zip
mouting system and vendor read write mount : cant find system in proc mounts
faild system could not be mounted
E: ERROR executing updater binary in zip 'sdcard\xposted\v86-sdk21-arm64.zip
error flashing zip sdcard\xposted-v86-sdk21-arm64.zip
updateing partition detalis
Click to expand...
Click to collapse
This one has another error, your system partition is not mounted read&write.
U should do that in TWRP.
Before that, do a backup including a system image, if u are stock, this will help if u go into trouble.
Good luck!
As this questions pops up every single month, I'm putting this information into a separate topic. It is for everyone who followed the Magisk A/B OTA update guide and OTA update still fails to install. https://github.com/topjohnwu/Magisk/blob/master/docs/tutorials.md
The usual culprit is TWRP - if you booted into TWRP and allowed system modifications (even once), OTA update won't install. The second common suspect is one of apps with root access, which might have tampered the system partition (AdAway or some other old apps).
Use these commands as root from ADB shell or terminal emulator on the phone and look for mount count (has to be 0) and last mount time (must be n/a). Anything else means that system partition has been mounted as R/W and you MUST reflash stock system.img manually.
Code:
[I][B]tune2fs -l /dev/block/sda12
tune2fs -l /dev/block/sda13[/B][/I]
sda12 is system_a, sda13 is system_b
Example of untouched system:
Code:
Filesystem created: Wed Dec 31 17:00:00 2008
Last mount time: n/a
Last write time: Wed Dec 31 17:00:00 2008
Mount count: 0
Maximum mount count: -1
Last checked: Wed Dec 31 17:00:00 2008
How to fix - reflash system.img with the same version as currently running (or reflash everything with newer ROM):
Option #1
- download full OTA zip (not the incremental one, size must be above 1gb)
- and this Windows tool https://androidfilehost.com/?fid=818070582850510260
- extract both and put payload.bin into payload_input folder. Then run payload_dumper.exe. Once it completes the job, you'll find all images which can be flashed via fastboot.
- flash system.img to the active partition
- install OTA update
Option #2
- set A as active partition
- download, extract and run flash_all_except_data_storage.bat from stock Fastboot ROM
- root with Magisk patched boot.img and apply OTA with the usual Magisk A/B OTA procedure
Before flashing, backup your important data, one can be never sure enough.
flash_all_except_storage.bat = flash_all_except_data_storage.bat
I have a few questions about this method of yours.
1) I downloaded the fastboot rom from this thread but I can't find the payload.bin mentioned in the first method. Did I download the right thing? All I can see are *.img files and system.img is there too. Can I flash that one?
2) I have both TWRP and magisk installed currently. Will I lose them if I follow your method? How should I go if I wanted to keep them?
3) Of course you advice us to make a backup beforehand. Can you tell me or link me a guide about how to backup and restore properly with the new A/B partion in the way?
I'm sorry for asking this much, but all the guides I'm following are either confusing or with conflicting info.
Thank you for the help, I just can't wrap my head around this dual partion thing :s
SirAugustin said:
I have a few questions about this method of yours.
1) I downloaded the fastboot rom from this thread but I can't find the payload.bin mentioned in the first method. Did I download the right thing? All I can see are *.img files and system.img is there too. Can I flash that one?
2) I have both TWRP and magisk installed currently. Will I lose them if I follow your method? How should I go if I wanted to keep them?
3) Of course you advice us to make a backup beforehand. Can you tell me or link me a guide about how to backup and restore properly with the new A/B partion in the way?
I'm sorry for asking this much, but all the guides I'm following are either confusing or with conflicting info.
Thank you for the help, I just can't wrap my head around this dual partion thing :s
Click to expand...
Click to collapse
1. Fastboot ROM can be used straight away (Option #2).
2. Well, the point of this guide is to restore phone to stock images, so you can install OTA update. TWRP can't be kept. You can flash Magisk without TWRP though.
3. Titanium backup pro is my #1 backup tool for years, except very few exceptions it can backup and restore all apps and their settings. Data partition is only one, so you might have luck using TWRP backup - I haven't tried it.
Thank you kindly for all the info. These days I will try the method you described. ?
_mysiak_ said:
As this questions pops up every single month, I'm putting this information into a separate topic. It is for everyone who followed the Magisk A/B OTA update guide and OTA update still fails to install. https://github.com/topjohnwu/Magisk/blob/master/docs/tutorials.md
The usual culprit is TWRP - if you booted into TWRP and allowed system modifications (even once), OTA update won't install. The second common suspect is one of apps with root access, which might have tampered the system partition (AdAway or some other old apps).
Use these commands as root from ADB shell or terminal emulator on the phone and look for mount count (has to be 0) and last mount time (must be n/a). Anything else means that system partition has been mounted as R/W and you MUST reflash stock system.img manually.
Code:
[I][B]tune2fs -l /dev/block/sda12
tune2fs -l /dev/block/sda13[/B][/I]
sda12 is system_a, sda13 is system_b
Example of untouched system:
Code:
Filesystem created: Wed Dec 31 17:00:00 2008
Last mount time: n/a
Last write time: Wed Dec 31 17:00:00 2008
Mount count: 0
Maximum mount count: -1
Last checked: Wed Dec 31 17:00:00 2008
How to fix - reflash system.img with the same version as currently running (or reflash everything with newer ROM):
Option #1
- download full OTA zip (not the incremental one, size must be above 1gb)
- and this Windows tool https://androidfilehost.com/?fid=818070582850510260
- extract both and put payload.bin into payload_input folder. Then run payload_dumper.exe. Once it completes the job, you'll find all images which can be flashed via fastboot.
- flash system.img to the active partition
- install OTA update
Option #2
- set A as active partition
- download, extract and run flash_all_except_data_storage.bat from stock Fastboot ROM
- root with Magisk patched boot.img and apply OTA with the usual Magisk A/B OTA procedure
Before flashing, backup your important data, one can be never sure enough.
Click to expand...
Click to collapse
I tried method 1, OTA installation still shows Error message
What next?
oseraphaels said:
I tried method 1, OTA installation still shows Error message
What next?
Click to expand...
Click to collapse
If you are running custom kernel, flash the stock boot.img to boot partition as well.
oseraphaels said:
I tried method 1, OTA installation still shows Error message
What next?
Click to expand...
Click to collapse
Was your system partition mounted as RW in the first place? Is it still untouched? Some apps with root access can still mount it as RW, even if you reflash system.img.
Frank.G said:
If you are running custom kernel, flash the stock boot.img to boot partition as well.
Click to expand...
Click to collapse
I have stock boot img running, still ota install failed
---------- Post added at 10:25 AM ---------- Previous post was at 10:22 AM ----------
_mysiak_ said:
Was your system partition mounted as RW in the first place? Is it still untouched? Some apps with root access can still mount it as RW, even if you reflash system.img.
Click to expand...
Click to collapse
I fastboot flash_all.bat , I think this should mount all ROM segments, including system partitions
I fast boot flashed the latest ROM v11.0.15 and it works perfectly.
_mysiak_ said:
Was your system partition mounted as RW in the first place? Is it still untouched? Some apps with root access can still mount it as RW, even if you reflash system.img.
Click to expand...
Click to collapse
I can't find any apps that may be mounting system partition.
Is there a way to find out?
oseraphaels said:
I can't find any apps that may be mounting system partition.
Is there a way to find out?
Click to expand...
Click to collapse
Yes, compare the last mount timestamp and Magisk log. You will see which app used root access at that time.
oseraphaels said:
As this questions pops up every single month, I'm putting this information into a separate topic. It is for everyone who followed the Magisk A/B OTA update guide and OTA update still fails to install. https://github.com/topjohnwu/Magisk/blob/master/docs/tutorials.md
The usual culprit is TWRP - if you booted into TWRP and allowed system modifications (even once), OTA update won't install. The second common suspect is one of apps with root access, which might have tampered the system partition (AdAway or some other old apps).
Use these commands as root from ADB shell or terminal emulator on the phone and look for mount count (has to be 0) and last mount time (must be n/a). Anything else means that system partition has been mounted as R/W and you MUST reflash stock system.img manually.
sda12 is system_a, sda13 is system_b
Example of untouched system:
I tried method 1, OTA installation still shows Error message
What next?
Click to expand...
Click to collapse
Flash ota ROM in recovery
Rajendran Rasa said:
Flash ota ROM in recovery
Click to expand...
Click to collapse
Thank you very much
I fastboot flashed the latest ROM and my device works perfectly
Hi,
I have similar issue. My current version is V11.0.1.0.QFQEUXM. The system update show can't install update.
I get the stock version of V11.0.1.0.QFQEUXM fastboot room, and get the system.img. Then I flash it into my current active slot - b. After reboot, I still get can't install update.
The specific error is W update_engine: [0615/084826.432657:WARNING:mount_history.cc(66)] Device was remounted R/W 1 times. Last remount happened on 2020-05-15 10:30:34.000 UTC.
The remount is cause by TWRP.
Is there other suggestion?
Flash ota ROM in recovery
Click to expand...
Click to collapse
Tried to sideload V11.0.2.0.QFQEUXM OTA.zip, but error also.
Thanks.
JackVoo said:
Hi,
I have similar issue. My current version is V11.0.1.0.QFQEUXM. The system update show can't install update.
I get the stock version of V11.0.1.0.QFQEUXM fastboot room, and get the system.img. Then I flash it into my current active slot - b. After reboot, I still get can't install update.
The specific error is W update_engine: [0615/084826.432657:WARNING:mount_history.cc(66)] Device was remounted R/W 1 times. Last remount happened on 2020-05-15 10:30:34.000 UTC.
The remount is cause by TWRP.
Is there other suggestion?
Tried to sideload V11.0.2.0.QFQEUXM OTA.zip, but error also.
Thanks.
Click to expand...
Click to collapse
You've found the culprit already.. Do NOT use TWRP to flash images, it must be done via fastboot.
_mysiak_ said:
You've found the culprit already.. Do NOT use TWRP to flash images, it must be done via fastboot.
Click to expand...
Click to collapse
Hi, the remount is at 15-May. Which I try to fix this issue.
I use fastboot to flash the system.img, but it still mentioned about "remount R/W".
After that, I boot into stock recovery and sideload the OTA.zip, still fail
Thanks
JackVoo said:
Hi, the remount is at 15-May. Which I try to fix this issue.
I use fastboot to flash the system.img, but it still mentioned about "remount R/W".
After that, I boot into stock recovery and sideload the OTA.zip, still fail
Thanks
Click to expand...
Click to collapse
You probably forgot to flash something (or used incorrect image). Just download the latest fastboot image, switch to slot A and flash it all (except storage).
Try flashing with V11.0.1.0.QFQEUXM boot.img and system.img at slot A and B, still couldn't update.
Will try to flash all with the V11.0.2.0.QFQEUXM.
Update status:
I finally solve this issue.
I flash the new fastboot ROM into slot A, my current active is slot B.
Thanks for help.
help please
doing these steps will erase my data like factory reset?
if yes, then how can i install ota without losinig any data
_mysiak_ said:
As this questions pops up every single month, I'm putting this information into a separate topic. It is for everyone who followed the Magisk A/B OTA update guide and OTA update still fails to install. https://github.com/topjohnwu/Magisk/blob/master/docs/tutorials.md
The usual culprit is TWRP - if you booted into TWRP and allowed system modifications (even once), OTA update won't install. The second common suspect is one of apps with root access, which might have tampered the system partition (AdAway or some other old apps).
Use these commands as root from ADB shell or terminal emulator on the phone and look for mount count (has to be 0) and last mount time (must be n/a). Anything else means that system partition has been mounted as R/W and you MUST reflash stock system.img manually.
Code:
[I][B]tune2fs -l /dev/block/sda12
tune2fs -l /dev/block/sda13[/B][/I]
sda12 is system_a, sda13 is system_b
Example of untouched system:
Code:
Filesystem created: Wed Dec 31 17:00:00 2008
Last mount time: n/a
Last write time: Wed Dec 31 17:00:00 2008
Mount count: 0
Maximum mount count: -1
Last checked: Wed Dec 31 17:00:00 2008
How to fix - reflash system.img with the same version as currently running (or reflash everything with newer ROM):
Option #1
- download full OTA zip (not the incremental one, size must be above 1gb)
- and this Windows tool https://androidfilehost.com/?fid=818070582850510260
- extract both and put payload.bin into payload_input folder. Then run payload_dumper.exe. Once it completes the job, you'll find all images which can be flashed via fastboot.
- flash system.img to the active partition
- install OTA update
Option #2
- set A as active partition
- download, extract and run flash_all_except_data_storage.bat from stock Fastboot ROM
- root with Magisk patched boot.img and apply OTA with the usual Magisk A/B OTA procedure
Before flashing, backup your important data, one can be never sure enough.
Click to expand...
Click to collapse
Thanks for the post.
When i ran flash system.img is says partition unknown!
Hello, i want to give a try LineageOS on my Xiaomi Redmi 5A (Riva), i have unlock bootloader and flasing recovery img (twrp), and every file checksum is even. i tried to flash
lineage-17.1-20201020-UNOFFICIAL-riva.zip
Click to expand...
Click to collapse
on my device but i got an error log. sound like problem in selinux. can someone help me?
Code:
I:operation_start: 'Flashing'
Installing zip file '/sdcard1/lineage-17.1-20201020-UNOFFICIAL-riva.zip'
Checking for Digest file...
Unmounting System...
I:Update binary zip
Cannot verify treble package compatibility, must build TWRP in Oreo tree or higher.
I:Extracting updater binary 'META-INF/com/google/android/update-binary'
I:Zip does not contain SELinux file_contexts file in its root.
I:Legacy property environment not used in updater.
No path given to file labeling backend
selinux_android_file_context: Error getting file context handle (No such file or directory)
Warning: No file_contextsscript aborted: assert failed: riva.verify_trustzone("TZ.BF.4.0.5-157266")
assert failed: riva.verify_trustzone("TZ.BF.4.0.5-157266") == "1"error: 25
Updater process ended with ERROR: 7
I:Install took 0 second(s).
Error installing zip file '/sdcard1/lineage-17.1-20201020-UNOFFICIAL-riva.zip'
Cvar1984 said:
Hello, i want to give a try LineageOS on my Xiaomi Redmi 5A (Riva), i have unlock bootloader and flasing recovery img (twrp), and every file checksum is even. i tried to flash on my device but i got an error log. sound like problem in selinux. can someone help me?
Click to expand...
Click to collapse
Sounds like wrong twrp recovery
https://forum.xda-developers.com/xi...ent/rom-lineage-os-17-1-t4051339/post81771033