Magisk Module - Call Recording for EMUI 9 (PIE) - Huawei Mate 10 Themes, Apps, and Mods

This module will enable call recording on EMUI 9.
Install the module with Magisk Manager, reboot and enjoy!
On devices with Call+ option enabled, there will be no "Record" icon in the Dialer screen, so you will have to enable Automatic Recording from Dialer - Settings.
Download link - > https://mega.nz/#!1s9FTQLI!BkXmo2jl9YhVkXqe0j-XgoqGPQFdmpBvJFwRrFy1BmI
Version 9.1 - This version will also disable Call+ (RCS) feature, so you can manually start call registration from Dialer (Registration Icon)
Link - > https://mega.nz/#!xpcTUAxB!sxUuj1NBmwWHnWycQJ9tO3dU43VZuyXouAIav5WqAFE
Version 9.2 - OAT folder removed as it doesn't seems to be required
Link - > https://mega.nz/#!oplFmKrY!ObM6MH34L5pPutRbyVNWPCqULXVOj4yMiq3ZDfxEI9g

Mirror link: https://www.dropbox.com/s/f4vctbexarno8zu/EMUI9_Call_Recording.zip

Pretoriano80 said:
This module will enable call recording on EMUI 9.
Install the module with Magisk Manager, reboot and enjoy!
On devices with Call+ option enabled, there will be no "Record" icon in the Dialer screen, so you will have to enable Automatic Recording from Dialer - Settings.
Download link - > https://mega.nz/#!1s9FTQLI!BkXmo2jl9YhVkXqe0j-XgoqGPQFdmpBvJFwRrFy1BmI
Version 9.1 - This version will also disable Call+ (RCS) feature, so you can manually start call registration from Dialer (Registration Icon)
Link - > https://mega.nz/#!xpcTUAxB!sxUuj1NBmwWHnWycQJ9tO3dU43VZuyXouAIav5WqAFE
Version 9.2 - OAT folder removed as it doesn't seems to be required
Link - > https://mega.nz/#!oplFmKrY!ObM6MH34L5pPutRbyVNWPCqULXVOj4yMiq3ZDfxEI9g
Click to expand...
Click to collapse
I made a copy from cust/hwcall recorder to system/app/call recorder, and it works, but have noticed that the recordings can't be accessed from the dialer, as before. Is there a fix?

Hello, is it possible that calls can be recorded at will?.
I'm not interested in recording absolutely everything, besides, you can edit a list of numbers but what about the numbers you do not have between the contacts?
Thank you and greetings.
Enviado desde mi BLA-L29 mediante Tapatalk

rey_lagarto said:
Hello, is it possible that calls can be recorded at will?.
I'm not interested in recording absolutely everything, besides, you can edit a list of numbers but what about the numbers you do not have between the contacts?
Thank you and greetings.
Enviado desde mi BLA-L29 mediante Tapatalk
Click to expand...
Click to collapse
Just start the recording manually, from the dialer.

Need root
Or i can do it without root

The installation don't work (version 9.2, EMUI 9.0.1, STF-L09)
MAGISK LOG IS:
- Copying zip to temp directory
- Installing EMUI_Call_Recording_v9.2.zip
Archive: /data/user/0/com.topjohnwu.magisk/cache/install.zip
creating: common/
inflating: common/post-fs-data.sh
inflating: common/service.sh
inflating: common/system.prop
inflating: module.prop
inflating: config.sh
- Mounting /system, /vendor
/system/bin/mke2fs: invalid option -- t
*******************************
Call Recording For EMUI 9
*******************************
******************************
Powered by Magisk (@topjohnwu)
******************************
- Creating /data/adb/magisk_merge.img with size 64M
BusyBox v1.29.3-osm0sis (2018-11-17 02:42:59 AST) multi-call binary.
Usage: mke2fs [-Fn] [-b BLK_SIZE] [-i INODE_RATIO] [-I INODE_SIZE] [-m RESERVED_PERCENT] [-L LABEL] BLOCKDEV [KBYTES]
-b BLK_SIZE Block size, bytes
-F Force
-i RATIO Max number of files is filesystem_size / RATIO
-I BYTES Inode size (min 128)
-L LBL Volume label
-m PERCENT Percent of blocks to reserve for admin
-n Dry run
Create /data/adb/magisk_merge.img with size 64M
Cannot mount image!
! /data/adb/magisk_merge.img mount failed...
! Installation failed

gabryrizz02 said:
The installation don't work (version 9.2, EMUI 9.0.1, STF-L09)
MAGISK LOG IS:
- Copying zip to temp directory
- Installing EMUI_Call_Recording_v9.2.zip
Archive: /data/user/0/com.topjohnwu.magisk/cache/install.zip
creating: common/
inflating: common/post-fs-data.sh
inflating: common/service.sh
inflating: common/system.prop
inflating: module.prop
inflating: config.sh
- Mounting /system, /vendor
/system/bin/mke2fs: invalid option -- t
*******************************
Call Recording For EMUI 9
*******************************
******************************
Powered by Magisk (@topjohnwu)
******************************
- Creating /data/adb/magisk_merge.img with size 64M
BusyBox v1.29.3-osm0sis (2018-11-17 02:42:59 AST) multi-call binary.
Usage: mke2fs [-Fn] [-b BLK_SIZE] [-i INODE_RATIO] [-I INODE_SIZE] [-m RESERVED_PERCENT] [-L LABEL] BLOCKDEV [KBYTES]
-b BLK_SIZE Block size, bytes
-F Force
-i RATIO Max number of files is filesystem_size / RATIO
-I BYTES Inode size (min 128)
-L LBL Volume label
-m PERCENT Percent of blocks to reserve for admin
-n Dry run
Create /data/adb/magisk_merge.img with size 64M
Cannot mount image!
! /data/adb/magisk_merge.img mount failed...
! Installation failed
Click to expand...
Click to collapse
Dude, no need for magisk install. Just copy the file in the zip archive to /system/app and make proper permissions.

Can you tell how I have to do?

gabryrizz02 said:
Can you tell how I have to do?
Click to expand...
Click to collapse
First and obvious, you have to be rooted. Next:
- Go to cust/app and copy the folder HWCallRecorder
- Go to system/app and paste the folder
- Set permissions to the folder to 755 in total commander
- Set permissions to the file inside to 644 in total commander
- Reboot
- Enjoy

obviously I have the root, otherwise how did I use Magisk? However I extracted the folder from the zip of version 9.2 because in my version c432 there was not in the cust folder. I copied in system app I restarted and it's all fine.

gabryrizz02 said:
obviously I have the root, otherwise how did I use Magisk? However I extracted the folder from the zip of version 9.2 because in my version c432 there was not in the cust folder. I copied in system app I restarted and it's all fine.
Click to expand...
Click to collapse
Great to hear that it worked out.

does this work on other pie phones or only on hauwei?

xumixu said:
does this work on other pie phones or only on hauwei?
Click to expand...
Click to collapse
As far as I know, only Huawei. It's already implemented into the system, only needs a bit of a nudge.
As for other pie phones, word is that due to some privacy regulations, google is required to stop supporting call recording.

@Pretoriano80 Hi Mate
I'm on EMUI 9 with Mate 9 and I would like to know if your Magisk module is installable on Magisk v19 (Magisk often switch his template and/or configuration with .sh files)?
Thanks!

Tecalote said:
@Pretoriano80 Hi Mate
I'm on EMUI 9 with Mate 9 and I would like to know if your Magisk module is installable on Magisk v19 (Magisk often switch his template and/or configuration with .sh files)?
Thanks!
Click to expand...
Click to collapse
Hi! It's a simple module, nothing fancy, so it should install just fine with Magisk v19 too.

Pretoriano80 said:
Hi! It's a simple module, nothing fancy, so it should install just fine with Magisk v19 too.
Click to expand...
Click to collapse
You are right, thanks :good:
I made a version based on your idea and with credit for you in the readme.md file for Mate 9 /Emui 9.
https://www.androidfilehost.com/?fid=1395089523397943267
Only difference: I used the new Magisk Installer Template for Magisk v19 and additional I use the HwSoundRecorder (deodexed from Chinese Firmware) too in /system/app. Both is possible, manual recording from dialer and auto recording from dialer settings. (RCS I leave disabled)
Thanks Mate :highfive:
If you like you can try to add Soundrecorder to your module for Mate 10 Pro and test.

How to flash your file with fastboot adb command please?

cadkey said:
How to flash your file with fastboot adb command please?
Click to expand...
Click to collapse
Read the first page (OP) - it's a Magisk module and must be flashed directly from Magisk Manager (Modules section + Button)

https://www.xda-developers.com/huawei-honor-emui-9-call-recording/
Found this post by XDA and I'm so pleased that call recording works flawlessly without root.

Related

[CLOSED][OUTDATED][2017.2.7][GUIDES & DOCS] Magisk All-In-One Wiki

This thread is outdated and will never be updated
Please check the official Magisk documentation on Github!
Magisk All-In-One Wiki​
Table of Contents
Module Creation And Online Repos
Create your first Magisk Module; Submit to Magisk Module Repo
Notes Regarding Magisk Module Repos
Magisk Guides and Tricks
How Do Magic Mount Behave
Manipulate system props (build.prop)
Remove files / folders
Cache mounts
Magisk Details (DEV)
sepolicy-inject tool
Work flow
File structure
Boot stages
Module Creation And Online Repos
Create your first Magisk Module; Submit to Magisk Module Repo
Details are all listed in the module template on Github.​
Notes Regarding Magisk Module Repos
Magisk module can be different kinds, for example it can be used to debloat your system; it can be used to install your favorite application into system to give it the privilege of system apps.; it can be a full custom rom; it can also be cool mods like Xposed and root. However I view the "Magisk Module Repo" as a platform to share modules that can be used on lots of devices, preferably universal to all Android devices. Device specific modules are OK if stated clearly in the descriptions, and actually doing something that is non-trivial.
I will moderate the "Magisk Module Repo" in my personal preference and standard, here are some that will not be included:
Modules that are too large. A full custom rom, for example, is too large to be hosted on Github effectively. You can share them on XDA forums in your device specific forums
Modules that are too trivial. For example: mods that simply just add apps to system; debloating selective apps; doing things that can be done in simple boot scripts. I'll add more here if when I face requests that I consider "trivial"
Modules that contains copyright property (unless given permission)
Modules that violates XDA rules
This thread is outdated and will never be updated
Please check the official Magisk documentation on Github!
Magisk Guides and Tricks
How Do Magic Mount Behave
Magic Mount by default merges the files in $MODPATH/system into the real /system. You can think as it dirty flashes the contents into /system.
Existing files will be replaced; new files will be added; will not remove any files
Directories under $MODPATH/system that contains a file named ".replace" will NOT merge into the system. It will directly replace the correspond directory in /system.
In the module template, you can list them in "config.sh", the scripts will create the ".replace" file automatically for you.
You can think as it wipes the existing folder, and then adds contents to that folder in /system.
The directory that contains ".replace" will replace the one in /system, all contents originally in the folder will be discarded
Adding items to system is relatively expensive, Magisk would need to do many under-the-hood tasks to achieve it (thus, called "Magic Mount")
Furthermore, the higher level the file is added, the more it effects the overall system
Only add new items if necessary! Think twice before adding items to /system root!
Replacing a whole folder is recommended if viable, it reduces the complicated process and speed up the booting time
Manipulate system props (build.prop)
Since the early days of XDA, people love "build.prop" mods. It can bring cool effects to our devices.
build.prop files are loaded early in the boot process, and once read-in, the values cannot be modified... in theory.
Magisk included a tool called "resetprop", it can modify any system props you want easily.
In the module template, you can set PROPFILE=true, then add your props into the file common/system.prop
Magisk by default reads the system.prop of each module and set the props.
Further resetprop options:
Code:
usage: /data/magisk/resetprop [-v] [-n] [--file propfile] [--delete name] [ name value ]
-v :
verbose output (Default: Disabled)
-n :
no event triggers when changing props (Default: Will trigger events)
--file propfile :
Read props from prop files (e.g. build.prop)
--delete name :
Remove a prop entry
Remove files / folders
It is complicated to actually remove a file (possible, not worth the effort). Replacing it with a dummy file should be good enough
Add an empty file with the same name and path into your module (easy way), or add this code to the updater-script to create it at flash time
Code:
# Example: you want to remove /system/media/audio/alarms/Argon.ogg
# Note: mktouch is a function defined in my updater-script, it is not a standard command!
mktouch $MODDIR/system/media/audio/alarms/Argon.ogg
It is complicated to actually remove a folder (possible, not worth the effort). Replacing it with an empty folder should be good enough
Add the folder to the replace list in "config.sh" in the module template, it will replace the folder with an empty one
Cache mounts
Some files requires to be mounted much earlier in the boot process, currently known are bootanimation, and some libs (most users won't change them).
You can place your files into the corresponding location under /cache/magisk_mount, Magisk will automagiskally manage selinux contexts, permissions and the mounting for you. For example, you want to replace /system/media/bootanimation.zip, copy your new boot animation zip to /cache/magisk_mount/system/media/bootanimation.zip, Magisk will mount your files in the next reboot​
More to come ...
This thread is outdated and will never be updated
Please check the official Magisk documentation on Github!
Magisk Details (DEV)
sepolicy-inject
Before starting, check the complete document from Chainfire
SELinux Policy Section in How-To SU
The included sepolicy manipulation tool is called "sepolicy-inject", it supports live patching, and also supports policy statements following the same syntax as supolicy:
Code:
sepolicy-inject [--live] [--minimal] [--load <infile>] [--save <outfile>] [policystatement...]
--live: directly load patched policy to device
--minimal: minimal patches for boot image to let Magisk live patch on boot
Supported policy statements:
"allow #source-class #target-class permission-class #permission"
"deny #source-class #target-class permission-class #permission"
"auditallow #source-class #target-class permission-class #permission"
"auditdeny #source-class #target-class permission-class #permission"
"create #class"
"permissive #class"
"enforcing #class"
"attradd #class #attribute"
"typetrans source-class target-class permission-class default-class (optional: object-name)"
source-class and target-class can be attributes (patches the whole group)
All sections (except typetrans) can be replaced with '*' to patch every possible matches
Sections marked with '#' can be replaced with collections in curly brackets
e.g: allow { source1 source2 } { target1 target2 } permission-class { permission1 permission2 }
Will be expanded to:
allow source1 target1 permission-class permission1
allow source1 target1 permission-class permission2
allow source1 target2 permission-class permission1
allow source1 target2 permission-class permission2
allow source2 target1 permission-class permission1
allow source2 target1 permission-class permission2
allow source2 target2 permission-class permission1
allow source2 target2 permission-class permission2
Work flow
Code:
--------post-fs---------
(Device Boots) -> Mount Magisk cache files -> (build.prop and persist prop loads) ->
-----------------------------post-fs-data---------------------------------
-> Live patch sepolicy -> mount magisk.img -> Preparation -> 5 stage of tasks ->
--------------late_start--------------
-> (System Start Up) -> run all service.sh -> Start Magisk Hide
-> (Parallel with other processes....)
(Preparation) Magisk will travel through all enabled module directories to collect info
(1st stage) Mount system (vendor) mirrors. This is used to revert dummy files
(2nd stage) Clone the system structure, and mount the dummy directories to provide a dummy skeleton
(3rd stage) Mount module items into the system (and dummy skeletons)
(4th stage) Execute scripts
(5th stage) Mount the mirror items back to the remaining dummy files
File Structures
A "Magisk Module" is a subfolder under magisk root directory
The structure of a Magisk Module do not have a strict restriction. However, here are some key files / folders:
Code:
/magisk
|
|-.core <--- Magisk auto-generated files. Do not mess with them :)
| |
| |
| |-hosts <--- This file will be mounted to /system/etc/hosts to enable
| | systemless support for AdBlocker apps.
| |-magiskhide <--- This folder holds the hide list and add/rm/list/enable/disable scripts
| | | Include the magiskhide binary
| | |-magiskhide
| | |-hidelist
| | |-add
| | |-rm
| | |-list
| | |-enable
| | |-disable
| |
| |-su <--- This folder holds the MagiskSU binaries and scripts
| | | Include the magiskhide binary
| | |-su
| | |-magisksu.sh
| | |-sbin_bind <--- This folder will bind mount to /sbin
| | |-.....
| |
| |-post-fs-data.d <--- Place scripts that should be executed at post-fs-data here
| | |-.....
| |
| |-service.d <--- Place scripts that should be executed at late_start service here
| |-.....
|
|
|-other_module
| |-.....
|
|-your_module
| |
| |-auto_mount <--- If this file exists, auto mount is enabled
| |
| |-disable <--- If this file exists, the module is disabled
| |
| |-remove <--- If this file exists, the whole module folder
| | will be removed in the next reboot
| |-module.prop <--- This files stores the info of your module
| |
| |-system.prop <--- This file will be read by resetprop
| |
| |-post-fs-data.sh <--- This script will be executed in post-fs-data
| |
| |-service.sh <--- This script will be executed in late_start service
| |
| |-system <--- If auto mount is enabled, Magisk will "Magic Mount" this folder
| | |-....
| | |-....
| | |-....
| | |-....
| |
| |-vendor <--- Auto generated. A symlink to $MODID/system/vendor
| | Dealing with separate vendor partitions
| |-..... <--- Any other files/folders are allowed
|
|-another_module
| |-.....
|-...
Other important folders (under /dev), these will be created every boot
Code:
/dev/busybox <--- Busybox applet symlinks will be created here
|-.... Will be bind mounted to /system/xbin if enable busybox in Magisk Manager
|-....
|-....
/dev/magisk
|
|-dummy <--- Lies all cloned dummy structures
| | Folders in here will be mounted to /system
| |-.....
|
|-mirror <--- Lies all mirrors
| |
| |-system
| | |-....
| |
| |-vendor <--- Could be a symlink to /dev/mirror/system/vendor
| |-....
|
|-mnt <--- Lies all mounting info
|
|-dummy <--- Lists all dummy mounts
| |-....
|
|-mirror <--- Lists all mirror mounts
| |-....
|
|-system <--- Lists all /system mounts
| |-....
|
|-vendor <--- Lists all /vendor mounts
|-....
Boot Stages
If you are working on complicated projects, you shall need more control to the whole process.
Magisk can run scripts in different boot stages, you can fine tune exactly what you want to do.
post-fs mode:
This stage is BLOCKING. Boot process will NOT continue until everything is done, or 20 seconds has passed
Happens after most partitions are mounted, except /data
Magisk will bind mount items in: /cache/magisk_mount/system (*1)
post-fs-data mode:
This stage is BLOCKING. Boot process will NOT continue until everything is done, or 60 seconds has passed
Happens after /data is ready (including encrypted data)
Happens before Zygote is started (which means pretty much everything)
/data/magisk.img will be mounted to /magisk
Magisk will bind mount items in: /magisk/$MODID/system (*2)
Magisk will run script: /magisk/$MODID/post-fs-data.sh
Magisk will run scripts in: /magisk/.core/post-fs-data.d
late_start service mode:
This stage is NON-BLOCKING, it will run parallel with other processes
Put time consuming but non time critical tasks here. In other modes, the boot process will be stuck if it took too long to finish your tasks.
Happens when class late_start is started . Most things are are loaded/loading in this case.
Magisk will run script: /magisk/$MODID/service.sh
Magisk will run scripts in: /magisk/.core/service.d
(*1) Bind mounting in post-fs only support simple bind mounts, which mean you cannot add files or replace directories.
It will only mount files that exist in the current system.
(*2) Bind mounting in post-fs-data support complex bind mounts. Please refer to the "Magic Mount" section
Thanks for this @topjohnwu.
If github is the where all modules need to be hosted, how do we plan on supporting closed source modules?
Or is closed source modules not supported?
@topjohnwu is there any thought about aroma installers being supported? is this already possible? or are you planning to add something similar?
I've tried to build a v7-compatible zip file for an app and Magisk Manager kept crashing with the following in its module.prop:
Code:
versionCode=7.1.3231428
Is it supposed to be a single round number (like a versionCode for Android apps)?
anantharam said:
Thanks for this @topjohnwu.
If github is the where all modules need to be hosted, how do we plan on supporting closed source modules?
Or is closed source modules not supported?
Click to expand...
Click to collapse
You can host closed source binary on Github.
ibrokemypie said:
@topjohnwu is there any thought about aroma installers being supported? is this already possible? or are you planning to add something similar?
Click to expand...
Click to collapse
You can flash the Magisk Module template in aroma with the same method to flash SuperSU. However if the module itself is made with aroma, it will not be able to flash in Magisk Manager
stangri said:
I've tried to build a v7-compatible zip file for an app and Magisk Manager kept crashing with the following in its module.prop:
Is it supposed to be a single round number (like a versionCode for Android apps)?
Click to expand...
Click to collapse
Yes, the versionCode is the similar concept of Android application's version code. It has to be a single number. You can place your long version number into version, which supports any string.
i have a problem with MagiskManager 2.0 launch.... app stopped after open it.
Zenfone ZE520KL...
Also, plz help - where can i found new supersu 2.78 for magisk?
topjohnwu said:
Yes, the versionCode is the similar concept of Android application's version code. It has to be a single number. You can place your long version number into version, which supports any string.
Click to expand...
Click to collapse
Still, the magisk manager shouldn't crash on invalid versionCode.
I need to patch in lines to audio_effects.conf rather than replace the file. Is there any way to do a systemless merge of lines within a conf with Magisk?
Hello, I'm trying to bring the OnePlus Camera to Magisk, and I'm having issues. I feel that I understand how to create a Magisk module from following your tutorial on Github, but apparently I don't. I just spent about 25 minutes trying to figure this out on my own, and couldn't.
When I flash my zip, I get error 255 in TWRP. It claims "/tmp/updater" doesn't exist. Magisk Manager also claims it's not a Magisk module when trying to manually add it in the app.
Below is the recovery.log, and link to the Github repo for what I'm working on. Any help is appreciated!
Source: https://github.com/ryanguy426/OnePlus-Camera-Magisk
recovery.log (PasteBin): http://pastebin.com/z0B9jaSM
ryanguy426 said:
When I flash my zip, I get error 255 in TWRP. It claims "/tmp/updater" doesn't exist. Magisk Manager also claims it's not a Magisk module when trying to manually add it in the app.
Source: https://github.com/ryanguy426/OnePlus-Camera-Magisk
recovery.log (PasteBin): http://pastebin.com/z0B9jaSM
Click to expand...
Click to collapse
AFAIK If you use the Magisk v7 template (from github), you do not flash resulting ZIP in recovery. Also, I'm not sure if just downloading the ZIP file from github will do, AFAIK doing that creates a nesting folder which is probably why Magisk refuses to add the module.
I can create the correct ZIP and I would have tried it on my phone, but I followed your support link and it leads to the generic Magisk thread and doesn't list specific models it's compatible with, so I refrained.
PS. Fix REPLACE in your config.sh
stangri said:
AFAIK If you use the Magisk v7 template (from github), you do not flash resulting ZIP in recovery. Also, I'm not sure if just downloading the ZIP file from github will do, AFAIK doing that creates a nesting folder which is probably why Magisk refuses to add the module.
I can create the correct ZIP and I would have tried it on my phone, but I followed your support link and it leads to the generic Magisk thread and doesn't list specific models it's compatible with, so I refrained.
PS. Fix REPLACE in your config.sh
Click to expand...
Click to collapse
I haven't created a support thread yet, as XDA doesn't allow placeholder threads. I'll create the thread when the module works.
I'll start over with it, and see if I can get it working. They're for the tips!
I have created a module that will enable miracast by adding a line to the build.prop. When I try to manually add the module to magisk I get an error saying "This zip is not a magisk module!!" Can someone please tell me what I'm doing wrong.
Here is the module : github.com/blake1029384756/EnableMiracast
Blake1029384756 said:
I have created a module that will enable miracast by adding a line to the build.prop. When I try to manually add the module to magisk I get an error saying "This zip is not a magisk module!!" Can someone please tell me what I'm doing wrong.
Here is the module : github.com/blake1029384756/EnableMiracast
Click to expand...
Click to collapse
If you are downloading the zip from github it nests a folder within it which magisk doesnt like, you need to zip up the files in the root of the zip.
ibrokemypie said:
If you are downloading the zip from github it nests a folder within it which magisk doesnt like, you need to zip up the files in the root of the zip.
Click to expand...
Click to collapse
I am aware that it does that and have made sure all files are in the root of the zip. Idk why it doesnt add to magisk manager
ahrion said:
I need to patch in lines to audio_effects.conf rather than replace the file. Is there any way to do a systemless merge of lines within a conf with Magisk?
Click to expand...
Click to collapse
Just make a copy of the file as /magisk/your_mldule/system/etc/audio_effects.conf, and modify the fake aidio_effects.conf which will be mounted during boot.
But the weird thing is that some setprop commands don't work when it is written in post-fs-data or post-fs, at least under Magisk v6 OnePlus 3 Oxygen OS. I have to write the setprop modifications in a fake build.prop instead.
Here is the module that I transplant from guitardedhero's ViPER4Audio_5.4_Stock.zip. Maybe it would help.
BTW: The attachment doesn't work well on v7, it stuck at boot animation. While it works well on v6.
Iceyogurt said:
Just make a copy of the file as /magisk/your_mldule/system/etc/audio_effects.conf, and modify the fake aidio_effects.conf which will be mounted during boot.
But the weird thing is that some setprop commands don't work when it is written in post-fs-data or post-fs, at least under Magisk v6 OnePlus 3 Oxygen OS. I have to write the setprop modifications in a fake build.prop instead.
Here is the module that I transplant from guitardedhero's ViPER4Audio_5.4_Stock.zip. Maybe it would help.
BTW: The attachment doesn't work well on v7, it stuck at boot animation. While it works well on v6.
Click to expand...
Click to collapse
Perhaps you might be able to tell me why Magisk Manager isn't recognizing my zip as a Magisk module...https://github.com/therealahrion/Audio-Modification-Framework
ahrion said:
Perhaps you might be able to tell me why Magisk Manager isn't recognizing my zip as a Magisk module...https://github.com/therealahrion/Audio-Modification-Framework
Click to expand...
Click to collapse
It is not easy to find a bug in my mobile browser. I'll try to look through your script more carefully when I get a PC. Now there is a mistake in the config.sh.
Code:
# This is an example
REPLACE="
/system/app/Youtube
/system/priv-app/SystemUI
/system/priv-app/Settings
/system/framework
"
# Construct your own list
REPLACE="
/system/etc
/system/vendor/etc
"
The first variable REPLACE is an example, so just delete it.(oh sorry, I forget it will be revalued because of the second one) And leave the second REPLACE void.
Code:
# Construct your own list
REPLACE=""
Since the value of REPLACE are folders, it mean replace an existing folder with a same-name-folder. The modified fake audio_effects.conf file will be mounted to replace the existing file automatically. No need to replace a whole folder.
ahrion said:
Perhaps you might be able to tell me why Magisk Manager isn't recognizing my zip as a Magisk module...https://github.com/therealahrion/Audio-Modification-Framework
Click to expand...
Click to collapse
Sorry about it, i can't figure out the reason either. I don't recommend you do the modification of the audio config files in post-fs-data.sh, which will be executed during every boot. I love your dax, wish it be a magisk module soon.

Question : "magisk hide unable to watch hidelist" any way to fix?

i use oneplus 3 with OxygenOs 3.5.5 when i use the rom (stock) and install magisk and enable magisk hide it hides root and safetynet succeed and it unmounts
But when i start from the beginning on the stock rom and install RR on the rom (customrom) and full unroot and reinstall magisk and enable magisk hide and reboot i get this in the log and it doesn't unmount :
HTML:
MagiskHide: starting MagiskHide Daemon
MagiskHide: Unable to watch /magisk/.core/magiskhide/hidelist
any help please to get it to unmount and hide root ?
to know after i installed RR and full unrooted safetynet passed
ahmedsasker said:
i use oneplus 3 with OxygenOs 3.5.5 when i use the rom (stock) and install magisk and enable magisk hide it hides root and safetynet succeed and it unmounts
But when i start from the beginning on the stock rom and install RR on the rom (customrom) and full unroot and reinstall magisk and enable magisk hide and reboot i get this in the log and it doesn't unmount :
HTML:
MagiskHide: starting MagiskHide Daemon
MagiskHide: Unable to watch /magisk/.core/magiskhide/hidelist
any help please to get it to unmount and hide root ?
to know after i installed RR and full unrooted safetynet passed
Click to expand...
Click to collapse
Run the following commands in a terminal emulator:
Code:
su
cd /magisk/.core/magiskhide
sh disable
sh enable
You're probably gonna get an output that the hidelist can't be created because of a permissions issue. That probably means the Magisk image doesn't get mounted properly at boot.
Another user (@gunner007dc) that had this issue fixed it by using a different kernel.
Didgeridoohan said:
Run the following commands in a terminal emulator:
Code:
su
cd /magisk/.core/magiskhide
sh disable
sh enable
You're probably gonna get an output that the hidelist can't be created because of a permissions issue. That probably means the Magisk image doesn't get mounted properly at boot.
Another user (@gunner007dc) that had this issue fixed it by using a different kernel.
Click to expand...
Click to collapse
that is what i get and safetynet doesn't pass still ..
Code:
[email protected]:/magisk/.core/magiskhide # sh disable
MagiskHide: Stopping MagiskHide daemon
disable[27]: can't open /magisk/.core/magiskhide/hidelist: No such file or directory
1|[email protected]:/magisk/.core/magiskhide # sh enable
MagiskHide: Removing dangerous read-only system props
touch: '/magisk/.core/magiskhide/hidelist': Read-only file system
chmod: chmod '/magisk/.core/magiskhide' to 40755: Read-only file system
chmod: chmod 'rm' to 100755: Read-only file system
chmod: chmod 'list' to 100755: Read-only file system
chmod: chmod 'enable' to 100755: Read-only file system
chmod: chmod 'disable' to 100755: Read-only file system
chmod: chmod 'add' to 100755: Read-only file system
grep: /magisk/.core/magiskhide/hidelist: Bad file descriptor/magisk/.core/magiskhide/add[14]: [: 0: unexpected operator/operand
enable[65]: can't open /magisk/.core/magiskhide/hidelist: No such file or directory
MagiskHide: Starting MagiskHide daemon
to know without the magisk and have root removed with the custom rom the safetynet passes so what is wrong ?
if magisk doesn't get mounted properly how could i fix that ?
i tried to install another karnel whick support systemless root and i got bootloop maybe cuz of the custom rom RR so i can't install another karnel while the one i tried the only one i saw that support systemless root
please anyway to make magisk work ? (i tried the two versions under 12.0 too)
ahmedsasker said:
that is what i get and safetynet doesn't pass still ..
Code:
[email protected]:/magisk/.core/magiskhide # sh disable
MagiskHide: Stopping MagiskHide daemon
disable[27]: can't open /magisk/.core/magiskhide/hidelist: No such file or directory
1|[email protected]:/magisk/.core/magiskhide # sh enable
MagiskHide: Removing dangerous read-only system props
touch: '/magisk/.core/magiskhide/hidelist': Read-only file system
chmod: chmod '/magisk/.core/magiskhide' to 40755: Read-only file system
chmod: chmod 'rm' to 100755: Read-only file system
chmod: chmod 'list' to 100755: Read-only file system
chmod: chmod 'enable' to 100755: Read-only file system
chmod: chmod 'disable' to 100755: Read-only file system
chmod: chmod 'add' to 100755: Read-only file system
grep: /magisk/.core/magiskhide/hidelist: Bad file descriptor/magisk/.core/magiskhide/add[14]: [: 0: unexpected operator/operand
enable[65]: can't open /magisk/.core/magiskhide/hidelist: No such file or directory
MagiskHide: Starting MagiskHide daemon
to know without the magisk and have root removed with the custom rom the safetynet passes so what is wrong ?
if magisk doesn't get mounted properly how could i fix that ?
i tried to install another karnel whick support systemless root and i got bootloop maybe cuz of the custom rom RR so i can't install another karnel while the one i tried the only one i saw that support systemless root
please anyway to make magisk work ? (i tried the two versions under 12.0 too)
Click to expand...
Click to collapse
Looks like what for a strange reason /magisk is mounted as read-only. Try mount as rw:
Code:
mount -w -o remount /magisk
Deic said:
Looks like what for a strange reason /magisk is mounted as read-only. Try mount as rw:
Code:
mount -w -o remount /magisk
Click to expand...
Click to collapse
Code:
[email protected]:/ $ su
[email protected]:/ # mount -w -o remount /magisk
[email protected]:/ # cd /magisk/.core/magiskhide
[email protected]:/magisk/.core/magiskhide # she disable
sh: she: not found
127|[email protected]:/magisk/.core/magiskhide # sh disable
MagiskHide: Stopping MagiskHide daemon
disable[27]: can't open /magisk/.core/magiskhide/hidelist: No such file or directory
1|[email protected]:/magisk/.core/magiskhide # sh enable
MagiskHide: Removing dangerous read-only system props
touch: '/magisk/.core/magiskhide/hidelist': Read-only file system
chmod: chmod '/magisk/.core/magiskhide' to 40755: Read-only file system
chmod: chmod 'rm' to 100755: Read-only file system
chmod: chmod 'list' to 100755: Read-only file system
chmod: chmod 'enable' to 100755: Read-only file system
chmod: chmod 'disable' to 100755: Read-only file system
chmod: chmod 'add' to 100755: Read-only file system
grep: /magisk/.core/magiskhide/hidelist: Bad file descriptor/magisk/.core/magiskhide/add[14]: [: 0: unexpected operator/operand
enable[65]: can't open /magisk/.core/magiskhide/hidelist: No such file or directory
MagiskHide: Starting MagiskHide daemon
[email protected]:/magisk/.core/magiskhide #
I still get the same result ...
ahmedsasker said:
I still get the same result ...
Click to expand...
Click to collapse
If you type just:
Code:
su
mount
and look for a line that starts something like:
Code:
/dev/block/loop0 on /magisk
In the parenthesis at the end of the line, the text should start with "rw". Does it?
Didgeridoohan said:
If you type just:
Code:
su
mount
and look for a line that starts something like:
Code:
/dev/block/loop0 on /magisk
In the parenthesis at the end of the line, the text should start with "rw". Does it?
Click to expand...
Click to collapse
No it it does start with ro
Code:
/dev/block/loop0 on /magisk type ext4 (ro,seclabel,noatime,data=ordered)
ahmedsasker said:
No it it does start with ro
Code:
/dev/block/loop0 on /magisk type ext4 (ro,seclabel,noatime,data=ordered)
Click to expand...
Click to collapse
Ok. Next, try:
Code:
mount -o remount,rw /magisk
If that doesn't work, try:
Code:
mount -o remount,rw -t ext4 /dev/block/loop0 /magisk
Didgeridoohan said:
Ok. Next, try:
Code:
mount -o remount,rw /magisk
If that doesn't work, try:
Code:
mount -o remount,rw -t ext4 /dev/block/loop0 /magisk
Click to expand...
Click to collapse
I tried both and it keeps telling me that it is read-only
Code:
[email protected]:/ $ su
[email protected]:/ # mount -o remount,rw /magisk
'/dev/block/loop0' is read-only
ount -o remount,rw -t ext4 /dev/block/loop0 /magisk <
'/dev/block/loop0' is read-only
ahmedsasker said:
I tried both and it keeps telling me that it is read-only
Code:
[email protected]:/ $ su
[email protected]:/ # mount -o remount,rw /magisk
'/dev/block/loop0' is read-only
ount -o remount,rw -t ext4 /dev/block/loop0 /magisk <
'/dev/block/loop0' is read-only
Click to expand...
Click to collapse
Hm... I have no idea...
From your earlier posts I assume you've already uninstalled and reinstalled Magisk a few times, right? Have you tried an unofficial beta snapshot (both Magisk and the Manager)?
I still say you should try a different kernel. I don't know what you mean with "supports systemless root", but I'd try flashing a kernel like Elemental over the one that comes with RR and then install Magisk. Maybe even try installing and running Kernel Auditor, like it says in the link I posted earlier.
Didgeridoohan said:
Hm... I have no idea...
From your earlier posts I assume you've already uninstalled and reinstalled Magisk a few times, right? Have you tried an unofficial beta snapshot (both Magisk and the Manager)?
I still say you should try a different kernel. I don't know what you mean with "supports systemless root", but I'd try flashing a kernel like Elemental over the one that comes with RR and then install Magisk. Maybe even try installing and running Kernel Auditor, like it says in the link I posted earlier.
Click to expand...
Click to collapse
I meant that it was written that it supports systemless root in the XDA forums plus I tried to flash elementalx karnel and went into boot loop ...
I'll try the snapshot one now and thanks alot <3
ahmedsasker said:
I meant that it was written that it supports systemless root in the XDA forums plus I tried to flash elementalx karnel and went into boot loop ... How can I uninstall the elementalx karnel to try another one without reflashing the whole rom ?
I'll try the snapshot one now and thanks alot <3
Click to expand...
Click to collapse
Dirty flash the ROM or open up the ROM zip, extract the boot.img and flash that in TWRP.
Didgeridoohan said:
Dirty flash the ROM or open up the ROM zip, extract the boot.img and flash that in TWRP.
Click to expand...
Click to collapse
OMG thanks alot it works well now and passes with the snapshot version <3
thanks again x3
Didgeridoohan said:
Dirty flash the ROM or open up the ROM zip, extract the boot.img and flash that in TWRP.
Click to expand...
Click to collapse
please do you know compatible version of systemless xposed with snapshot magisk ! cuz latest v87 after I flash it, closed installer says that there's not framework installed but normal official one works
systemless xposed v87 was working fine on magisk v12
i installed the official one now and it is working very well
what is the difference between systemless xposed and the normal one ? (cuz both got caught by safety net)
ahmedsasker said:
please do you know compatible version of systemless xposed with snapshot magisk ! cuz latest v87 after I flash it, closed installer says that there's not framework installed but normal official one works
systemless xposed v87 was working fine on magisk v12
i installed the official one now and it is working very well
what is the difference between systemless xposed and the normal one ? (cuz both got caught by safety net)
Click to expand...
Click to collapse
It's very likely the Xposed Magisk module needs to be updated to work with v13... I don't use Xposed though, so I wouldn't know.
The difference between system and systemless xposed is that one is installed into system and the other one is systemless. :laugh: Seriously... That's the difference. They'll both trigger SafetyNet. Systemlessness is not about passing SafetyNet.
Didgeridoohan said:
Run the following commands in a terminal emulator:
Code:
su
cd /magisk/.core/magiskhide
sh disable
sh enable
You're probably gonna get an output that the hidelist can't be created because of a permissions issue. That probably means the Magisk image doesn't get mounted properly at boot.
Another user (@gunner007dc) that had this issue fixed it by using a different kernel.
Click to expand...
Click to collapse
In my device, no file in /magisk/...why?:crying::crying:
Hooxp17 said:
In my device, no file in /magisk/...why?:crying::crying:
Click to expand...
Click to collapse
No idea. I can't see your device and I can't read your mind... Meaning: you've given very few details.
I'm gonna make a guess though: are you taking about the ".core" folder? It's a hidden folder, so if your file explorer isn't set to see hidden files and folders you won't see it.
If this is not your issue, give more details.
Didgeridoohan said:
Dirty flash the ROM or open up the ROM zip, extract the boot.img and flash that in TWRP.
Click to expand...
Click to collapse
Which ROM? How to Dirty Flash? I have G5 Plus
brandonsisco said:
Which ROM? How to Dirty Flash? I have G5 Plus
Click to expand...
Click to collapse
Uhm... That was a specific advice for a specific issue...
What's your issue?
Didgeridoohan said:
Run the following commands in a terminal emulator:
Code:
su
cd /magisk/.core/magiskhide
sh disable
sh enable
You're probably gonna get an output that the hidelist can't be created because of a permissions issue. That probably means the Magisk image doesn't get mounted properly at boot.
Another user (@gunner007dc) that had this issue fixed it by using a different kernel.
Click to expand...
Click to collapse
hello, i have a problem with magisk, so i found your post. but in the terminal emulator can't see this file.. can you help me?

Unable to extract zip file

I've got a freshly installed Magisk v14, with manager 5.6.0, running on an Oukitel K10 with Android 7.1.1.
Version 15+ of Magisk causes a boot loop on this device, so I'm stuck on 14.
Anyway, installing downloaded Magisk modules from the zip file, or from the Downloads section in the manager, I get logs like:
Code:
- Copying zip to temp directory
- Installing Emoji_one-v1.311.zip
- Mounting /system, /vendor, /data, /cache
! Unable to extract zip file!
Failed!
! Installation failed
The MagiskManager directory does exist. I also deleted it and let the manager recreate it by downloading the magisk zip again. No change.
What can I do?
Might be an issue with unzip. Try if installing the Busybox module from the Downloads section works, and if it does, try installing modules again (after rebooting).
Installing BusyBox worked, but even after a reboot I get the same result when attempting to install other stuff. Also, BusyBox is listed under "Update Available" in the downloads section even though I already installed 1.27.2, twice.
norbolt said:
Installing BusyBox worked, but even after a reboot I get the same result when attempting to install other stuff. Also, BusyBox is listed under "Update Available" in the downloads section even though I already installed 1.27.2, twice.
Click to expand...
Click to collapse
That most likely means it did not work. Post the install log from installing the Busybox module.
Hm. Yes, the log doesn't seem as fine.
Code:
- Copying zip to temp directory
- Installing Busybox_for_Android_NDK-1.27.2.zip
Busybox Installer Script
by osm0sis @ xda-developers
Mounting...
mount: bad /etc/fstab: No such file or directory
mount: bad /etc/fstab: No such file or directory
mount: bad /etc/fstab: No such file or directory
Extracting files...
update-binary[110]: unzip: not found
Installing...
Using architecture: arm64
Creating filesystem with parameters:
Size: 67108864
Block size: 4096
Blocks per group: 32768
Inodes per group: 4096
Inode size: 256
Journal blocks: 1024
Label:
Blocks: 16384
Block groups: 1
Reserved block group size: 7
Created filesystem with 11/4096 inodes and 1294/16384 blocks
umount: /dev/magisk_merge: No such file or directory
mount: losetup failed 1
mknod: /dev/block/loop0: File exists
losetup: /dev/block/loop0=/data//magisk_merge.img: Device or resource busy
mknod: /dev/block/loop1: File exists
Using path: /dev/magisk_merge/busybox-ndk/system/xbin
cp: busybox-arm64: No such file or directory
cp: bad 'busybox-arm64': No such file or directory
chown: /dev/magisk_merge/busybox-ndk/system/xbin/busybox: No such file or directory
chmod: /dev/magisk_merge/busybox-ndk/system/xbin/busybox: No such file or directory
cp: module.prop: No such file or directory
cp: bad 'module.prop': No such file or directory
cp: module.prop: No such file or directory
cp: bad 'module.prop': No such file or directory
Cleaning...
update-binary[189]: /dev/magisk_merge/busybox-ndk/system/xbin/busybox: not found
update-binary[191]: /dev/magisk_merge/busybox-ndk/system/xbin/busybox: not found
update-binary[210]: /dev/magisk_merge/busybox-ndk/system/xbin/busybox: not found
Creating symlinks...
Unmounting...
umount: /system: Device or resource busy
umount: /data: Device or resource busy
umount: /cache: Device or resource busy
Done!
- All done!
Yeah, there's an issue with unzip:
Code:
update-binary[110]: unzip: not found
Might be an issue with your Magisk installation or a device thing, hard to say....
Have you tried installing a zip through recovery? If you can install the Busybox module in recovery it might fix things.
Didgeridoohan said:
Have you tried installing a zip through recovery? If you can install the Busybox module in recovery it might fix things.
Click to expand...
Click to collapse
I have not tried that. I currently have the stock recovery flashed. So I guess this means flashing TWRP, then flashing Busybox, and perhaps also attempting to flash Magisk itself through the recovery?
Hopefully I got that right. I'm a bit new to this.
norbolt said:
I have not tried that. I currently have the stock recovery flashed. So I guess this means flashing TWRP, then flashing Busybox, and perhaps also attempting to flash Magisk itself through the recovery?
Hopefully I got that right. I'm a bit new to this.
Click to expand...
Click to collapse
You don't have to install TWRP, you can just boot it:
Code:
fastboot boot recovery twrp.img
I attempted to install both Magisk and Busybox from TWRP, and while the Magisk installer seems to run fine, I get to allow root access to stuff in Android afterwards and I get the Magisk Manager and such, I still can't install Busybox. Also, it seems from the log that Magisk itself is also having some issues the UI isn't telling me about.
The main issue seems to be the following error:
Code:
I:[MTP] MtpServer::run fd: 26
E:[MTP] got unsupported command UNKNOWNE:[MTP] response write returned -1, errno: 19, exiting MtpServer::run loop
Searching Google for the above error returns very little help.
I pasted the entire log here, from me booting TWRP and attempting to install Magisk and Busybox a few times. The Busybox installer claims Magisk isn't installed.
I can't post links yet, so this is code:
Code:
http://paste.debian.net/1010746/
norbolt said:
I've got a freshly installed Magisk v14, with manager 5.6.0, running on an Oukitel K10 with Android 7.1.1.
Version 15+ of Magisk causes a boot loop on this device, so I'm stuck on 14.
Anyway, installing downloaded Magisk modules from the zip file, or from the Downloads section in the manager, I get logs like:
Code:
- Copying zip to temp directory
- Installing Emoji_one-v1.311.zip
- Mounting /system, /vendor, /data, /cache
! Unable to extract zip file!
Failed!
! Installation failed
The MagiskManager directory does exist. I also deleted it and let the manager recreate it by downloading the magisk zip again. No change.
What can I do?
Click to expand...
Click to collapse
hello,
Very simple solution for me at least.
i found this thread because the same thing just happened to me on g900t s5 running lineageOS. Magisk said couldnt extract Zip everytime.
My problem i believe was that i installed busybox from Apkpure and not playstore
Because when i uninstalled Busybox from apkpure then installed busybox from playtore the unzip errors are gone!
Maybe its because i has a bad copy of busybox?
Idk but that was the solution for me!
Hope this helps someone
Me helps install again magisk by twrp.
Install the es file explorer once and extract the zip at least once, It will show a list of programs by which to extract, select es file extractor and check the always button now go back to the magisk manager and try again you should be good to go.
magisk zip
My problem solved by typing real path.
I was use command to install a module using this code
Code:
twrp install sdcard/module.zip
Give an error, so i change to
Code:
twrp install /sdcard/module.zip
Everything ok.
alfanveykov said:
My problem solved by typing real path.
I was use command to install a module using this code
Code:
twrp install sdcard/module.zip
Give an error, so i change to
Code:
twrp install /sdcard/module.zip
Everything ok.
Click to expand...
Click to collapse
where I must try this command?
because I have same problem

Magisk made my phone stuck on bootloop unable to uninstall

Last evening Magisk asked me to install it's latest app version (v6.1.0 I suppose, can't remember), and so i did, then it asked me to update the Magisk root itself (to v18.0 I suppose), and so i did. Then my phone was stuck on a eternal
bootloop.
i tried to remove Magisk via TWRP (like many people did before) using the official uninstall .zip file, to no avail; TWRP is unable to unpack boot image.
the log says:
Iperation_start: 'Flashing'
Installing zip file '/sdcard/URAAA/Magisk-uninstaller-20181208.zip'
Checking for Digest file...
Skipping Digest check: no Digest file found
I:Update binary zip
I:Zip does not contain SELinux file_contexts file in its root.
I:Legacy property environment not used in updater.
Archive: /sdcard/URAAA/Magisk-uninstaller-20181208.zip
inflating: META-INF/com/google/android/update-binary
inflating: META-INF/com/google/android/updater-script
inflating: arm/magisk
inflating: arm/magiskboot
inflating: chromeos/futility
inflating: chromeos/kernel.keyblock
inflating: chromeos/kernel_data_key.vbprivk
inflating: util_functions.sh
inflating: x86/magisk
inflating: x86/magiskboot
inflating: META-INF/MANIFEST.MF
inflating: META-INF/CERT.SF
inflating: META-INF/CERT.RSA
************************
Magisk Uninstaller
************************
- Mounting /system, /vendor
- Device platform: arm64
- Found boot/ramdisk image: /dev/block/sde36
- Unpacking boot image
MagiskBoot v18.0(18000) (by topjohnwu) - Boot Image Modification Tool
Parsing boot image: [/dev/block/sde36]
No boot image magic found!
! Unable to unpack boot image
- Unmounting partitions
Updater process ended with ERROR: 1
I:Install took 10 second(s).
Error installing zip file '/sdcard/URAAA/Magisk-uninstaller-20181208.zip'​
After that i also tried redownloading the uninstaller, same error; installing version 18.0 via trwp, same problem; installing version 16.0 from a .zip already used that way, also same problem.
So, why is it not working, did the boot image get corrupted and therefore can't be mounted or booted ?
can I solve this without reflashing my phone and losing my files and app configurations ?
Backgound:
Phone: Xiaomi Mi Note 2, 128 GB storage, 6 GB RAM
Software: MIUI MINote2 Global V9.5.2.0.NADMIFA
TWRP: v3.2.1-0
unlocked and rooted as per: http en.miui.com thread-415067-1-1.html
The error is telling you it can't find the boot image that was supposed to have been backed up when installing Magisk in the first place.
Flashing the stock boot image or kernel usually removes Magisk and fixes these boot problems.
how
gk1984 said:
The error is telling you it can't find the boot image that was supposed to have been backed up when installing Magisk in the first place.
Flashing the stock boot image or kernel usually removes Magisk and fixes these boot problems.
Click to expand...
Click to collapse
where do i found the right boot image to flash ? i had months ago flashed the original rom (all partitions) from the vendor website and using their tool, it came in a big fat zip file.
can q flash it from TWRP or a have to use adb ?

How to patch `system.img` to root the Samsung S10 5G (Qualcomm) device?

Hi All,
Device Detail:
- Samsung S10 5G
- Qualcomm Device
- Model: SM-G977U
- ROM: VZW-G977UVRU2ASH7-20190827135903
- Kernel-Version - Linux version 4.14.83-16633035 ([email protected]) (clang version 6.0.10 for Android NDK) #2 SMP PREEMPT Wed Aug 14 16:23:48 KST 2019
Background: I have
- rooted the device with instructions given by Magisk.
- I can successfully reboot to the recovery rootfs.
Problem: I am trying to modify the `system.img.ext4.lz4` file to root the device with normal boot. I am aware that it will not let the device install OTA Updates.
Unpack-Pack System and make new AP.tar, flash:
- Without any modification to the `system.img`, I have just unpacked `system.img.ext4.lz4`->`system.img.ext4`->`system.img`->mounted to system directory and packed it back to `system.img`->`system.img.ext4`->`system.img.ext4.lz4`.
- Replaced unpack-packed `system.img.ext4.lz4` with the AP `system.img.ext4.lz4` and make a tar of it.
- Then I have flashed it using Odin v3.13 along with BL, CP, and HOME_CSC.
- Odin has show PASS and I have rebooted the device into recovery mode.
- Done the Wipe data/factory reset and reboot to recovery again but released the recovery key combination on splash screen as mentioned in the root instructions .
- The device stuck in a boot loop.
Tries:
1. Disable Dm-verity
- Removed `avb` flag from `boot.img` with
Code:
magiskboot dtb boot.img patch
- Removed `avb` and `verify` flags from `dtbo.img` with
Code:
magiskboot dtb dtbo.img patch
- Patched `ramdisk.cpio` with
Code:
magiskboot cpio ./initrd 'patch false true'
Patched `boot.img` and `dtbo.img` is working fine with magisk patched AP file but the `ramdisk.cpio` creating the issue: Stuck at splash screen when trying to go to recovery after successfully flash with Odin. Download mode is appearing on splash screen.
So, I have used `boot.img` and `dtbo.img` along with unpack-packed `system.img.ext4.lz4` but the result is still a boot loop. I have also tried a combination of `boot.img` and `dtbo.img` along with unpack-packed `vendor.img.ext4.lz4` and flashed the AP.tar with other files but still the result is a boot loop.
So, I want to debug the problem and got to know about `pstore` which preserve the logs when kernel panic.
2. pstore
- Checked that `/sys/fs/pstore` is mounted by the system with following in init file: Grep the pstore using `find . | grep '\.rc' | xargs cat | grep pstore -n -i` and get following result:
Code:
314: # pstore/ramoops previous console log
315: mount pstore pstore /sys/fs/pstore nodev noexec nosuid
316: chown system log /sys/fs/pstore/console-ramoops
317: chmod 0440 /sys/fs/pstore/console-ramoops
318: chown system log /sys/fs/pstore/console-ramoops-0
319: chmod 0440 /sys/fs/pstore/console-ramoops-0
320: chown system log /sys/fs/pstore/pmsg-ramoops-0
321: chmod 0440 /sys/fs/pstore/pmsg-ramoops-0
- Checked the kernel config by pulling the file from /proc/config.gz.
Code:
$ cat config | grep PSTORE
CONFIG_PSTORE=y
CONFIG_PSTORE_ZLIB_COMPRESS=y
# CONFIG_PSTORE_LZO_COMPRESS is not set
# CONFIG_PSTORE_LZ4_COMPRESS is not set
CONFIG_PSTORE_CONSOLE=y
CONFIG_PSTORE_PMSG=y
CONFIG_PSTORE_PMSG_SSPLOG=y
CONFIG_PSTORE_RAM=y
- Check the `ramoops` configuration:
Code:
./sys/module/ramoops/parameters/console_size 262144
./sys/module/ramoops/parameters/dump_oops 1
./sys/module/ramoops/parameters/ecc 0
./sys/module/ramoops/parameters/ftrace_size 262144
./sys/module/ramoops/parameters/mem_address 3241148416
./sys/module/ramoops/parameters/mem_size 1048576
./sys/module/ramoops/parameters/mem_type 0
./sys/module/ramoops/parameters/pmsg_size 262144
./sys/module/ramoops/parameters/record_size 262144
`pstore` setup looks fine but when I am trying the get logs from `sys/fs/pstore` then I found nothing.
I have tried it by two ways:
1. Crash manually with panic kernel using:
Code:
echo 1 > /proc/sys/kernel/sysrq
echo c > /proc/sysrq-trigger
Followed Reading Kernel Logs
2. Flashing non-working rom that cause a boot loop and then flashed a working ROM with rooting steps and checked the file at `sys/fs/pstore`.
I need a favor in:
- Any steps to fix/debug the `pstore` problem?
- Any other way to find the kernel logs?
Update 1: I get the logs from recovery but I am not able to identify the problem.
Logs link: https://drive.google.com/file/d/1b-XNmjpYvH-L8lY0xA0SYr7XcITVCrVS/view?usp=sharing
Description: In this video, I have done the following:
1. Displayed recovery logs before: The last recovery logs are ends with 8.
2. Rebooted the device with a recovery key combination. I have already wipe data partition before making this video.
3. The boot loop happens and in the next reboot, I have pressed the recovery key combination to open the recovery mode where logs that end with 9 displayed.
4. Then I have recorded `last_history`, `last_avc_message_recovery`, `last_log.9` and `last_kmsg.9`
5. `last_history` and `last_avc_message_recovery` looks unchanged(same as before boot loop).
6. Then, I just have tried to mount the system but that didn't work.
7. At last, I have just rebooted the system normally without any recovery key combination.
Some Highlighted logs of last_log.9
exec -f /system/bin/e2fsck -v -y /dev/block/bootdevice/by-name/cache
error: _do_exec: can't run '/system/bin/e2fsck'
(errno 13 : Permission denied)
/system/bin/e2fsck terminated by exit(255)
...
E:Can't read /cache/recovery/last_locale: No such file or directory
...
W:Failed to unmount /efs: Device or resource busy
can't unmount /efs - Device or resource busy
...
W:Failed to set brightness: Invalid argument
I:Screensaver disabled
Atomic Commit failed in DisableNonMainCrtcs
Atomic Commit failed, rc = 0
...
Reboot Recovery Cause is [[BootChecker]RebootRecoveryWithKey]
...
print_recovery_cause() : reboot_reason=[[BootChecker]RebootRecoveryWithKey]
...
[property list]
persist.audio.fluence.speaker=true
...
ro.vendor.build.security_patch=2018-08-05
Supported API: 3
I:/efs is already mounted
W:Failed to unmount /efs: Device or resource busy
check_selective_file:Can't unmount /efs - Device or resource busy
just_reboot_after_update = 1
should_wipe_cahcewipe_cache
-- Wiping cache...
erase_volume(/cache)
...
MDF_I: Completed reset MDF flag!
MDF_I: Completed initialized MDF for Recovery!
mke2fs 1.43.3 (04-Sep-2016)
Discarding device blocksL 4096/153600??????????????????????????????done
Discard takes 0.00051s
Creating filesystem with 153600 4k blocks and 38400 inodes
...
Creating journal (2048 blocks): done
...
copy_logs
...
Cache wipe complete
[Checking pre-multi-csc2]
[start failed section]
sales_code=VZW
Carrier ID=[XAA]
[system partition space check]
The device has /product partition.
[out-recovery]
I:system root image is true, so need to change the unmount point from /system to /system_root
running out-recovery time : 0.000s
running recovery time: 1.738s
copy_avc_msg_to_data(1, )
I:fs_type "ext4" for /cache
copy_file 'proc/avc_msg' 'cache/recovery/last_avc_msg_recovery'
!__RECOVERY_FOR_ASSAMBLY
b_del_recovery_command = true
Rebooting...
## finish_recovery_terminate(del=1, reboot_cmd=reboot, clear_BCB=1)
## finish_recovery(delcmd=1,...
I:Saving locale "en-US"
I:fs_type "ext4" for /cache
I:[libfs_mgr]dt_fstab: Skip disabled entry for partition vm-linux
I:## unlink /cache/recovery/command
copy_logs
I:fs_type "ext4" for /cache
copy_log_file :: create recovery log file '/cache/recovery/log'
copy_log_file :: create recovery log file '/cache/recovery/last_log'
Click to expand...
Click to collapse
Is anyone have experience in detecting problems from the kernel logs?
i can not help you, but we can collect ideas. what about re-sign the system.img? there is a key somewhere, i guess just deleting won't work but maybe it is possible to calculate checksum
or maybe you can switch to SuperSU 2.79 SR3 (latest release from chainfire) or at least look inside the update-binary shell script how to root system.
regarding dm-verity i would start with searching for "verify" flag in your fstabs and remove it. magisk is also doing some hex patches and re-signing, it's the best source to look inside magisk installer zip update-binary/ updater-script, if you have the knowledge to read code
another option is try to port a twrp recovery from another snapdragon (i wonder if somebody did this already) if you can find a porting guide
so the vzw s10 5g is unlockable?
elliwigy said:
so the vzw s10 5g is unlockable?
Click to expand...
Click to collapse
yes
aIecxs said:
yes
Click to expand...
Click to collapse
Figures lol.. I have a g975u from big red n don't plan on buying another lol
aIecxs said:
yes
Click to expand...
Click to collapse
Message me on telegram and I can help you if you help me.. I'm curious in some logs and what not.. I also might have something you can use..
Did you get it working? I have the same phone and I want to use the 600mgz tmobile 5g in a few days, so I need the right rom.
elliwigy said:
so the vzw s10 5g is unlockable?
Click to expand...
Click to collapse
aIecxs said:
yes
Click to expand...
Click to collapse
Snapdragon bootloader unlockable? How?
I'm a VZW customer and can get the phone on an upgrade, but want to root it...
i got a g977p and twrp n magisk working great
do you think it is possible to flash other branding on verizon devices with modded odin?
aIecxs said:
do you think it is possible to flash other branding on verizon devices with modded odin?
Click to expand...
Click to collapse
dunno.. its not possible on n976v..
Was there any luck on rooting the Verizon G977U?
@Vats12 has already successful rooted with magisk in recovery. this thread is for rooting system (kind of rooting where su binary is placed in /system/xbin like for older devices, which breaks OTA)
aIecxs said:
@Vats12 has already successful rooted with magisk in recovery. this thread is for rooting system (kind of rooting where su binary is placed in /system/xbin like for older devices, which breaks OTA)
Click to expand...
Click to collapse
So you want like the supersu method?
ExtremeGrief said:
So you want like the supersu method?
Click to expand...
Click to collapse
Yes, do you know how to do this?
Magisk (guide) does a lot of other things too..
Maybe we can use Magisk to disable the securities and then SuperSu can help in the rooting system?
Vats12 said:
Yes, do you know how to do this?
Magisk (guide) does a lot of other things too..
Maybe we can use Magisk to disable the securities and then SuperSu can help in the rooting system?
Click to expand...
Click to collapse
But why? Safetynet will be gone
What model is the device?
ExtremeGrief said:
But why? Safetynet will be gone
What model is the device?
Click to expand...
Click to collapse
model see OP! i guess because of the buttons needed for booting in magiskrecovery, but the reason is not important only HOW (for Vats12, not for me i don't own this device)
Sorry but this thread needs to be closed
aIecxs said:
model see OP! i guess because of the buttons needed for booting in magiskrecovery, but the reason is not important only HOW (for Vats12, not for me i don't own this device)
Click to expand...
Click to collapse
I don't want to be the one who shouts fake, but the instructions you gave a link to says you have to be able to flash a bootloader first, which means an unlocked blootloader, if you have Verizon rom this is not possible, as the blootloader is locked.
If you did find a way to flash a modified bootloader, or a modified recovery those are the instructions we need, because in fastboot you are unable to do this with a locked bootloader and you are unable to unlock the bootloader on Verizon. If you have a modified bootloader or recovery flashed on your device what did you use to flash it with Odin? Because only way to flash a boot.img is either get into download mode and flash with Odin, or with Edl, if you got into edl mode then can you provide instructions on that, because we would like to know how to get the device into EDL mode as well
Sorry boys this is a hoax.
@DroidisLINUX there is video proof in OP, and again for you:
This is not a tutorial about unlocking and rooting, it is a question how he can modify /system to permanently integrate su

Categories

Resources