Live data from Hacker News

Booting Linux in One Second [pdf]

elinux.org

11–20 of 110 posts

Re: Booting Linux in One Second [pdf]

#11
post #3

An OS is recomputing the same functions over and over again when booting, so why not cache all of this, and make it instant?

How much do you cache? Hardware is difficult because you could add/remove/swap it at any time, and software information is already partly cached depending on your OS.

IIRC, Windows a) builds a list of files to pre-load from disk based on your usage, and b) doesn't actually fully shut down by default (it goes to hibernate mode: http://blogs.msdn.com/b/olivnie/archive/2012/12/14/windows-8...). I don't know if any Linux distros do either of those by default, but it is certainly possible.

Also, some BIOSes already have a "quick boot" setting which caches some hardware information, particularly about memory. It usually comes with a warning that you need to disable the setting for at least one boot when installing RAM.

Re: Booting Linux in One Second [pdf]

#12
post #3

An OS is recomputing the same functions over and over again when booting, so why not cache all of this, and make it instant?

Hardware requires specific handshaking to get it to initialize, the kernel cannot assume that the hardware that was present last time is available this time, and orchestrating everything is not an easy process.

The holy grail would be a kernel organized and designed to cache everything to disk related to its own configuration, and only re-execute/rerun the hardware reinitialization code.

Admittedly, Windows' current approach to bootup is very close: it closes all applications then pseudo-hibernates the kernel. Bootup simply reads the hibernated kernel state from disk and reloads userspace.

This is of course besides traditional full ACPI hibernation, which is pretty cool but isn't a perfect art. (I'm typing this on a ThinkPad T23, a fairly old (and thus well-tested) hardware configuration; its hibernation/resume is usually rock-solid, but this morning my WLAN decided to get all stupid with dhcpcd, and USB decided that while it could see my external HDD, there wasn't a disk inside it. From-scratch boot is still the only way to get a reasonably predictable system state.)

Re: Booting Linux in One Second [pdf]

#14
1 seconds seems a rather arbitrary measure. In HCI 100ms seems to be the value that's generally taken under which an action seems to be happening instantaneously [1]

It's quite sad to see how we hardly use the computing power offered by our modern computers to actually speed up common tasks, but instead bloat it up with all kinds of stuff.

[1] http://cogsci.stackexchange.com/questions/1664/what-is-the-t...

Re: Booting Linux in One Second [pdf]

#16
post #9
post #8

Earlier quoted context omitted.

I once had a brief conversation (via Reddit) with a guy using JACK for a commercial (embedded Linux) networked audio system. I wasn't aware of the exact specifics but I understand it was Sonos-style, embedded boards inside speakers. He wasn't particularly interested in talking about the work his team had done :P I think that proves your point.

> He wasn't particularly interested in talking about the work his team had done :P As in, he tried to keep the secrets secret, or it seemed to be trivial and uninteresting to him?

more likely the former

Re: Booting Linux in One Second [pdf]

#19
post #17
post #4

Earlier quoted context omitted.

Also known as "suspend to disk"?

After which you'd have to load 8Gb from disk/SSD in under 1 second...

If you need 8G of resident memory to have the apps you want running then you need 8G... no shortcuts. That is a pretty high figure, though. Afaik things like disk caches aren't restored during a suspend/resume.

Re: Booting Linux in One Second [pdf]

#20
post #3

An OS is recomputing the same functions over and over again when booting, so why not cache all of this, and make it instant?

The biggest problem with caching things during the boot process is that turning our devices off and on again will not magically solve our problems any more.
Post reply on HN