Wednesday, July 30, 2008

HowTo: Delete All Thumbs.db Recursively

An offline messages just arrive from a fedora newbie trying to polish more of his FTP administration skills.

After quite some time of establishing his fully functional FTP server via VSFTP, he then realized that most of their staff with windows-based desktops usually Selects ALL files, Copy and Paste to FTP site, the normal non-techie way. Unaware that selecting all files from currently working windows folder also selects the Thumbs.db file to be uploaded to that same FTP server.

This Thumbs.db file is by the way created by windows OS for the purpose of thumbnailing cached image files, which has a filesize of 23040. If you've 1,000 of that, you just lost 23MB of disk space.

Now, the answer to his question of deleting Thumbs.db file recursively following the same concept with recent postings. This can be simply done using find.


# find ~ftpusername -name "Thumbs.db" -exec rm -rf {} ;


Adding to cron job on every morning or on daily basis would be


01 07 * * * find ~ftpusername -name "Thumbs.db" -exec rm -rf {} ; > /dev/null 2>&1


Goodluck, hope this helps.

Related External Articles:
What Happens After rm -rf / ?

0 comments:

Sign up for PayPal and start accepting credit card payments instantly.
ILoveTux - howtos and news | About | Contact | TOS | Policy