I suggest a tmp directory for every site, what the idea of it?
when a video is downloaded for the first time, it stays in the tmp directory of youtube for example , until this movie is served from the cache it moves to the permanent directory of youtube and stays there.
the movies that are in the tmp directory of youtube which has been downloaded and viewed only once must be deleted after a specific time for example 3 months .
the idea is not to full the harddrive with movies only downloaded and viewed one time only.
I understand the need for clearing of unused cached videos but creating temp directories for each website is not really the forward compatible solution. That would be difficult to manage for me. I'll work on a script which will clear videos from all websites cache directories.
Thanks for the suggestion.