What are the pros and cons on compressing old files on a disk? I've read that compressing old files will degrade the performance when accessing the compressed files. I've got gigabytes of old files in my laptop; is it worth the trade-off?
I have the following installed on this laptop (it's my playground/test system):
- SQL Server 2005 Developer Edition
- SQL Server Express
- Informatica PowerCenter v7.x
- Oracle 9i
- Toad for Oracle
- VS 2008 Professional Edition
- VS 2005 Professional Edition
On the contrary, compressing files can improve performance.
Disk time is expensive, processor time is cheap. Compressed files can be read faster than uncompressed ones (they are smaller), and on modern machines there should always be enough processor time available to decompress them on the fly.
Compressed files makes a big difference when you have a bunch of small text files (like source code, batch scripts, etc.) it makes the least difference to your downloads directory that is full of large zip files. So your mileage may vary.
Instead of letting Disk Clean-up compress your old files, instead use Windows Find Files and look for files over a certain age by type. Then compress or delete those.
If you need to free up space though I recommend using WinDirStat. It will show you where you are using the most space. Especially with a "playground machine" like you have, you may be surprised that you still have an old install of Oracle kicking around that you forgot about, or a database instance leftover from the time you experimented with storing really large image files in a DB. Since it helps you to target your cleanup efforts where there is the most space being taken up, you get more results quicker. It can also show you if you have a directory filled with a lot of small files, which might be a good candidate for compressing . . . .
The compression isn't great, which also means the performance hit isn't massive. If you're looking to archive information I suggest you use "real" compression such as 7zip.
I doubt you'll notice the difference in performance if you compress your files, although if you're compressing a fair bit you'll most likely notice the space saved. I say go for it.
Edit: Although I suggest you keep your binaries (C:\Windows and C:\Program Files) uncompressed.
If you are running out of space on your laptop and you "need" to get more space out of it then yes its ok. The performance hit isn't too bad when opening documents/music but if you trying something like playing a game that's compressed then you will run into trouble.
Careful with compressing databases. SQL Server 2005 / SQL Server Express does not support compressed databases (might support them if they are read only, I'm not sure).
If you let this tool compress the old SQL server databases, you will no longer be able to access them before you decompress the database files again.