yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] Lazy8:
I thought about installing a busybox but was afraid it would Bork something with magisk/safetynet. So you're saying I should install another busybox? Any recommended?

ROM toolbox has one it asks to install on startup.

Thanks for having a look at this, I do appreciate it.

(SOLVED)

Thank you for all the help! I just installed the busybox for ndk from osmosis thru magisk and after a reboot all is working now. I'll check out the app more in depth and will probably be purchasing and buy you a beer as well.

Thanks again for all the prompt help. This community rocks!
[Android Apps and Games] The Analog Kid:
I have SD Maid Pro for sometime now, but I wanted to give "scheduler" a try for the very first time ever; however, I can't figure out how to setup times because there is no such thing inside "scheduler"...
[Android Apps and Games] Oswald Boelcke:
You're screenshot belongs to the scheduler settings (Settings => scheduler) but not to the scheduler itself, where you can make all necessary adjustments.

May I assume you didn't look into the OP prior to posting and therefore didn't find the link to @Dark3n's great Wiki respectively the help documentation? Here's the link to the scheduler part.

Some screenshots attached to prove it works.
[Android Apps and Games] jfive74:
This app is near perfect. Would love to see a batch/select all mode for freezing apps. Any plans to add this? Great work Dark3n.
[Android Apps and Games] Dark3n:
I think we can move v4.8.5 out of beta, can't we? Don't see any new issues in crash tracking or on Github.

[MENTION=935963]jfive74[/MENTION] Batch actions are already available through long press selection.
[Android Apps and Games] Oswald Boelcke:
Absolutely concur. Didn't discover any bug or issues despite heavy use; personally my impression: It's the smoothest running version thus far. Great job. Thank you very much.
[Android Apps and Games] jfive74:
Sorry, i miss spoke. I meant to say for disabling boot items. Instead of having to do app by app. Just select all apps and disables all needed items. Takes time to do 100 apps. Lol.
[Android Apps and Games] Dark3n:
You shouldn't just disable 100 boot receivers though as you don't know what each is necessary for.

Allowing to "batch disable" all boot receivers would cause more issues than it would solve.

People would do it because they think they "improve" something, but in reality they would break half their apps.

Then they would want an undo function, but there is none and they are left with having to reinstall every app that they broke.

If they notice it at all, because messing with receivers can cause really subtle problem.

Boot receivers != Windows autostart. Boot receivers are not inherently bad!
[Android Apps and Games] Dark3n:
Moved v4.8.5 into staged rollout.

Also looking for some feedback on this idea regarding stale data in the Media Provider:

https://github.com/d4rken/sdmaid-public/issues/1309

It seems it affects quite a few people (based on mails I get), but I can't seem to reproduce such an issue on my device.
[Android Apps and Games] Celestial Fury:
What are the current exact ADB command lines available for SD Maid?
[Android Apps and Games] jlb1959.01:
agree!!
[Android Apps and Games] Dark3n:
There are currently no ADB commands available for SD Maid.
[Android Apps and Games] Dark3n:
Just released 4.8.6 ahead of schedule and pushed it to 100% rollout.

https://github.com/d4rken/sdmaid-public/blob/master/CHANGELOG.md

Apparently any app build with aapt2 (with buildtools <27.0.1) can bootloop some CyanogenMod/LineageOS ROMs due to a bug in the system, see:

https://issuetracker.google.com/issues/64434571
[Android Apps and Games] Celestial Fury:
Would this be hard or troublesome to implement? For those without root, a few functionalities activated through ADB is better than nothing. Some other apps that have ADB-activated functions include BBS, Greenify, Autoset.
[Android Apps and Games] Dark3n:
Not hard, current AppControl modules allow for this easily since the last rewrite.

Not sure about onboarding, but probably this is only for power users so not much onboarding/setup screens necessary, maybe just some wiki docs.

Rather potentially troublesome regarding Google Play compliance, see:

https://www.reddit.com/r/androiddev...eceived_a_mail_from_google_about_bind_device/

Maybe some other apps have dealt with this and I could take some hints from there (feel free to comment on the github tickets with such info), but this is what moved such a feature low on my "want to do list".
[Android Apps and Games] Rochey13:
Can't install apks using explorer?

Hi all, I've been using SD Maid for the last couple of years for keeping my phone in tip top shape and I remember that it had an included "Explorer". Last time I tried it was a long time ago and it couldn't do a couple of things that I need from an explorer. These are unzipping zip files and installing apk files. I tried it today and found I could unzip files - which is great but I can't seem to install apks. If I try and open one a white screen pops up for about 1/4 second and disappears.

Should I be able to install apks from explorer?

If so any ideas what's wrong?

If not, what is the purpose of the explorer?

I'm running the latest Android 8.1 beta on a Pixel XL phone, without root.

If anyone could give me some info that would be greatly appreciated.
[Android Apps and Games] Dark3n:
[MENTION=516936]Rochey13[/MENTION], Nice catch.

https://github.com/d4rken/sdmaid-public/issues/1313

Wasn't aware an extra permission is needed on newer Android versions.

Expect a fix in the next update.
[Android Apps and Games] Rochey13:
Awesome! I thought something didn't seem right.

I'll then be able to remove the other file managers that I've got installed, thank you.
[Android Apps and Games] Dark3n:
SD Maid v4.8.7 is now available as beta. You get updated translations and lots of clutter updates, especially fixes for two annoying false positives (fasthub & magisk).

On another note:

I wanted to open source parts of SD Maid for a long time. Especially root related code in an effort to make it easier to dev well-behaved root apps. I think that the more root apps there are, the better for all other root apps it is, because of a healthy ecosystem of "root" apps.

My first goal was always to open-source the shell related code as it is the basis for all root apps.

I finally got around to this some hundred hours ago and it all seemed simple on first thought. Just refactor out the code into an extra library, some extra spit and polish, and done. This actually wasn't too bad. But... after looking at the extracted code I wasn't happy with it. It worked well in SD Maid, but was also very specific to SD Maids needs. I just didn't feel good about the code, because I knew I could do better, but why throw away perfectly fine working code?

Well I couldn't help myself and threw it away, started from scratch. 127h later... (dam race condition debugging in RxJava) it's "ready". Previously SD Maid used a set of "StaticShell" and "InteractiveShell" classes that were similar to libsuperuser, the new library I call "RxShell" is based on RxJava and takes a layered approach (Process -> Shell -> CommandShell), which was inspired by another shell lib called rootfw.

In the end the rewrite idea wasn't too bad as I'm quite happy with the result, I like the code, it's more flexible, easier to test and faster too.

Because the basic foundation of SD Maid changed, I don't want to do a "real" beta release yet and would just like to do some small circle testing. I'm not too worried about something going horribly wrong, because all other code is still the same, but I expect a few crashes, especially when multi tasking in SD Maid. Dealing with race conditions is what cost me the most time.

Attached to this post is SD Maid v4.9.0, which based v4.8.7 but with the new shell system.

Just use SD Maid as you would normally, and if you see errors that are not present in v4.8.(6/7) then make a github ticket (preferably with your install ID from the debug menu so I can check whether an automatic report was uploaded or I need a debug log).

Please don't spread the apk of v4.9.0 outside of XDA, after our little testing round here, I'll do some more polishing and fixing, then release the library and also a real v4.9.1 beta release.

Edit: Attachment removed.
[Android Apps and Games] patrickdrd:
is there any way we can clear unnecessary increasing in size data?

I mean there are some apps accumulating data over time instead of cache, don't know why is that, but is there any way to clean only "cache-like" data and keep valuable ones?

edit: found out I have to delete files in

/data/data/*/files/.fabric/*.*

can you help me set it up in system cleaner (user)?

edit2: ok, I found that, doesn't it support wildcards?

edit3: got them with regular expressions :)

great option I didn't know it was there for so long
[Android Apps and Games] Dark3n:
The AppCleaner already targets files that are "cache-like" and can be described as "expendable".

Specifically the "Hidden caches filter" targets these types of files. You can check in the Explorer for files marked with the AppCleaner icon.

Some of those "fabric" files might already be included in the filters "Bug reporting" and "Analytics".

I'm always open for additions, feel free to open a ticket things you find.

I think there are many people who don't know all of SD Maids features. :D

Pro tip:

When creating user filters with regexes, add an additional criteria to speed up the scan. Regex are expensive, but SD Maid compares them last.

If you add an additial criterium that makes SD Maid skip a file early, the regex doesn't have to be evaluated.

In your example path that could be:

LOCATION=PRIVATE_DATA

PATH_CONTAINS="/files/.fabric"
[Android Apps and Games] patrickdrd:
actually I did it with the following regexp:

\/data\/data\/.*\/files\/\.Fabric\/.*$

in order to delete ".fabric" folders of every app that had files there,

and I had seen that there were some and their "data" were stored there and weren't cleaned by sd maid

(ok I hadn't enabled the settings you said in appclener though)

also I deleted the inoreader databases and cache that were also not deleted and

last but not least viber images (considered as "junk" after seen in my case)

and of course I didn't know about the appcleaner's capabilities, I went on and enabled some of them and you were right of course :)

two more questions please:

1) I guess these setting I make in the "manual" system cleaner and app cleaner are saved for the scheduled process too?

and

2) is there a way to make a "manual" backup of the settings?

I found a folder with the json filters, are they "imported" automatically?

or the only way somebody can restore sd maid automatically is using titanium backup?

and please add an option to create a 2nd schedule,

I use two phones and on the weekend I use the 1st from the moment I wake up to the moment I go to bed and

rarely the 2nd and on weekdays I use the 2nd on working hours and I switch on the 1st on the afternoon, so the schedule doesn't run (I want it to run every morning)
[Android Apps and Games] Dark3n:
> 1) I guess these setting I make in the "manual" system cleaner and app cleaner are saved for the scheduled process too?

The scheduler runs the same tasks as the scan/delete UI buttons, so same settings apply.

> 2) is there a way to make a "manual" backup of the settings?

Exclusions and user filters can be exported to json files, the other settings can't.

You could back the files with titanium backup, but would only recommend restoring to the same SD Maid version.
[Android Apps and Games] Oswald Boelcke:
Github ticket opened regarding v4.9.0-beta.
[Android Apps and Games] Gerolianis:
Did anyone of 4.9.0 beta testers experience excessive battery drain? I did, but I wouldn't swear it's related to SDMaid.
[Android Apps and Games] florincristea:
Me too with Samsung A3 2017 and Nokia 3!
[Android Apps and Games] Shyam Bairi:
I use Folder Mount app to link some folders in internal storage to external sd card.

When i use Duplicates finder in SDMaid, all the files in those folders appear to be twice i.e. in SD card & in internal storage. But actually they are only in SD card.

The storage analyzer also gets wrong with it. It shows wrong internal storage size because it counts the size of files that are in sdcard but appear to be in internal storage.

I can surely unlink the folders before using SDMaid, but everytime feels annoying.

Please can you get SDMaid to recognize Folder Mount linked folders as it does with Link2SD files.
[Android Apps and Games] Dark3n:
[MENTION=4980140]Gerolianis[/MENTION] [MENTION=4400742]florincristea[/MENTION]

When? While running SD Maid lots of energy consumption is expected as we are trying to finish as fast as possible. It would not surpise me if this increased in 4.9.0 as the scan is 20-50% faster too in some cases.

If you noticed this afterwards, when SD Maid was done, then we have to differentiate between SD Maid consuming energy and other apps.

If the system shows SD Maid having increased energy usage, even after running, then I probably introduced a bug with runaway processes.

If other apps show increased energy usage, then those likely missbehave due to something SD Maid did, this should not be new since 4.9.0 though, as 4.9.0 only changed the shell system, deletion and matching is the same as 4.8.7.

"Battery consumption" is a very very very very subjective issue (which is also the reason many people think many "battery optimizers" work, hint: most don't), but if you have concrete data to support it, I'd be happy to look into it.

[MENTION=7995023]Shyam Bairi[/MENTION] In most cases an exclusion would be the best solution, but if this is for some default pathes are are present in every "Folder Mount" setup, then I can look into it. This needs lots of help from you though as I don't use folder mount ;). Please make a ticket on github, with an issue description, how to reproduce, a few screenshots so I understand it and a debug log from the duplicates scan.
[Android Apps and Games] Shyam Bairi:
Excluding folders work for resolving duplicates finder.

The issue is with storage analyser. Folder Mount actually mounts a user desired folder in sdcard to any other folder of same name in internal storage.

I guess there would be some way to recognize those mounted folders and exclude them from storage analyzer.

Is there any?
[Android Apps and Games] TECCC:
its only possible to create user specific folders for cleaning , like whatsapp sent images/videos/voice messages , right ?
[Android Apps and Games] Oswald Boelcke:
Using v4.9.1-beta since you released it. Running without any issues or problems - at least in that way I'm using SDMaid.

I didn't observe any exceptional battery drainage at all during deep sleep. During utilisation of SDMaid, no battery consumption I've to worry about.
[Android Apps and Games] Dark3n:
v4.9.1 is now available. This is a beta only version.

https://sdmaid.darken.eu/download/beta/

http://sdmaid.darken.eu/changelog

http://sdmaid.darken.eu/issues

Notes:

SD Maid switched from using `ctime` (metadata change) to `mtime` (content change) as we are mostly interested in file content, not metadata, especially with metadata change times sometimes being unreliable depending on the storage location.

This is now the first official version of SD Maid using RxShell (https://github.com/d4rken/RxShell), an open-source library I wrote for using shells on Android. See here for some more details on the how/why. I'll also be releasing another open-source library as extension to this that adds a few tools specific to root related tasks.

I've also written an open-source library to help use MVP principles in apps (https://github.com/d4rken/ommvplib) which I've also started integrating into SD Maid. SD Maid already uses MVP principles, but does not yet sepperate all concerns nicely (huge codebase, grew organically). I'm rewriting code pieces gradually. In the end this benefits us by allowing for easier fixes/enhancements and better unit test coverage to keep us error free.

This probably doesn't concern most of you beta testers, but secondary storage permission setup is now much easier on Android 7.0, no more manually selecting the sdcard path, just a yes/no popup. Android added a nice API for this since Android 7.0.

Android 8.0 related issues such as not being able to install APKs or shortcuts for Activities are fixed now too.

Thanks to nice user reports the AppCleaner can now also go a bit more aggressively after facebook related hidden caches.

Check the full changelog on GitHub for all the details.

Huge shoutout to everyone who created tickets on Github, check out:

https://github.com/d4rken/sdmaid-public/milestone/34?closed=1
[Android Apps and Games] Vagelis1608:
Damn, you have been at work :laugh:

Great libs, too. Certainly useful.

Keep up the good work! :victory:

Also:

"While this is obviously :^) the best library, there are alternatives you could be interested in:"

This actually made me laugh out loud on a bus :laugh:
[Android Apps and Games] Dark3n:
v4.9.2 is now available.

I'm curious whether anyone notices a performance difference between v4.9.1 and v4.9.2.

v4.9.2 is the first SD Maid version where shell output is not stored into a log buffer (for debugging support).

Not doing that should theoretically improve scan performance as less work has to be done for each line read from a shell.

It also makes it a bit more difficult to investigate problems.

Often I prefer sacrificing a bit of performance to make it easier to fix bugs, but if this is a significant difference in performance it might be worth it.

The logging be returned to pre v4.9.2 behavior by changing the debug level in the debug menu of SD Maid, in "BETA" builds the logging is also as in pre v4.9.2.
[Android Apps and Games] infatality:
Yes.. Definitely faster scanning and deleting than previous versions. Very noticeable on older devices too. Like my old oneplus one too!
[Android Apps and Games] jlb1959.01:
huge difference....
[Android Apps and Games] Dark3n:
Would love some measurements.

Device/Root/ROM/free space/used space.

SD Maid v4.8.7 vs 4.9.1 vs 4.9.2.

In the debug menu (long press settings) there is a setting "Armed: true" if you toggle it (need to kill SD Maid) to "Armed: false" ALMOST all tools run in a demo mode where "echo ....." instead of "rm ...." is executed.

You can use this to make comparisons more accurate.
[Android Apps and Games] IronTechmonkey:
I'll try to get actual time measurements later but for now, a few of the scans that I run frequently (Quick Access [CorpseFinder - SystemCleaner - AppCleaner] and Storage Analyzer > /data do seem somewhat quicker in 4.9.2 than in 4.8.7 although not to the extremes previously described, in fact at first I thought it was a placebo effect but after a few more tests a while later I do think there is a difference.

Tests have been on a Moto G 4g (Peregrine/2013-2014) in recently clean flashed LOS14.1/N7.1.2 w/LOS SU, w/32GB Ext Sandisk Extreme SD as portable storage, device configured for minimal background activity, with no other apps running, recently cleaned by SD maid but not so recently that SD maid is a presence other than its normal activity at boot, and other boot scans subsided.
[Android Apps and Games] Dark3n:
v4.9.4 is now considered stable and currently in rollout replacing v4.8.7.

v4.9.3 and v4.9.4 were small hotfixes because the bug i tried to fix fooled me twice...
[Android Apps and Games] Vagelis1608:
"99 bugs in the code.

Take one down, patch it around.

127 bugs in the code!"
[Android Apps and Games] xdarthanonx:
Why is it trying to connect to utzbox.darken.eu?
[Android Apps and Games] patrickdrd:
good question, I saw internet activity too when I was using a firewall, why is an app like this need internet?
[Android Apps and Games] dukelc:
Internet is for ...
[Android Apps and Games] xdarthanonx:
I have these disabled.
[Android Apps and Games] Dark3n:
Update check. The app send the SD Maid version, the server looks up the version number and then tells SD Maid whether to display the update popup.

In a future version also to unlock features without requiring an extra app for people who don't want to use Google Play.
[Android Apps and Games] mistermojorizin:
I'm on a kindle fire hd10 2017 and it has a weird setup in that the cpu is 64bit, but the insruction set is 32 bit. In overview, sd maid recognizes the architecture as armebi v7a. I am rooted with supersu from play market and I believe it installed the 32 bit version of su, consistent with the play market giving me all 32 bit versions of google apps and 64 bit versions of google apps not installing on my system.

Sdmaid says root and busybox is available, but wont do any root functions. I looked in the supersu log and it has this error from sd maid:

I've tried disabling root check in debug settings. Same result. Any guidance?
[Android Apps and Games] Dark3n:
Disabling the root check just means SD Maid assumes you are not rooted.

Do other root apps work? This seems more like a root issue itself.
[Android Apps and Games] mistermojorizin:
Yes, every other root app works as expected (TiBu, Adaway, Rom Toolbox, All in One toolbox, root explorer, link2sd, etc.). Root checker pro says it is rooted.

But I do know there is this 32 bit vs 64 bit thing with the "su," I'm not sure how to convert "su" to 64 bit or if I should. But was wondering if I could maybe fix it on SdMaid's side, since that is the only problem.
[Android Apps and Games] Dark3n:
Mail me a debug log of this, so we are not talking past each other.

> Sdmaid says root and busybox is available, but wont do any root functions.

What does this mean?

Do you mean SD Maid shows rooted in the overview, but when you use the Explorer to browse /data/data , you can't do that?

Then this might be an issue with SD Maids toybox binary, in that case I would have expected SD Maid to detect this though and try to use another one. I could potentially improve the compatiblity check here to fix that.

If the Explorer works and you mean specific functions like disabling apps not working, then this might be an issue with the 32/64bit check as the commands look a little bit different depending on the architecture.

That check looks like this

@TargetApi(Build.VERSION_CODES.LOLLIPOP)
public static boolean isSystem64Bit() {
return ApiHelper.hasLolliPop() && Build.SUPPORTED_64_BIT_ABIS.length > 0;
}

and that determines

public static String getSetLDLibraryCommand() {
StringBuilder sb = new StringBuilder();
sb.append("LD_LIBRARY_PATH=");
if (ArchHelper.isSystem64Bit()) {
sb.append("/vendor/lib64").append(":");
sb.append("/system/lib64").append(":");
}
sb.append("/vendor/lib").append(":");
sb.append("/system/lib").append(":");

sb.append("$LD_LIBRARY_PATH");
return sb.toString();
}

Many devices need the specific pathes added for the packagemanager to work. The 64bit libs would be looked up before the 32bit ones. If the library exists in both 32bit and 64bit, SD Maid thinks your system is 64bit, but needs 32bit.... yeah then we could see this error.

How do we solve this nicely? A hardcoded workaround for the kindle fire is dirty...

Maybe expand the setup routine with a new function "testIfWeReallyNeed64bit()" and then we use the old 64bit check with a non invasive command check for an error, then retry as 32bit and if that works assume we need 32bit. Then again if this fails for other reasons we could make debugging quite difficult.

Send me a debug log first so I can see the error message.

I'm a bit suprised this hasn't come up before. Are you the only SD Maid user on a rooted kindle fire hd 2017? :confused:
[Android Apps and Games] ogisha:
I reported this bug few months ago, but I did not have time to do some further investigations and make the log files. Meanwhile, the bug stayed until the latest 4.9.4 version, so I had to use 4.7.6 version all of the time.

Today, I upgraded firmware to L09C432B395 and I just want to report that the latest 4.9.4 version works as supposed to.

So, if anyone have similar problems on the same device, the solution is to upgrade the firmware.