Ask HN: Why don't operating systems gzip their startup files?
I was pondering why modern operating systems take so long to start up... We have a huge amount of processing power on each machine after all, and we should be able to process all the required start up routines thousands of times faster than just a few years ago. I realize that the slowest part of modern computers are the hard drives (about 90 Mb/s is high for non-SSD) and not to mention seek times.
Which leads me to the question: why not GZIP all the required startup files? In fact, why not TAR them too, and make them sequential? Our modern CPUs would be more than powerful enough to handle the decoding process. Is there something preventing this compression? Or are they doing this already?
14 comments
[ 3.3 ms ] story [ 36.9 ms ] threadThe reason that modern operating systems take a fairly long time to start up is due to things like enumerating hardware for PnP, getting a network address from DHCP, and starting whatever system services are necessary for you to have a pleasant (if you want to call it that) user experience. It really doesn't have anything to do with the size of the executable files, since the CPU is going to have to run the same code to make it all happen anyway (you can't execute GZIP'd code and have it run faster).
I agree with you, though - I don't think that's really why it's slow - I'm just pointing out what he meant.
And you even provided some supporting evidence. I don't think that it's conclusive, but until I'm willing to do the work....
> To actually seek to find all these gazillion small configuration files.
If that's the actual bottleneck, perhaps a different configuration system would be a better solution.
It is that most file systems are optimized for large files.
Reiser FS promised to be a killer FS, handling small files and arbitrary file-meta-data, but well... <insert un-tasteful joke here>.
To see this in benchmark form, look at the difference in drive speed tests between large reads (sequential) and small reads (random). You'll go from 60 Mb/s to 6 Mb/s when file size drops from gigabytes to kilobytes, because more of the time is spent seeking.
Developers should be using the oldest and least available memory machine they can lay their hands on.
Want to see a zippy starting system ? Install Xenix 386 on your 2.8 GHz machine. Or windows 95+trumpet winsock if that's your thing.