yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] Shyam Bairi:
Hi [MENTION=608746]Dark3n[/MENTION]

1. Will you please add a "Keep Last Modified Date" option in File explorer settings.

To preserve the last modified date of files while doing copy/cut paste operations.

Like it's there in Mixplorer. It's for root users.

It's very helpful and a need. I usually use SDMaid's file explorer to move large number of files to SD card as I feel it to be more error proof and reliable. But the change of last modified date becomes a trouble.

Recently I moved my huge WhatsApp Media from internal to SD card, but all the huge number of images and videos got jumbled up in gallery and while viewing them in other file managers. SDMaid moved all the files randomly. Atleast it should move them in order of their chronology. That'd retain their order.

I tried sorting them with date modified and date taken, but all in vain. Now I can't find the last images that I received.

Please add this small root feature to make SDMaid's root explorer complete. Also about that moving files in order of chronology idea, for non-root users.

2. Also can you add a backup restore feature to save all the settings and exclusions. So that when we reinstall the app, it would work as it was before out of the box.

Currently we can export only exclusions, but we have to again set all the system cleaner, corpse cleaner, scheduler, explorer, general, all the settings.

Adding this feature would be a great relief.
[Android Apps and Games] Dark3n:
[MENTION=7995023]Shyam Bairi[/MENTION]

1:

a) Timestamps: I'll have to check how supported that flag is among the `cp` binaries on Android but I think it's generally supported. Next major, maybe minor update. Make a feature request ticket on Github for this please.

b) Ordering: Depends on how you do the operations. All copy/move operations go through the shell and then then `cp`/`mv` applets I don't have an influence on the order use by the applets. So if you act on a single top element, i.e. folder with pictures, then I can't influence the order. If you go into a folder, select all, then copy/move, SD Maid will run the operations individually and then I can influence the order. If this is not behaving as expected then this might be a bug. I think array lists are used, so order should be preserved. If it is the later case, please create a github ticket with a description how I can reproduce the issue.

2: It's planned, but I can't just wipe the settings to create a clean backup/restore system as that will piss every user off and I can't (don't want to) force a backup/restore system without a rewrite as that would just end up in headaches further down the road (backwards compatibility etc.).

I want to split responsibilities so each tool is responsible for it's own settings such that in future updates we don't accidentally break tool A when changing something in tool B. Currently the settings are kinda shared in a general settings object. I'm moving the settings into extra modules. This has already happened for the duplicates tool (which is also why it now has it's own reset to defaults option in the settings). I need to do this for the other tools too, then I can add a backup/restore function. I know this is requested a lot and I'm taking quite long for this :(.
[Android Apps and Games] carlese:
[MENTION=608746]Dark3n[/MENTION] my system keeps crashing after I uninstalled some apps. My only suspect is that SD Maid removed some leftover files that should not be deleted.. I tried to clean flash, everything was working, then uninstalled some apps and then 80% of my apps are crashing now, and a dirty flash doesn't fix it :( I don't know what changed in the last build, I've been using your software for a long time and never happened (and maybe it's not sd maid fault)..
[Android Apps and Games] Vagelis1608:
Which apps did you uninstall?
[Android Apps and Games] carlese:
Some apps like Spotify, Sync.me, Google Translator, Facebook and others.. I see that there are some logs in the statistics section of sd maid, how can I post them?

I think it has something to do with webview, I uninstalled chrome (built in my rom), SD maid cleaned the leftovers and now even if I install it again or install webview from play store all apps crash.. Is there a way to exclude this?

Edit: it's 100% chrome/webview, I managed to get everything working again so if there's a way to prevent this it would be great!
[Android Apps and Games] Dark3n:
The question is whether the issues are caused by uninstalling the app itself, or by uninstalling it through SD

If it is the later case, please provide an SD Maid debug log of you uninstalling it and a sample of the system log showing the crashes.
[Android Apps and Games] carlese:
I clean flashed everything and I'm out for the weekend so I can't really help now, I'll try next week to reproduce the case.. Thanks!
[Android Apps and Games] Vixificent:
SD Maid has been quite useful, now the last clean deleted all data in /data partition apparently. I thought it was just trash but in fact app data of all apps is gone. Just cleared up apps in a drawer. Didn't tinker with any settings. That is unacceptable. I don't usually trust cleaner apps, so SD Maid unfortunately joins them as well for me. Any good alternatives to that?
[Android Apps and Games] KOLIOSIS:
No problems here on my phone,sounds like user error to me.

Why don't you provide a bit more info (in the form of a bug report/etc... to the developer) regarding your situation before you make negative & false blanket statements regarding this app.....................
[Android Apps and Games] Vagelis1608:
I have been using SD Maid for several years now.

There never had any issues, especially this big.

Either something is wrong with your ROM or you messed up something.

The dev will certainly want to take a look at this.
[Android Apps and Games] lekiaM:
I think SD Maid doesn't like to be themed. Once in a while I'm getting soft reboots while scanning and automatically cleaning stuff. Without theming, it doesn't happen... ?
[Android Apps and Games] Vixificent:
Well similar story until now. I don't know why, it was just way too unexpected :confused:. Enough to be inconvenient though. SDM use to work like a charm on all of my devices, also on the following setup: Stock Z3C with SuperSU and xposed, debloated of Google - microg, cyberian camera mod, adaway, gravitybox, xprivacylua. I think no logs available, hastily uninstalled SD Maid just after that thing happened...
[Android Apps and Games] tonino2424:
Advanced Wipr querry

Could someone kindly tell me where is wipe>advanced wipe is located? Please provide the exact path. Thx
[Android Apps and Games] Oswald Boelcke:
I apologise but I haven't made your experiences yet at all. SD Maid Pro (currently v4.10.11), themed by PitchBlack developed by Altan KRK, is running like a charm and without any issues on our three Samsung GT-i9305, all driven by RR-N-v5.8.5-final. I believe Altan include SD Maid into the theme about three or four versions ago.

Altan is not only the developer of PitchBlack but also one of the main drivers behind Resurrection Remix i.e. I was convinced that his theme perfectly integrates into the ROM.

I don't think that your experiences are SD Maid related but solely to the theme (correlated with the ROM in use). Themes can be poorly (or my personal opinion, are occasionally poorly) coded and pending on the ROM in use, create forced closings of an application or force crashes of the system / main system components like System UI and reboots. Here you find some of my experiences from two years ago.

Ultimately, I suggest to contact the developer of your theme, report your issue to him, and give the developer a chance to fix the problem.

What do you mean? Wipe and advanced wipe in which context? Did you already check the complete Wiki?
[Android Apps and Games] lekiaM:
I think it's an Oreo bug. Now that i don't theme, it happens once a while anyway. When it's scanning the System and App cleaner at the same time, and "scan and delete in a single pass" enabled, it soft reboots half way.
[Android Apps and Games] Dark3n:
[MENTION=6364688]Vixificent[/MENTION] To look into this I need a debug log. You should be able to safely do this as you just need to record the scan, if you don't press delete, nothing will happen. Which SD Maid update, Android Version? Which tool did this? What changes did you make to SD Maids default config? Did you use any mount/link scripts?

Debug log: https://github.com/d4rken/sdmaid-public/wiki/Reporting-a-bug#debugrun-log

[MENTION=7976298]lekiaM[/MENTION] Device reboots are almost always caused by ROM/kernel/root issues. If SD Maid has been wrongly themed it would likely just crash. SD Maid puts a lot of load on the system which often tends to surface some otherwise rare instabilities in systems.

As [MENTION=7408621]noc.jfcbs[/MENTION] said, some theming can also crash the System UI which often makes it look like a device reboot, when in fact it's just a soft-reboot where the UI relaunches.
[Android Apps and Games] Dark3n:
Did you find time to reproduce this and record a log ? [MENTION=6364688]Vixificent[/MENTION]
[Android Apps and Games] patrickdrd:
so after upgrading to android N 7.1 and reading that we have to clean the cache manually, is sd maid useless?
[Android Apps and Games] Vagelis1608:
I am on android 7.1.2 ( ResurrectionRemix ) and SD Maid works without a problem.
[Android Apps and Games] patrickdrd:
you're using a custom Rom and you're root I guess? I'm on stock and unrooted
[Android Apps and Games] KaMyKaSii:
[MENTION=608746]Dark3n[/MENTION] It is not a bug that hurts usability, but if you open SDMaid, put it to start AppCleaner and quickly click the home button, the notification will tell you that you are working on two tasks, not just one. If you can not reproduce there, I'll provide the logs
[Android Apps and Games] Dark3n:
Not 100% sure, but I think the 2nd task is the setup task (checks, conditions, storage etc.) that runs before any other task (e.g. appcleaner scan).

Would I be correct when saying that you can only reproduce if SD Maid is not yet initialized?

I think it's worth a bug ticket though as completion of the setup task does not update the notification to "1 Tasks", probably an edge case due to the setup task being a "special task".

Maybe we could force tasks to have a "label" and then display this label in a comma sepperated list in the notification? Then it would be clearer what is happening too.
[Android Apps and Games] Dark3n:
Hyperbole much?

SD Maid is a set of tools, and one aspect of one tool has changed.

Assuming you only cared about deleting the default caches on a schedule, which means that you only wanted an automated way of pressing "Clear cache" in the system settings, then it may no-longer be usefull to you.

To achieve pre Android 6.0 behavior without root you would have to use both. AppCleaner and manually press the "Clear cache" button in the system settings. The order doesn't really matter. I can understand that this may be too inconvenient for some. Would it be worth it? I'd say yes, but I also don't wipe all caches everyday. How much space each action frees depends on SD Maids configuration and your apps. Usually it's around 70-80% in default caches (deleted by the system), and 20-30% in non-default stuff (only found by SD Maid). YMMV

The specific restriction you are referring to is actually not a new restriction, but was a "flaw" that was abused up till Android 6.0 to clear private caches. You can read up on the full history of freeStorageAndNotify here.
[Android Apps and Games] Freak3672:
Editing as I got the solution!
[Android Apps and Games] Andy_G4:
I support this suggestion, a lot of empty folders clutter our phones.
[Android Apps and Games] IronTechmonkey:
System Cleaner > Filter Manager > Empty directories (enable)

Note: That may include empty folders that are used by apps as well as user created folders, but then you could use exclusions to refine the filter. To put that in perspective: I've found > 500 empty folders on device but would only delete a very small percentage of them, so small in fact that I just disable the "Empty directories" setting entirely.

If that does not work for you then you might want to provide more device/rom details.

FYI, you can learn a little bit more about this by searching the thread for empty directories, empty folders. ;)
[Android Apps and Games] ab1jx:
Can SD Maid delete the Google search bar on the home screen of Android 5.02?
[Android Apps and Games] Dor71:
No.
[Android Apps and Games] Vagelis1608:
If it is a separate app, yes.

If it is part of the launcher app, no.

Check the launcher settings.

There might be an option to disable it there.
[Android Apps and Games] ab1jx:
Interesting, I used Dropbear to ssh to it and did:

root@surnia_umts:/ # ps | grep -i google

u0_a43 1807 836 885436 56728 ffffffff b6f681e8 S com.google.android.googlequicksearchbox

u0_a16 1826 836 1162296 54844 ffffffff b6f681e8 S com.google.android.gms

u0_a16 1932 836 832456 60860 ffffffff b6f681e8 S com.google.android.gms.persistent

u0_a51 10411 836 709468 18796 ffffffff b6f681e8 S com.google.android.calendar

u0_a43 12764 836 804108 36984 ffffffff b6f681e8 S com.google.android.googlequicksearchbox:interactor

u0_a43 12784 836 837560 83440 ffffffff b6f681e8 S com.google.android.googlequicksearchbox:search

u0_a19 12829 836 663784 17936 ffffffff b6f681e8 S com.google.android.partnersetup

u0_a16 12883 836 672696 24216 ffffffff b6f681e8 S com.google.process.gapps

root@surnia_umts:/ #

The second column is the process ID. I can kill (one at a time) the processes for googlequicksearchbox and the interactor but they keep popping back with new process IDs like I haven't killed the parent. My busybox doesn't have pkill or pstree. At this point I don't know what's spawning those processes.

My guess would be they're spawned by some google process that's necessary and that also spawns others, it's like a daemon or service that keeps running. I didn't see the searchbar disappear even momentarily while I was killing processes but I might have missed it.

If I do a kill -9 on the process id that one goes away but another pops back with the same name and a different number. I just tried killing the one with persistent in the name and both searchboxes, they all came back with different process numbers. It's almost like fighting with selinux. You can do something but it notices, you don't get away with it.

There are kernel sources here: https://github.com/MotorolaMobilityLLC/kernel-msm but then there's the Google userland stuff that's Android 5.02 also. I think that's available.
[Android Apps and Games] txpxsx:
My scans all stuck on in queue

Rooted OnePlus 5 OOS 5.1.1
[Android Apps and Games] Emilyu:
Good Tools:good:
[Android Apps and Games] txpxsx:
I fixed this by installing Magisk Manager and grant access to root. My bad

Thanks
[Android Apps and Games] patrickdrd:
lol, epic:

Just got a bad rating because SD Maid's animation is drinking coffee with the left hand...

https://twitter.com/d4rken/status/996025737189699585
[Android Apps and Games] kyzn:
People are still offended by lefties? Lol. As a lefty, boy do I bother some people.
[Android Apps and Games] dimoxa6233:
Can the program remove randomly needed system files? 8.1
[Android Apps and Games] Dark3n:
What is a "randomly needed system file"?
[Android Apps and Games] aankkurr:
Every time SD Maid (Pro) runs, I need to login again to Netflix on Shield TV (root).

And also I am loosing all downloaded AdAway sources, I have to download again.

Is there any suggestion other than ignoring these folders?
[Android Apps and Games] Dark3n:
Depending on what tool deletes them, you could turn off a filter.

Search in SD Maids statistics to find out which tool is responsible.
[Android Apps and Games] patrickdrd:
ok, so I've rooted one of my devices, cache is cleaned automatically,

but I've noticed around 1,5gb of "system data" space (in diskusage app),

is it possible using sd maid to empty that (reserved) space?
[Android Apps and Games] radz_:
I'm wondering why SD maid is not asking for Root Permission.

All other apps works fine..

It just say. "Deny" [MENTION=608746]Dark3n[/MENTION]
[Android Apps and Games] IronTechmonkey:
I'm not sure what is Magisk's default setting for app permissions requests (Ask, Allow, Deny) but AFAIK most SU managers would start with Ask, which implies that at one point SD Maid might (or might not) have been manually set to "Deny" as shown in your screenshots. In any event have you tried removing permissions for SD made in Magisk and or manual assigning them. Does the same thing occur in a fresh installation of SD maid? FWIW, I'm getting proper SU for SD maid in LOS 14.1 with native LOS SU (and I'm flashing ROMs today so will have opportunity to test again later).
[Android Apps and Games] radz_:
I just set Request Permission to "Grant" but the toast notif still says "Deny"

SD is not even listed in Superuser access. Meaning no request pop-up.

As a side note, im using the unofficial Magisk by [MENTION=3306843]kantjer[/MENTION] which is a fix version of 16.4, BUT again all other apps works perfectly fine.

(I just flash the latest firmware for OP5T)
[Android Apps and Games] Dark3n:
This is known to happen with all super-user apps sometimes. At least I've seen it with SuperSU too.

I never found out what exactly happen but it seems to be some kind of database issue.

I think SD Maid is somewhat more prone to it as we generate a lot of su requests.

(Maybe the bug itself is then a race condition?)

The general approach to troubleshooting would be (arranged by escalation):

1: Just reboot the device

2: If app is listed in the app su app, remove it, then reboot.

3: Go system -> su app -> wipe data, then reboot

4: Uninstall SD Maid, reboot, reinstall SD Maid

5. Reroot
[Android Apps and Games] IronTechmonkey:
Ahh, I mistook the log for the list of relevant apps identified by Magisk.

IDK if that would be an SD Maid issue or Magisk issue but a logical next testing step would still be to see if this occurs in a clean installation of SD Maid if you've not already done that.
[Android Apps and Games] IronTechmonkey:
FWIW, in LOS 14.1 with LOS SU (ROM regularly clean flashed) When SD Maid is restored from TiBu, or updated from playstore, or clean installed; I've never had issues with SD Maid SU permissions. To your point, about SD Maid perhaps being more prone to this than other apps, particularly in Magisk and SuperSU, I've occasionally seen similar pasterns of behaviour with some other apps - happy with LOS SU but some hiccups with SuperSU and or Magisk.

I'd follow your advise about this before anyone else's but I'm curious why in your list a clean install of SD Maid is after a data wipe for the SU app. I, perhaps mistakenly, perceive the data wipe for the SU manager to have potential impact on a wider range of device function (SU settings for other apps) than removing/reinstalling SD maid around a reboot. Is this just different priorities or am I missing something?
[Android Apps and Games] radz_:
Delete..double post
[Android Apps and Games] Dark3n:
Subjectively I find it easier to to press yes/no on a few su popup dialogs than to reconfigure SD Maid without backup (which underlines that at some point I really should add a settings export/import feature... :| ).

Objectively the issue is with the super user management app, not SD Maid.

If we would look at SD Maids debug log we would see SD Maid opening a shell with "su" and then probably getting either an exitcode of 1 (error) or 255 (out of range) or possibly a "permission denied" (though rather rare).

While removing SD Maid might trigger the su app to cleanup/fix itself, it could also fail because of the same underlying issue.

On a side note, I've had a few users with similar issues where the cause was "su" being accidentally hidden from SD Maid. Though I don't know if it's exactly this issue as no one shared the little detail of whether the su app log showed something, I'll have to ask that the next time this comes up...

What does SD Maid say in overview about root? [MENTION=5140419]radz_[/MENTION]
[Android Apps and Games] radz_:
Fixed!!!

I just reflash Magisk.zip via Magisk app.

Initially, I flash Magisk.zip in TWRP.

Thanks man..
[Android Apps and Games] Dark3n:
Where you flashed it from was not the cause of the issue.

The data wipe is likely what fixed it (even if you would have flashed it via TWRP again).

In any case, happy to hear it's working again.

Hm maybe next time someone reproduces this we could backup magisks data and open a bug ticket with magisk to further look into this.
[Android Apps and Games] Oswald Boelcke:
I'm using Magisk v16.0 (not any beta) and it's working great - also with SD Maid.

You mentioned this:

If you now flashed Magisk via the Magisk-app, I assume you're now also going with the official Magisk. Maybe the unofficial one was the culprit?
[Android Apps and Games] radz_:
Hi mate, I'm still using the unofficial one.. it works great, it could be a glitch in Magisk database.

The unofficial version of Magisk is a fixed version for 16.4, the commits is from topjohnwu.
[Android Apps and Games] kantjer:
I'm also using the unofficial Magik version ?

Never had any issues with SD getting root.
[Android Apps and Games] spawnlives:
If it helps I am using official 16.4 (beta) magisk.

No issues with SD Maid or any other apps using root access.
[Android Apps and Games] chrisjcks:
Hey Dark3n,

Can the pro version convert user apps to system apps & vice versa?

I can't seem to find it in App Control, it would be strange if it couldn't as it already does Freeze, kill, Uninstall system apps etc. (it does all these perfectly btw)

(yes I'm rooted)
[Android Apps and Games] Oswald Boelcke:
No, it doesn't; and I assume I'll be corrected quickly if I'm wrong.

Titanium Backup provides such a functionality (however, by own experiences it doesn't always work), and the Magisk repo also contains a few modules (I know about at least two) that are supposed to provide this conversion capability.