Preview only show first 10 pages with watermark. For full document please download

How We Made Ubuntu Boot Faster

   EMBED


Share

Transcript

How we made Ubuntu boot faster LinuxCon 2010, Boston How we made Ubuntu boot faster ● Why boot speed matters ● Process for improvement ● What we changed Why boot speed matters Sometimes you can't just suspend Why boot speed matters Some users reboot all the time Why boot speed matters When you're paying for uptime Why boot speed matters The work has other benefits too ● Smaller operating system image ● Smaller memory footprint ● More efficient use of hardware ● Reduced power consumption Process for improvement Pick a baseline Process for improvement Pick a process Improve what you have: ● When there's lots of low-hanging fruit ● If you have limited time or man-power Aim for a target: ● Requires work across the platform ● Easier to justify the hard decisions Process for improvement Decide on your targets 10s boot: ● 2s for kernel and initial ramdisk ● 2s for platform initialisation ● 2s for graphical subsystem ● 4s for the desktop environment Process for improvement Make sure you can measure What we changed Kernel ● ● Asynchronous kernel initialisation work already done by Moblin Extended to move populate_rootfs() to an asynchronous thread What we changed Initial ramdisk ● ● Can't drop this since we support multiple hardware controllers, hibernation, RAID, LVM, encrypted root disks, etc. Replaced while/sleep loop around blkid with a libudev utility What we changed Upstart Bad: ● ● Critical path of 1,000s of line of shell script while/sleep loops to wait for things like network and disk Good: ● Event-based system designed to eliminate race conditions What we changed Hard drives suck What we changed SSD suck too What we changed ureadahead What we changed ureadahead on SSD What we changed ureadahead on HDD What we changed Ubuntu Light [email protected]