Custota icon indicating copy to clipboard operation
Custota copied to clipboard

Crash on boot (logcat access denied?)

Open e-t-l opened this issue 4 months ago • 5 comments

type: crash
osVersion: google/husky/husky:16/BP2A.250805.005/2025081400:user/release-keys
flags: dev options enabled
package: com.chiller3.custota:329984, targetSdk 35
process: com.chiller3.custota
processUptime: 308 + 94 ms

java.io.IOException: Cannot run program "logcat": /storage/emulated/0/Android/data/com.chiller3.custota/files/monitor.log: open failed: EACCES (Permission denied)
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1050)
	at com.chiller3.custota.updater.UpdaterThread.run(Unknown Source:78)
Caused by: java.io.FileNotFoundException: /storage/emulated/0/Android/data/com.chiller3.custota/files/monitor.log: open failed: EACCES (Permission denied)
	at libcore.io.IoBridge.open(IoBridge.java:583)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:259)
	at java.lang.ProcessImpl.start(ProcessImpl.java:118)
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
	... 1 more
Caused by: android.system.ErrnoException: open failed: EACCES (Permission denied)
	at libcore.io.Linux.open(Native Method)
	at libcore.io.ForwardingOs.open(ForwardingOs.java:568)
	at libcore.io.BlockGuardOs.open(BlockGuardOs.java:274)
	at libcore.io.ForwardingOs.open(ForwardingOs.java:568)
	at android.app.ActivityThread$AndroidOs.open(ActivityThread.java:8992)
	at libcore.io.IoBridge.open(IoBridge.java:568)
	... 4 more

crash.log

Running Custota v5.9 on GOS 16 build 2025081400 (rooted with pixincreate's Magisk v28104)

Custota module and app are installed and granted root. Zygisk is not installed. Custota is not set to any OTA server; I haven't set one up yet, so I am using it just to monitor update merge progress.

e-t-l avatar Aug 19 '25 19:08 e-t-l

I suspect you're running into the same problem as https://github.com/chenxiaolong/Custota/issues/139#issuecomment-3032830738. Can you post the outputs of those commands?

Unfortunately, it probably isn't something I can work around in Custota, but you can fix it by manually deleting /sdcard/Android/data/com.chiller3.custota/files.

chenxiaolong avatar Aug 19 '25 20:08 chenxiaolong

Thanks, I tried searching for related issues but wasn't confident that other users' crashes on boot were the same problem as mine.

I ran the commands and the two IDs do match.

What does deleting those files accomplish?

e-t-l avatar Aug 19 '25 21:08 e-t-l

Oh, that's interesting. What if you do ls -lR instead? Is every file also owned by the same ID?

chenxiaolong avatar Aug 19 '25 22:08 chenxiaolong

What if you do ls -lR instead? Is every file also owned by the same ID?

looks like "monitor.log" is owned by a different ID

e-t-l avatar Sep 11 '25 23:09 e-t-l

Weird. That's definitely evidence that the issue occurred. I don't know what would have fixed the permissions on the /sdcard/Android/data/com.chiller3.custota/files directory itself though. Last I checked, Android didn't do that, but maybe it changed with more recent versions of Android.

Anyway, deleting the folder should get things back to normal again.

chenxiaolong avatar Sep 12 '25 00:09 chenxiaolong