View Full Version : Option to purge unused thumbnails?
Was just flicking through my thumbnails folder (which is getting rather chunky in size) and noticed art for lots of things that are no longer within my library.
Is there a method to clean this up short of deleting the folder and rescraping? I'm quite limited on space and this could really help out.
If it is not possible, wouldn't this be quite a useful feature?
Some of us like to run XBMC off CF cards, a silent and cheap option but limited space.
I have noticed that the current way the thumbnails folder works, it does not delete data that is no longer in use.
I think it would be very useful to have a feature to clean the thumbnails file. Check from the database what files are currently in use and delete the rest.
This would save an unnecessary waste of space.
jmarshall
2009-07-07, 01:42
Nope. Rewriting the whole thumb side of things is something we want to do but noone at the moment has the time. It's not exactly a straightforward task.
A good first step would be to document exactly where we're doing thumb stuff (it's in a LOT of places) and to document exactly what these functions are doing.
Second step would be to document what we WANT the thumb system to do. Examples are we want a thumbmanager to keep track of where thumbs were cached from (local file next to the media, local file that was browsed to, downloaded from internet etc.), when they were last cached, when they were last accessed and so on.
Third step is moving all the current thumb stuff (from step 1) to a single thumbmanager.
Fourth step is cleaning it up so that it does things as specified in step 2.
Volunteers most welcome. I can assist with step 2 at least!
Cheers,
Jonathan
jmarshall
2009-07-07, 02:11
Threads merged. No need for the 2 posts.
Cheers,
Jonathan
Has this ever made it as an official feature request on Trac? I did some searching for "clean thumbnails" or "remove thumbnails" and didn't come across it. Maybe I didn't look hard enough. I am wondering because my thumbnail folder is gaining on 1GB rather quickly with an influx of new content every day. I have plenty of old content that could stand to loose the old thumbnails.
jmarshall
2009-09-15, 07:14
Given that I know about the problem, I'm not sure how useful a trac ticket would be, but feel free to create one if there isn't already one there (check through any ticket assigned to me for a start) and feel free to cc me.
I thought I might look into doing step 1 if I get the chance over the next couple of weeks.
Cheers,
Jonathan
while it's not ideal, if you remove the thumbs folder, it'll regrab those images the next time they are accessed, think of it as brute force cleanup.
nothing more then just removing the cached images is needed, no other changes are needed, no rescraping, etc.
i'm not quite ready to dig into that portion of umx and xbmc, but i've got some pretty good ideas on how to handle the images that xbmc caches (via umx) and since i'll be lookign at both sides of things, i can prob find a way to do it from xbmc as well (although it would be something you would want to make sure the all your source locations are available before running.)
the more i think about it, adding something to the xbmc side would be alot easier then from externally, maybe i'll try to do both if i get the time