[XAP][SOURCE] Storage Cleaner 0.2.1 - Windows Phone 8 Development and Hacking

Hi folks!
So, inspired by the discoveries on this thread, I set about creating an app to easily discover and delete space-wasting files. This app is now in Alpha stage, and will be advanced to Beta as soon as it is feature-complete.
Requirements: capability-unlock (interop-unlock plus EnableAllSideloading). In the case of files that can't be deleted normally, the app will attempt to use the Samsung-specific RPC Component to move them to the SD card (and delete them from there). The app will still run on non-Samsung phones, or those without SD cards (although you'll get a warning at launch in either case) provided they meet the other requirements, but some folders won't be cleanable.
Current state: Alpha 0.2.1
History:
Alpha 0.2.1: Files will now be checked for the Read-Only flag, and it will be removed if possible, both before attempting an in-place deletion and after moving to SD. In case of an error, the exception type will now be given in the report. Files with a "Modified" date in the future will now be included by default as well.
Alpha 0.2.0: Added Move-to-SD-and-then-delete as a work-around to permissions issues. Added warnings if Samsung RPCComponent or SD card are not present. Truncated overly-long messageboxes to avoid the app hanging for a few minutes due to an accidental tap. Re-compiled as release build for performance.
Initial release (20 Feb 2014)
Source code is available at https://wp8storagecleanup.codeplex.com/
Please post feedback here!

Known issues:
Many locations that we nominally have access to don't actually grant *delete* access, only read and write/create (yes, NT tracks permissions for Delete separately from Write). Thus, a lot of files that you'd like to delete might not actually go away. (Sadly, this includes the EdmCache\Lib folder mentioned in the thread linked above). I'm working on it!
Should be fixed as of 0.2.0, if you have a Samsung phone and an SD card!
Many locations set the Read-Only flag on their files, making them un-deletable even with move-to-SD.
Should be fixed as of 0.2.1, which removes RO flags either in-place or acter move-to-SD
The app startup is pretty slow. Well, it's actually fairly fast, but it seems slow because the entire structures of all relevant directories are traversed before the UI is shown. I will move that to a background/async thread "soon".
Viewing the files for some locations (like the TIF folders, which often have hundreds or thousands of files) will cause the app to hang for a long time while it tries to format kilobytes of text into a MessageBox.
As of 0.2.0 this problem should no longer occur, as the messages will be truncated before being displayed in the MessageBox.
There's no way to change the list of locations. Well, not short of re-compiling the app, at least. I'll move them to external storage soon.
Features I want to implement:
Filtering (especially for specific folders) to files older than a certain date. This is actually already supported by the app; there's just no UI for it.
Adding additional locations for cleaning out files from, and removing locations too. Ideally, these would persist across runs of the app.
One button to select (or clear) all locations.
Option to hide locations which have no files of interest (just to make the list smaller).
Ability to edit a given location's filters (filtering on filename patterns is already implemented, but again, there's no UI for it). This should persist too.
At some point, the ability to select (or de-select) specific files or folders for deletion, in case the filtering isn't fine-grained enough. This is pretty easy to add; I just hate writing XAML.
While I'm at it, the ability to delete directories might be good. Currently this tool only deletes files.
More detailed errors when deleting a file fails. It's *usually* ERROR_ACCESS_DENIED, but it could be something else (like the file being in use by another program).
An option to move files to the SD card instead of deleting them. This would save space while providing the ability to implement an un-delete. True un-delete would require some kind of log or structure to the moved files.
Speaking of logs, I really should have the app generate one. Again, the basic stuff is already there; in fact, it generates *too much* text, so much so that I had to make it truncate MessageBox contents at about a KB.
Option to report file sizes in units based on powers of 1000 or powers of 1024 (currently it uses powers of 1000).
Internationalization would be good.
Possibly, at some point in the future, the ability to check (and clean out) the storage of other apps. You can clean them by just removing (and re-installing) them, of course, but sometimes that's a pain, and a more specific filter may be good.
Possibly an in-app update notification when new versions come out...

Reserved for OP.

Good work waiting for further versions
Sent from my GT-I8750 using Tapatalk

Hack:
Move "undeletable" files to directory, where you can delete them with RPC and delete.

the RPCComponent doesn't actually change the file ACLs, and may even turn inherited ACLs into file-specific ones when used; I previously tried copying files from unreadable locations to System32, and was still unable to read them even though I could now see them and see their file size. Very irritating.
My work-around for that is to move them to the SD card, which (being a FAT file system) has no ACLs at all. They can then be deleted from there. This works great... if you have an SD card. While I imagine most Ativ S users have installed such a card (it's one of the best features of the Ativ S, the only first-gen WP8 device to both have good specs *and* a microSD card) and they're pretty cheap if not (only needs to be big enough to briefly store the file being moved; 4GB would be more than enough), it's annoying to introduce dependencies like that. Still you've gotta do what you've gotta do...

GoodDayToDie said:
the RPCComponent doesn't actually change the file ACLs, and may even turn inherited ACLs into file-specific ones when used; I previously tried copying files from unreadable locations to System32, and was still unable to read them even though I could now see them and see their file size. Very irritating.
My work-around for that is to move them to the SD card, which (being a FAT file system) has no ACLs at all. They can then be deleted from there. This works great... if you have an SD card. While I imagine most Ativ S users have installed such a card (it's one of the best features of the Ativ S, the only first-gen WP8 device to both have good specs *and* a microSD card) and they're pretty cheap if not (only needs to be big enough to briefly store the file being moved; 4GB would be more than enough), it's annoying to introduce dependencies like that. Still you've gotta do what you've gotta do...
Click to expand...
Click to collapse
Just make it an option

OK, I implemented the Move-to-SD-and-then-delete hack. It's considerably slower that in-place deletion but it works. I also built the app for Release (rather than debug) which improves initial performance somewhat, and truncated long messages so you don't have to watch the phone struggle to display a messagebox with 200KB of text.

installed on my lumia 520 with developer unlocked...Not able to open.
Deployed successfully....but no app icon in Application list....
How to launch it?
tell me?

You need capabilities-unlock, it is not possible yet on Lumias. Only on Ativs
Sent from my GT-I8750 using Tapatalk

Got an error deleting my Internet Explorer Temp Files
edit: same with all other files

trytogetme said:
Got an error deleting my Internet Explorer Temp Files
edit: same with all other files
Click to expand...
Click to collapse
maybe they were currently in use?

-W_O_L_F- said:
Hack:
Move "undeletable" files to directory, where you can delete them with RPC and delete.
Click to expand...
Click to collapse
That´s the best solution atm. For example I move files from the appdata folders with the RPC to the local storage of my app and delete them there using a background worker.

Amirphp said:
installed on my lumia 520 with developer unlocked...Not able to open.
Deployed successfully....but no app icon in Application list....
How to launch it?
tell me?
Click to expand...
Click to collapse
If you actually managed to even get it installed, I'm impressed! It should have reported an error. This app uses both ID_CAP_INTEROPSERVICES and some capabilities that installable apps aren't supposed to have at all. There should have been at least two different errors if you tried to install it on a Lumia...

@trytogetme: Are you using the newer version, and do you have an SD card in the phone (with at least a bit of space; it doesn't need much)?
If so, I'll try to dig deeper into what the problem could be. @error0x0000034 has a good point, though; you may want to try running the app immediately after rebooting the phone.

I have same problem, with little files too
Sent from my GT-I8750 using Tapatalk

GoodDayToDie said:
@trytogetme: Are you using the newer version, and do you have an SD card in the phone (with at least a bit of space; it doesn't need much)?
If so, I'll try to dig deeper into what the problem could be. @error0x0000034 has a good point, though; you may want to try running the app immediately after rebooting the phone.
Click to expand...
Click to collapse
Restarting the phone doesnt help for me.
Still the error. The app doesnt care what folder I want to clear. Got that error every time

Hmm. I'll see if there's something I can do about that. One thing I found is that some files are marked Read-Only. Unlike proper ACLs, that flag persists after the move to microSD. It's easy to remove, though. I'll add code to check for, and remove, that flag.
Can you connect your phone to USB and check the SD card? If there's a folder called "StorageCleanerTemp" on the root of the SD card, that means there were files moved by the PRCComponent but which the app subsequently failed to delete. The most likely reason is that they were flagged as Read Only. (it's worth noting that this would have removed them from the phone's internal storage anyhow...)
I just deleted my Temporary Internet Files using v0.2.0, exactly the same as you can get here. It took something like 10 minutes - I really need to optimize that - but it worked, deleting some 2600 files totaling over 200MB.

GoodDayToDie said:
If you actually managed to even get it installed, I'm impressed! It should have reported an error. This app uses both ID_CAP_INTEROPSERVICES and some capabilities that installable apps aren't supposed to have at all. There should have been at least two different errors if you tried to install it on a Lumia...
Click to expand...
Click to collapse
i used xap Deployer 2.0
And installed without any error...
But No app icon...as i told earlier.
But when i tried to deploy via windows Power Tools...then i got error...
But no error with Xap deployer 2.0.

Are there any other folders or files that could be deleted to regain space from system files?
My system is at 9.59GB, but even the StorageCleanup says I can free up to 215.3MB only, with the Store app package cache holding only 1-2 .zmz files (with about 30MB, the most is in Temporary Internet files, at about 170MB)...
Each time I delete some apps I installed previously (just about 4GB of apps right now), pretty soon that free space gets "eaten up" by the system leaving me with just MB/KBs free?! It's unreal how Microsoft hasn't at least addressed this as a bug yet, maybe it's going to be fixed in 8.1, hopefully developer preview's coming soon...
@GoodDayToDie - I wanted to rebuild the xap myself and see if I could help out myself somehow, but I'm having a problem with deploying the app from VS2013 with the standalone WP8SDK installed, in particular with these capabilities:
<Capability Name="ID_CAP_CHAMBER_PROFILE_DATA_RW" />
<Capability Name="ID_CAP_COMMS_SERVICES" />
<Capability Name="ID_CAP_COMMS_APPLICATIONS" />
<Capability Name="ID_CAP_COMMS_COMMON" />
<Capability Name="ID_CAP_DU_SHARED_DATA" />
<Capability Name="ID_CAP_DUASVC" />
<Capability Name="ID_CAP_EDM_CACHE_WRITE" />
<Capability Name="ID_CAP_ENTERPRISE_SERVICE" />
<Capability Name="ID_CAP_PHONE_INTERNAL" />
<Capability Name="ID_CAP_PUBLIC_FOLDER_FULL" />
<Capability Name="ID_CAP_ZMFSERVICES" />
failing build with these 1 error + 10 warnings:
The 'Name' attribute is invalid - The value 'ID_CAP_CHAMBER_PROFILE_DATA_RW' is invalid according to its datatype 'String' - The Enumeration constraint failed, etc...
How do you get around it please? And is your CRPComponent free to use/distribute? I'd like to use some of its method calls (which I will share afterwards - hope you don't mind that I got it from the xap file - the dll&winmd files)...

Related

DIAMIMG - New app suggestion

A suggestion for a trivial app for programmers but one that would be useful none the less.
A simple GUI that would list all the NBH files in ones internal storage root. It would the allow user to select one NBH file and queue it for flashing. Rather than renaming the desired rom it would copy it to a new file diamimg.nbh. That way the users set of ROMs would stay properly identified and intact. This would mean a 1 rom overhead but with 4gb storage this should be OK.
loggersDudRom.nbh
someotherROM.nbh
HTCStock.nbh
diamimg.ndh <-- On of the above 3
Ideally this utility could be a standalone exe like PPCBackup to user could keep it in their internal storage root so it survived flashing to ROMs it was not bundled in.
It could possibly include various option such as:
-A button that would "Triggered bootloader mode" if programmaticaly possible but no big deal.
- Place a known good rom such as HTCStock.nbh in the diamimg.ndh position as a safe reversion for when ROM in use becomes unresponsive.
- delete diamimg.nbh
- Hard Reset button to use post flash.
Could be called "Rom Junky" or just DIAMIMG.
Anyway I realise it only is fairly trivial and replaces renaming files in a folder but thought I would suggest it and see if it appeals to anyone else?
PS: I am not a programmer, so if anyone is interested, fill your boots and have a crack at it.

[TIP/TRICK] Stop Stock Gallery From Creating .thumbnails Folder! Save SD Card Space!

[TIP/TRICK] Stop Stock Gallery From Creating .thumbnails Folder! Save SD Card Space!
First off, I'll start by saying: "I am not responsible if you brick your phone! Always make a nandroid backup before using my steps/messing with Autostarts! (It's a very powerful application!)"
If you use a 3rd party gallery app (Like QuickPic, my personal favorite...) - You are probably tired of wasting over 100mb of space on your SD card... (And waiting a long time for booting up as well...) I had no need for the /sdcard/DCIM/.thumbnails folder taking up space on my SD card, so this is how to disable the stock Gallery app from doing so!
I researched a little on how to accomplish this and came up with little information, so I thought I'd share:
What you'll need:
1.) Autostarts app (I used: Version 1.7.0)
---
Steps/Directions:
1.) Run Autostarts
2.) Look for these entries: Media ejecting/mounted
3.) Choose either entry (ONLY CHOOSE ONE, IT DOES NOT MATTER WHICH! Choosing one entry will disable both entries in Media ejecting AND Media mounted!)
4.) Click on BootReceiver
5.) Choose Disable (A popup will show saying "This is a system app, are you sure? etc.)
6.) Done! Reboot. On boot, go to /sdcard/DCIM/ and look inside for the usual .thumbnails folder, it should be contained with a few (SMALL) files now!
Note: (Make sure you disable the entry BootReceiver ONCE, it should "strikeout" (as in: draw a line through) the entry BootReceiver, to show it has been disabled on boot.) - zmag
Hmm, seems I just looked in my folder and I saw the darn .thumbnails file again... If anyone knows how to disable the stock Gallery app from wasting boot time & sd space; PLEASE TELL ME!!! - zmag
Well, it looks like this is not a big issue for anyone out there - but it still annoys me.
I have since "frozen" the stock Camera and Gallery apps with Titanium Backup Pro, and still; no luck.
Now, granted when I reboot my phone and look in my DCIM folder it doesn't seem to be creating the .thumbnails folder 100% of the time. But the folder is still being created somehow, and my only guess is from a third-party app (and I can't seem to pinpoint which one) but I'm gonna test to find out which and post my results...
I wish someone out there could give me some input, I've been talking to myself here for too long. - zmag
This isn't the same, but you can create a filetype named '.nomedia' and place it at the root of the folder where you want and it will stop displaying the thumbnails in the gallery app.
http://smartadopter.wordpress.com/2...mbnails-showing-in-the-android-photo-gallery/
OK I believe I may have found the possible solution to this problem.
I was searching around on how to fix this problem as well, and tried a few things myself and believe I have found a solution, so I had to sign up for xda to share with everyone else. So please be gentle as this is my first post, although im a long time lurker.
I also got rid of the stock gallery (uninstalled with Titanium Backup) and now use Quick Pic. although I have removed the stock gallery it still builds that 60mb+ thumbnails directory on my SDcard. I was using SD Maid to delete it but it gets annoying that it kept reappearing even after the uninstall of stock gallery.
Now to start fixing,
I realized it was actually a large single file itself named ".thumbdata3-1967290299" in "sdcard/DCIM/.thumbnails/" that was taking up the 60mb+ , the smaller individual thumbnails Quick Pic created only added up to a 1mb or so.
So what I did was I just grabbed a random useless file from my SD card I didn't need anymore (an alarm clock plus backup .bak file, but I would assume the *new file" option in root explorer would do the same) and I renamed the unneeded file the same name as the file in /.thumbdata/ (the the .thumbdata3-19672902099).
Now I had a .thumbdata file that was only 1.75kb and just simply moved it to the sdcard/DCIM/.thumbnails/ folder and replaced the 60mb .thumbdata file with the smaller one.
After a few restarts of my phone, opening and browsing Quick Pic, checking my thumbnail size a few times with both SD Maid and Root Explore - I now have a much smaller 1.75kb file instead of the old 60mb file.
Hopefully this well help some of you out and solve your problem as well, as far as I can tell it is no longer making that thumbnail file expand so large on my phone.
Phone: HTC Hero CDMA
ROM: Cyanogenmod 7.1
Carrier: i-wireless/sprint
hewillmakehell said:
OK I believe I may have found the possible solution to this problem.
Click to expand...
Click to collapse
i've tried both your copied file trick and making a new file with root explorer, both to no avail. ".thumbdata3--1967290299" always reverts to its old size if any app associated with the gallery is opened.
has yours really stopped reappearing?
i can't figure out where the large thumbnail data is stored, but it must be in the system somewhere...
problem solved
hey i figured out how to fixed this on my atrix. should be the same for all android phones.
http://forum.xda-developers.com/showthread.php?p=28447099#post28447099
There's no "external.db" inside my "com.android.providers.media" folder.
However, I didn't even understood what I was supposed to do with this file. What he meant with "trim the thumbnails table with an sql editor"?
I quoted the post you linked below:
i found the place where the thumbnail data is stored, which was making the huge thumbnail file and crashing Entertainment Center.
it isn't storing the entire ".thumbdata3--1967290299" file (which can be hundreds of mb for some people), rather a large (tens of mb) .db database file that is being used to recreate it on demand.
/data/data/com.android.providers.media/databases
external.db
with Root Explorer i could view the file, and Speed Software also sells an sql editor which you can use to trim the thumbnails table.
*be careful: deleting entries from this file also seems to delete it from the device! i deleted all records from the thumbnails and images tables..
learn from my mistake. i thought it would regenerate, but it deleted all images from /sd card. good thing i backed up all my photos first, but better to use the filter option and trim out only the records for files that are no longer on the device.
".thumbdata3--1967290299" now reappears, but a whole lot smaller.
Gallery opens so much faster now, and Entertainment Center works again!
hope it helps!
Click to expand...
Click to collapse
i bet it is hiding somewhere. maybe it's slightly different on other phones.
the issue was that i had an ever-expanding sdcard/dcim/.thumbnails/.thumbdata3--1967290299 file being recreated every time i accessed the gallery viewer, even after that thumbnails folder was erased.
my device was keeping track of ALL the media files that were ever on it, not just the ones presently on it. so the more files that passed through my device, the bigger the thumbdata file kept getting. the external.db file contains a table that lists all media files along with a bunch of attributes for each. apparently this db file is used to generate the thumbdata file. all the info for deleted files just leads to more padding inside the thumbdata file, so it keeps getting bigger.
by trimming the table i meant to delete the records in the external.db that correspond to thumbnails for media no longer on the device. that file is an SQLite file, so to open it you need a special viewer/editor. i first used the SQLite Viewer that comes with Root Explorer. with that, i could see the all the redundant thumbnail entries. to edit it, i got the SQLite Editor, though i'm sure there are other ways. then it's a matter of recognizing which files it lists that are no longer on your device, and getting rid of those rows from the table. in my case the external.db file went down from 8mb to 500kb after i did that.
screenshot 1 showing tables inside external.db, using SQLite Editor
screenshot 2 showing 'thumbnails' table
TBN FILE 2gb
hi
i have a huge thumbnail file in he sd card its almots 2GB
i have already came to opeing the list for thumbnails in the editor
but i dont know how to filter it that i can delete only the files which are not in the sd card (i.e already deleted ) plss guide me throught ,,, this and u will be a star:good:
whitebreadstyle said:
i bet it is hiding somewhere. maybe it's slightly different on other phones.
the issue was that i had an ever-expanding sdcard/dcim/.thumbnails/.thumbdata3--1967290299 file being recreated every time i accessed the gallery viewer, even after that thumbnails folder was erased.
my device was keeping track of ALL the media files that were ever on it, not just the ones presently on it. so the more files that passed through my device, the bigger the thumbdata file kept getting. the external.db file contains a table that lists all media files along with a bunch of attributes for each. apparently this db file is used to generate the thumbdata file. all the info for deleted files just leads to more padding inside the thumbdata file, so it keeps getting bigger.
by trimming the table i meant to delete the records in the external.db that correspond to thumbnails for media no longer on the device. that file is an SQLite file, so to open it you need a special viewer/editor. i first used the SQLite Viewer that comes with Root Explorer. with that, i could see the all the redundant thumbnail entries. to edit it, i got the SQLite Editor, though i'm sure there are other ways. then it's a matter of recognizing which files it lists that are no longer on your device, and getting rid of those rows from the table. in my case the external.db file went down from 8mb to 500kb after i did that.
screenshot 1 showing tables inside external.db, using SQLite Editor
screenshot 2 showing 'thumbnails' table
Click to expand...
Click to collapse
I had the sam issue, but unfortunately your solution didn't help me. I have only a couple of pictures on my phone, but a lot of GBs of music on SDCard and I think this is he reason why .thumbdata3 file is so large on my phone.
I also tried using SDRescan as proposed here: http://forum.xda-developers.com/showpost.php?p=28516079&postcount=6, but that didn't help either.
I've done some more research and found a solution here: http://www.mobilephonetalk.com/show...in-memory-card&p=311954&viewfull=1#post311954. After I deleted the .thumbdata3 file, created a blank one with Root Explorer and removed write permission to it, the file stays at 0 bytes and Camera and Gallery apps still work fine.
mihir880 said:
hi
i have a huge thumbnail file in he sd card its almots 2GB
i have already came to opeing the list for thumbnails in the editor
but i dont know how to filter it that i can delete only the files which are not in the sd card (i.e already deleted ) plss guide me throught ,,, this and u will be a star:good:
Click to expand...
Click to collapse
it sure would be nice if android did that automatically
i don't know how though, sorry.. maybe there is a way, but it is surely safer to backup the media files to another drive, trim the db, then move them back if necessary.
---------- Post added at 09:47 PM ---------- Previous post was at 09:42 PM ----------
strom87 said:
I've done some more research and found a solution here: http://www.mobilephonetalk.com/show...in-memory-card&p=311954&viewfull=1#post311954. After I deleted the .thumbdata3 file, created a blank one with Root Explorer and removed write permission to it, the file stays at 0 bytes and Camera and Gallery apps still work fine.
Click to expand...
Click to collapse
i guess that's one way of doing it. it just means all the thumbnails have to be recreated every time you open the gallery or file browser.
strom87 said:
I had the sam issue, but unfortunately your solution didn't help me. I have only a couple of pictures on my phone, but a lot of GBs of music on SDCard and I think this is he reason why .thumbdata3 file is so large on my phone.
I also tried using SDRescan as proposed here: http://forum.xda-developers.com/showpost.php?p=28516079&postcount=6, but that didn't help either.
I've done some more research and found a solution here: http://www.mobilephonetalk.com/show...in-memory-card&p=311954&viewfull=1#post311954. After I deleted the .thumbdata3 file, created a blank one with Root Explorer and removed write permission to it, the file stays at 0 bytes and Camera and Gallery apps still work fine.
Click to expand...
Click to collapse
How did you removed write permission from the thumbdata3 file with RootExplorer. If I try this, then I get a message, that that is not possible on the SD-Card and nothing happens!! The permissions stay !!!
Sunnymen1975 said:
How did you removed write permission from the thumbdata3 file with RootExplorer. If I try this, then I get a message, that that is not possible on the SD-Card and nothing happens!! The permissions stay !!!
Click to expand...
Click to collapse
You can try creating a folder instead of a file(no need to set permissions). So far, it's working
lbrfabio said:
You can try creating a folder instead of a file(no need to set permissions). So far, it's working
Click to expand...
Click to collapse
Another quick way that seems to work:
Code:
rm -rf /mnt/sdcard/DCIM/.thumbnails && touch /mnt/sdcard/DCIM/.thumbnails
rm -rf /mnt/sdcard/external_sd/DCIM/.thumbnails && touch /mnt/sdcard/external_sd/DCIM/.thumbnails
Hello, I also have this problem. Now I put another file with that name and that seems to work.
However, I came on this because my device went suddenly very slow.
Is it possible that the application that writes these .thumbnail files is still searching through the complete device, even when it cannot update the file?
And, how can I inspect what app is causing this file or slow down?
Fixed!... deleted .thumbnails folder and then created a file called .thumbnails using root explorer....thats worked for me in my THL w1..saved 1.2 gb of space!
Is there anyway to stop the stock camera from posting pics in the DCIM folder? I am somewhat ocd and would like them to be posted in a folder of my choosing.
estranged1977 said:
Fixed!... deleted .thumbnails folder and then created a file called .thumbnails using root explorer....thats worked for me in my THL w1..saved 1.2 gb of space!
Click to expand...
Click to collapse
Created a file or a folder?
petrsiri said:
Created a file or a folder?
Click to expand...
Click to collapse
try create folder (I do this and see no more thumbdata3-files yet two months)

[Q] rooted NST - how to add images to internal wallpaper folder?

I'd like to change the wallpaper on the root u-tube home screen, but I don't see how one can access the internal folders. I'd like to be use adb push but I don't know the path for the 'Picture', or 'Wallpaper gallery Home' that are possible locations for adding the images.
You do mean the desktop wallpaper?
I'm boring. I just changed the default wallpaper to solid white.
In /system/framework/framework-res.apk
Replace /res/drawable-mdpi/default_wallpaper.png
To answer your original question: I don't know.
Thanks for the information; however being a complete beginner that does help me get a little bit closer to what I'd like to do but there is still much that I don't really understand. How do I access that location? And should I add my new image to the subfolder with a totally differently name, or should I rename the my image to that of the default.png and replace the old image?
If I adb push to the nook my image renamed to match the old wallpaper image, will that work?
still trying to replace home image in rooted Nook ST
I have a question for someone who knows more than I about android systems. Thanks to Thank Meter 78 who pointed out the file I need to change in order to replace the home image is in
/system/framework/framework-res.apk
and that I need to replace in that apk
/res/drawable-mdpi/default_wallpaper.png
Will the following procedure work properly without screwing up my newly rooted Nook?
Using Root Explorer I copied the 'framework-res.apk', and saved it to my Nook sd card. Then copied that apk file to my windows xp computer and changed the extension to 'zip' and unzipped it. The png file thus is available for replacement by another image of identical size and name.
Will it be correct for me to rename the modified .zip extenson file containing a new default_wallpaper.png file back to its original .apk extension, copy/paste it to the sd card, insert the sd card into the Nook, and the using Root Explorer to copy the apk file and paste it back to the drawable-mdpi folder where it will replace the nook apk (being sure that I change the r/o to r/w permission for the folder, and change it back after the replacement)?
Could there be adverse effects of the replacement?
My friends all call me Renate...
Yes, that procedure works, correcting for your typo.
Unzip, replace PNG, zip, copy back to /system/framework/framework-res.apk
You don't need to set it back to r/o. It's better/easier to just reboot, preferably with ADB.
You should always backup at reasonable intervals and before major changes.
Heck, I've bricked my Nook a dozen times.
Thanks Renate!
Ok, the actual answer is:
The gallery uses the mediastore images database.
The crawler can't find anything even if it's right under its nose.
The databases are stored in /data/data/com.android.providers.media/databases
There's internal.db and another db for each unique SD card inserted.
The crawler is equally lame finding MP3's also.
That's why both Music and Gallery say "no media".
Renate NST said:
Ok, the actual answer is:
The gallery uses the mediastore images database.
The crawler can't find anything even if it's right under its nose.
The databases are stored in /data/data/com.android.providers.media/databases
There's internal.db and another db for each unique SD card inserted.
The crawler is equally lame finding MP3's also.
That's why both Music and Gallery say "no media".
Click to expand...
Click to collapse
1) I thought the original question was about u-tube (I guess "Youtube" ;-))
2) ad gallery - I was always wondering how to make it see the JPGs I had as screensavers... Would you have any ideas how to fix this (i.e. make the crawler work)? Or maybe the other way round, how often is the crawler running? Would battery be improved if it was turned off/killed?
The Media Scanner service is what scans.
Normally it is activated on insertion of an SD card.
It does not run continuously.
It ignores directories with file in it called ".nomedia"
The MediaScannerConnection can be used to request scanning of a single file.
Level 8 API (we're 7) can request scanning of multiple files.
It seems to turn its nose up at files and not put them in its database.
ajislav said:
2) ad gallery - I was always wondering how to make it see the JPGs I had as screensavers... Would you have any ideas how to fix this (i.e. make the crawler work)? Or maybe the other way round, how often is the crawler running? Would battery be improved if it was turned off/killed?
Click to expand...
Click to collapse
Are you asking about having your own pics as screensavers?
I did that by connecting my NST to the PC, and creating a folder (one word name) under screensavers/ and copying the pics into that folder. It then shows up in the screensavers menu, and you can select it. The location from within the nook is /media/screensavers
--
The emulator's MediaScanner works fine, the Nook's appears broken.
You can manually enter images into the MediaStore:
(This requires sqlite3 installed or pull the database and do it on your desktop.)
Code:
sqlite3 /data/data/com.android.providers.media/databases/internal.db
insert into images (_data, mime_type) values('/media/myphoto.png', 'image/png');
.q
Call up Gallery.
You will see a blank thumbnail because one has not been generated yet.
Click on that.
Renate NST said:
The emulator's MediaScanner works fine, the Nook's appears broken.
You can manually enter images into the MediaStore:
(This requires sqlite3 installed or pull the database and do it on your desktop.)
Code:
sqlite3 /data/data/com.android.providers.media/databases/internal.db
insert into images (_data, mime_type) values('/media/myphoto.png', 'image/png');
.q
Call up Gallery.
You will see a blank thumbnail because one has not been generated yet.
Click on that.
Click to expand...
Click to collapse
Isn't their any way to repair the nooks MediaScanner? like, re-install it, clear the app data, copy another one in from another android 2.1 device? I don't understand why it isn't working, or why it can't be fixed. I've tried backing up the app and re-installing it, deleting the external db's, running media scan apps. Disabling it, re-enabling it...

what is /storage/emulated/legacy etc. and /storage/emulated/0 etc.

I am not rooted.
I have researched and every time someone talks about this topic they start refering to doing things in root. I am a Linux user specifically a Linux Mint 13 KDE. However! I don't work with the terminal and have not since my DOS days, nor do I want to. IMO I'm too old to bother with it.
Now I use ES File Explorer as my file browser and I see there seems to be a duplication of almost everything on my device yet there is not enough room on the Nexus 4 16GB to hold 2 of everything I have loaded onto it.
So I assume the extra stuff I see are sym-links (I don't realy understand what they are just that they are not real). Am I correct?
Why when an app looks for duplicates does it show the stuff in /storage/emulated/legacy etc. and in /storage/emulated/0 etc. and report them as the same size?
Why am I allowed to create a folder in /storage/emulated/0 or /storage/emulated/legacy if they just contain sym-links? IMO I should not have access to those folders without being rooted.
Why when I add a folder in /storage/emulated/0 or /storage/emulated/legacy does it show up in /sdcard?
donec said:
I use ES File Explorer as my file browser and I see there seems to be a duplication of almost everything on my device yet there is not enough room on the Nexus 4 16GB to hold 2 of everything I have loaded onto it.
So I assume the extra stuff I see are sym-links (I don't realy understand what they are just that they are not real). Am I correct?
Why when an app looks for duplicates does it show the stuff in /storage/emulated/legacy etc. and in /storage/emulated/0 etc. and report them as the same size?
Why am I allowed to create a folder in /storage/emulated/0 or /storage/emulated/legacy if they just contain sym-links? IMO I should not have access to those folders without being rooted.
Why when I add a folder in /storage/emulated/0 or /storage/emulated/legacy does it show up in /sdcard?
Click to expand...
Click to collapse
I was going to post a simpler version of this question: Why do I have [Android 4.2.2 on a Nexus 7] /storage/emulated/0/, /storage/emulated/legacy/, and /storage/sdcard0/ when they seem to have exactly the same contents? When, if I create something in /storage/emulated/0/ it's duplicated in the other two locations?
But I noticed this thread and decided to check it out. I am shocked that it'' gotten no response in five months.
Eric Weir said:
I was going to post a simpler version of this question: Why do I have [Android 4.2.2 on a Nexus 7] /storage/emulated/0/, /storage/emulated/legacy/, and /storage/sdcard0/ when they seem to have exactly the same contents? When, if I create something in /storage/emulated/0/ it's duplicated in the other two locations?
But I noticed this thread and decided to check it out. I am shocked that it'' gotten no response in five months.
Click to expand...
Click to collapse
They are basically the same thing. 2 mount points pointing to the same storage device and partition.
If you create something in one folder, it will show up in the other. Same applies for deleting stuff.
They do not take away more storage space, as it is only available once but shown twice.
You also don't need to worry about it in any way because file browsers normally set their default directory to one of these locations.
As far as i know, Google changed the mount points in Android 4.2 to /storage/emulated/0/ due to them switching to MTP and EXT4(?) for the sdcard. The other mount points are still there for compatibility.
Don't quote me on that, though.
They changed it for multi-user feature
Sent from my Nexus 4
Can I delete "legacy"
Nuu~ said:
They are basically the same thing. 2 mount points pointing to the same storage device and partition.
If you create something in one folder, it will show up in the other. Same applies for deleting stuff.
They do not take away more storage space, as it is only available once but shown twice.
You also don't need to worry about it in any way because file browsers normally set their default directory to one of these locations.
As far as i know, Google changed the mount points in Android 4.2 to /storage/emulated/0/ due to them switching to MTP and EXT4(?) for the sdcard. The other mount points are still there for compatibility.
Don't quote me on that, though.
Click to expand...
Click to collapse
Can I delete the legacy folder without harming anything?
DEFI4NT said:
Can I delete the legacy folder without harming anything?
Click to expand...
Click to collapse
Did you read the post that you quoted ?
"If you create something in one folder, it will show up in the other. Same applies for deleting stuff."
DEFI4NT said:
Can I delete the legacy folder without harming anything?
Click to expand...
Click to collapse
Why would you even want to delete it in the first place? You wouldn't be gaining anything is just another mount point.
Sent from my Nexus 4 using Tapatalk
....
/storage, /sdcard are sym linked folders,that means when you open one of those, it redirects to the original(/data/media/0), as for the 0 is just a multi user feature implemented in android 4.2, but only enabled on tablet androids.
Why do this Sym-Link?: simple so it dosent break apps(not only file explorer type of app, but all apps).
Still dont get, why it would break?.Simple. android api have lots of ways to write/read files from folders, u can do manually,u can get the data path, u can get the sdcard path, etc,etc. so to not break that they just does these sym links, thats why in one app the storage contentents are listed on /sdcard but on others, is /storage, etc,etc. one example of an app that broke because of these changes to android is titanium backup, u need to change the internal storage on it, so it work.
Are they really symlinks?
I want to make sure that they are sym linked files/ folders and not additional copies as it will directly impact the storage.
Emulated storage is the only reason i have not upgraded yet to Android 4.4 yet, despite ROMs being available ages ago..
1. Please let me know for confirmation, if there is no impact on storage space.
2. Can Link2SD be used in 4.4 with emulated storage?
3. If there is a file and its sym link/ copy; are the rights equally assigned to both files/ folders?
I mean to ask if there is a provision to have root previlege on the original file and read only rights on the sym link ? Is it possible??
the main reason for this question is that, if by mistake i do something on the sym lilnk, it should not affect the original file.
and whatever change i wish to operate on, i can do it on the original file itself.
Regards
Dwipen
opssemnik said:
/storage, /sdcard are sym linked folders,that means when you open one of those, it redirects to the original(/data/media/0), as for the 0 is just a multi user feature implemented in android 4.2, but only enabled on tablet androids.
Why do this Sym-Link?: simple so it dosent break apps(not only file explorer type of app, but all apps).
Still dont get, why it would break?.Simple. android api have lots of ways to write/read files from folders, u can do manually,u can get the data path, u can get the sdcard path, etc,etc. so to not break that they just does these sym links, thats why in one app the storage contentents are listed on /sdcard but on others, is /storage, etc,etc. one example of an app that broke because of these changes to android is titanium backup, u need to change the internal storage on it, so it work.
Click to expand...
Click to collapse
dwipen said:
I want to make sure that they are sym linked files/ folders and not additional copies as it will directly impact the storage.
Emulated storage is the only reason i have not upgraded yet to Android 4.4 yet, despite ROMs being available ages ago..
1. Please let me know for confirmation, if there is no impact on storage space.
2. Can Link2SD be used in 4.4 with emulated storage?
3. If there is a file and its sym link/ copy; are the rights equally assigned to both files/ folders?
I mean to ask if there is a provision to have root previlege on the original file and read only rights on the sym link ? Is it possible??
the main reason for this question is that, if by mistake i do something on the sym lilnk, it should not affect the original file.
and whatever change i wish to operate on, i can do it on the original file itself.
Regards
Dwipen
Click to expand...
Click to collapse
1- impact? no they are like .ink files in windows
2- yes link2sd works
3- the permissions are the same
maybe someone here can explain whats going on
So my phone seems to have two systems (or probably more) running and it IS using up my memory. See attached photos. I own a 32gb Optimus G pro. Rooted and custom recovery. Beeen trying out a few ROMs. Well somehow I noticed that there is some kind of ghost app/system using up my memory. I only use 7.36 of my sd card (internal). Yet I only have 6gb of memory left. And I just noticed my calendar has double the entries.
Is there a fix??? Or do I have to reflash stock kitkat???
What happened? The only irregular thing that happened is when I was restoring a nandroid backup I fell asleep and woke up 3 hours later and noticed that somehow the phone was making another backup. Could that be the cause. Restoring doesn't fix this. What can I do?
I can't rfactory reset since I have a custom recovery. Doing it in the custom recovery has no effect.
Oh and I did flash freegee's cwm over hoangnova's cwm. Someone told me to update cwm through freegee because I couldn't flash any custom roms.
I have similar problem.
liovag said:
Hello,
I have order Meizu m1 note 32 gb version blue color from fastcardtech.com and i have received a couple of days ago. Today i notice that in storage menu, the file system holds 17.13GB
The phone is unrooted.
How is this possible, I am very disappointed, and frustrated.
This is a big thing. I have pay for 32GB version and i suspect that they fraud me.
Also i have connect the phone via usb to my pc and i saw that the total size is only 11,9GB and not 32.
Also i have install to the phone the ES File Explorer to check the storage capacity and i saw that the phone have 11.94 GB Total capacity and not 32 i suspect that you have change something to the phone software. to look 32gb but actually is only 16GB version. This is fraud.
I have make factory reset with erasing data and upgrade the system but remains the same. :/
Please give me your advice.
View attachment 3407558
View attachment 3407559
View attachment 3407560
Click to expand...
Click to collapse
Imagine a HOUSE. The house = the storage location. Everything in it is your data... furniture etc. These are your files.
storage location \legacy = the back door.
storage location \0 = the front door.
If you delete a file = take your chair and throw it in the yard. Its gone from the house no matter if you entered the front door or back door.
yes, it consumes double storage!
I also have the same observation. Whatever the explaination from previous replies, it consumes my storage double! And it hurts if you only have 8 GB internal storage in my Moto G.
X-plore app can show the storage mapping in my root folder.
What we need now is a solution how to avoid this double storage consumption.
So, we have two identical houses, instead of one house with two doors!
Why2 said:
I also have the same observation. Whatever the explaination from previous replies, it consumes my storage double! And it hurts if you only have 8 GB internal storage in my Moto G.
X-plore app can show the storage mapping in my root folder.
What we need now is a solution how to avoid this double storage consumption.
So, we have two identical houses, instead of one house with two doors!
Click to expand...
Click to collapse
I completely understood the analogy about the house and furniture but it does not answer the above question.
Why does it reflect as double the amount of storage being used if it is technically one spot. Its not like its one spot with different files, its one spot with duplicate paths of ONE file that are somehow reflecting as double files, using double the amount of space.
Sorry I'm trying my best to explain and work logic into this lol
II've been trying to change the destination file for utorrent on my android from storage/emulated/legacy to storage/external_SD, for some reason when I do this utorrent says "file not found", and will only download to storage/emulated/legacy, can anyone help with this? It would be greatly appreciated

Unknown folder in the root of internal memory?!

Hey guys.
I'm a bit intrigued. There's an unknown folder in the root of my phone's internal memory. I delete it every few weeks when I check the storage and sweep all the junk I might find in there.
Here's the folder structure.
GT-I9505\Internal storage\.sp\.94\.743\.cache\LazyList.
Inside that last folder (LazyList), there's a 23 KB file named 663014360. It has no extension. Opening it with Notepad / WordPad reveals a lot of unreadable characters (of course...).
I am having a hard time tracing it back to any app (if it's an app that's creating it, or the ROM itsellf ).
Does anyone here know what this .sp sh*t is all about...?
For what it's worth, I am running the latest SlimKat ROM.
Formhault said:
Hey guys.
I'm a bit intrigued. There's an unknown folder in the root of my phone's internal memory. I delete it every few weeks when I check the storage and sweep all the junk I might find in there.
Here's the folder structure.
GT-I9505\Internal storage\.sp\.94\.743\.cache\LazyList.
Inside that last folder (LazyList), there's a 23 KB file named 663014360. It has no extension. Opening it with Notepad / WordPad reveals a lot of unreadable characters (of course...).
I am having a hard time tracing it back to any app (if it's an app that's creating it, or the ROM itsellf ).
Does anyone here know what this .sp sh*t is all about...?
For what it's worth, I am running the latest SlimKat ROM.
Click to expand...
Click to collapse
try this app - https://play.google.com/store/apps/details?id=com.kokanes.fileextensiondirectory
Sent from my GT-I9500
Formhault said:
Hey guys.
I'm a bit intrigued. There's an unknown folder in the root of my phone's internal memory. I delete it every few weeks when I check the storage and sweep all the junk I might find in there.
Here's the folder structure.
GT-I9505\Internal storage\.sp\.94\.743\.cache\LazyList.
Inside that last folder (LazyList), there's a 23 KB file named 663014360. It has no extension. Opening it with Notepad / WordPad reveals a lot of unreadable characters (of course...).
I am having a hard time tracing it back to any app (if it's an app that's creating it, or the ROM itsellf ).
Does anyone here know what this .sp sh*t is all about...?
For what it's worth, I am running the latest SlimKat ROM.
Click to expand...
Click to collapse
It is very good that although you are deleting the launcher's (or some other app) cache, it restores it.
I can understand that you're mad about it and you would like that your launcher (or app) shall not create any cache and consequently would work slower.
As well I appreciate your huge work with tracing it (5th link in google search provides the answer what is it).
If you really care what is, your work would be pretty simple. Factory reset your phone, start each built in ROM app and check the folder after. Then, install your apps one by one, starting each of it and each time after closure checking the folder. Easy.
anu.cool said:
try this app - https://play.google.com/store/apps/details?id=com.kokanes.fileextensiondirectory
Click to expand...
Click to collapse
Sorry, but that app is of no use to me since the file in question has no extension.
spamtrash said:
It is very good that although you are deleting the launcher's (or some other app) cache, it restores it.
I can understand that you're mad about it and you would like that your launcher (or app) shall not create any cache and consequently would work slower.
As well I appreciate your huge work with tracing it (5th link in google search provides the answer what is it).
If you really care what is, your work would be pretty simple. Factory reset your phone, start each built in ROM app and check the folder after. Then, install your apps one by one, starting each of it and each time after closure checking the folder. Easy.
Click to expand...
Click to collapse
What exactly did you use as a search term on Google?
I know most apps create folders that are legible (com.android.thisgameproducer). Buth with this given specific folder's structure, I don't know what it could be.
For what it's worth, I have been trying to find an answer to this for some months. But only now I made a topic about it. I did my research, which turned out nothing... :/
Formhault said:
. I did my research, which turned out nothing... :/
Click to expand...
Click to collapse
Have you:
wiped your phone, and then used titanium backup for freezing each app, restoring it, and verifying which one creates it? did you repeated the same for each installed by you app? Well, if this folder/file is NOT created by one application (or installed, or embedded into the ROM), then only one explanation is that your phone is used by E.T at night while he "phone home" and this is his encrypted message.:cyclops:
about extension/filetype:does the file have header?
spamtrash said:
Have you:
wiped your phone, and then used titanium backup for freezing each app, restoring it, and verifying which one creates it? did you repeated the same for each installed by you app? Well, if this folder/file is NOT created by one application (or installed, or embedded into the ROM), then only one explanation is that your phone is used by E.T at night while he "phone home" and this is his encrypted message.:cyclops:
about extension/filetype:does the file have header?
Click to expand...
Click to collapse
You know where that .sp folder comes from? Perhaps you were able to find something on Google that I didn't all this time...
I don't know what that header is / should be...
I know I could wipe all and start over again and check each app... But that's too time consuming... Hence I am asking here.
Formhault said:
You know where that .sp folder comes from? Perhaps you were able to find something on Google that I didn't all this time...
I don't know what that header is / should be...
I know I could wipe all and start over again and check each app... But that's too time consuming... Hence I am asking here.
Click to expand...
Click to collapse
1. No idea which particular app makes the cache file, but it is clear that it is cach for one app you have installed, or one you have embedded in ROM.
2. Header is the two first bytes of file in the notepad viewer: for example, PK is characteristic for zip files and by changing the extension you could see what's inside.
3. No one who does not have your ROM AND your specific set of apps installed would be able to provide the answer, therefore without doing your homework, it is unlikely that you'd have information you want.
spamtrash said:
1. No idea which particular app makes the cache file, but it is clear that it is cach for one app you have installed, or one you have embedded in ROM.
2. Header is the two first bytes of file in the notepad viewer: for example, PK is characteristic for zip files and by changing the extension you could see what's inside.
3. No one who does not have your ROM AND your specific set of apps installed would be able to provide the answer, therefore without doing your homework, it is unlikely that you'd have information you want.
Click to expand...
Click to collapse
Well, I don't really know what homework I should do here, as the folder structure is weird (come on, just numbers? ) and the file has no obvious meaning whatsoever. I'm usually a tech guy, but when all I see is numbers, I'm really not that wise... :silly:
Since I know for a fact that I don't have any rogue apps installed, guess I should leave it be and carry on.
But anyway, just for the heck of it, I opened the file in Notepad. Here's the first line (as seen in Notepad, lol).
Code:
ÿØÿà JFIF ÿÛ „
(1#%(:3=<[email protected]\[email protected]_bghg>Mqypdx
I'm sorry, but this is way out of my league. :/
Mod Edit
Thread closed at the request of the [OP]
malybru
Forum Moderator

Categories

Resources