topjohnwu / Magisk

The Magic Mask for Android
GNU General Public License v3.0
47.16k stars 11.93k forks source link

init: cannot setexeccon('u:r:magisk:s0'): Invalid argument #8344

Open KaMyKaSii opened 2 weeks ago

KaMyKaSii commented 2 weeks ago

Device: Quantum Go Q2 Android version: 7.1.1 Magisk version name: 8e82113b Magisk version code: 27007

Following the last issue, I decided to update Magisk through recovery, but after that the root was lost. The hidden app says that the root connection was lost and when restoring the default app it says that root is not available. To record the bootlog I decided to do a clean reinstall. For some reason the logcat disconnects during boot so I recorded a second one as soon as possible. When returning to TWRP, I noticed that the /cache/magisk.log file is not created so I imagine that Magisk is failing at a very early stage. bootlog-magisk27007-clean-install.zip magisk27007-patched-boot.zip stockboot.zip

yujincheng08 commented 2 weeks ago

Try patch boot instead. TWRP installation is not promised to always work. If it does not work, you use patch boot instead.

KaMyKaSii commented 2 weeks ago

Try patch boot instead. TWRP installation is not promised to always work. If it does not work, you use patch boot instead.

I patched the boot image and flashed it but it still behaves the same way magisk_patched-27007_4yI8j.zip

yujincheng08 commented 2 weeks ago

Follow this to grab a bugreport: https://developer.android.com/studio/debug/bug-report

KaMyKaSii commented 2 weeks ago

Follow this to grab a bugreport: https://developer.android.com/studio/debug/bug-report

bugreport-NMF26X-2024-08-29-18-06-55.zip

yujincheng08 commented 2 weeks ago

too late. reboot your device and grab bugreport as soon as it boots

KaMyKaSii commented 2 weeks ago

too late. reboot your device and grab bugreport as soon as it boots

bugreport-NMF26X-2024-08-30-00-08-59.zip

yujincheng08 commented 2 weeks ago
<11>[ 113.884845] (1)[1283:init]init: cannot setexeccon('u:r:magisk:s0'): Invalid argument
canyie commented 2 weeks ago

Root was working on 27002, right? Can you narrow down which Canary build the regression starts occurring? And is your device 32-bit?

KaMyKaSii commented 1 week ago

Root was working on 27002, right? Can you narrow down which Canary build the regression starts occurring? And is your device 32-bit?

Yes, root works on 27002. I tested 27003 and root no longer works. The device is 64-bit

canyie commented 1 week ago

Both canary and debug builds don't work right? There are many new sepolicy-related commits in 27003 and these three commits seems suspicious: d20b30c7710584bb15bbf02accd991c8d8627663 d654b9cb97dbf8fd532434e0f745e4835c72dafa and 865fca71a5954b3fc80f5f261fab889a99859dc2. I'll take time to investigate this issue when I'm free.