
Delivering fast boot times in Windows 8 - ghurlman
http://blogs.msdn.com/b/b8/archive/2011/09/08/delivering-fast-boot-times-in-windows-8.aspx
======
artursapek
I don't really care as much about the boot time as the time between my desktop
showing up and any of my commands being recognized. On my old Thinkpad as soon
as the desktop and Start menubar showed up I got the same two laggy warnings
about incompatible drivers _every single time I would boot_ , and for 20
seconds or so icons wouldn't even respond to me hovering over them. Then I
would have to wait another 20-45 seconds for anything to open while all the
little icons and their respective programs were loading in the bottom right
part, among with other background activity.

Granted the computer was a couple years older than average users' these days,
but psychologically it was just infuriating to think the computer is ready for
me, and then having to sit through the "second boot." Instead of a super-fast
boot they should focus on a super-simple boot which isn't torture to watch. I
can walk away from my machine and do something else for a minute while it's
booting, just like anyone does when they're popping popcorn. But the popcorn
should be easy to open once it's "done."

~~~
drzaiusapelord
Its not the OS's fault that you've littered your machine with all sorts of
startup checkers and startup apps. Then again, most end users arent aware of
this.

Is the state of software engineering so poor that no one has considered
staggered or delayed startup for some of these borderline useless apps? I
mean, startup is a busy time in the computer world and on the server end of
things we use delayed services all the time, but on the dekstop the assholes
at Apple and Google and the rest just assume that their little startup app
should run immediately and with full priority and so what if you have 5 others
just like this. Heaven forbid someone consider the end user experience here.

I think MS had to step in and set these things to low priority starting with
Vista. What a mess when the OS guys are fixing what the app guys are simply
unable or unwilling to do.

~~~
Sephr
To be fair, Google's updater doesn't run until the computer is idle for a
certain amount of time.

~~~
artursapek
As they all should!

------
blinkingled
On my X220 the Windows 7 boot is already fast even without a SSD (pre-desktop
authentication and some Lenovo sauce helps) but watching the video FTA -
that's mind bogglingly fast - it's more like the Mac's sleep/resume than a
cold boot!

The key change seems to be a clever kernel session hibernation. They discard
user sessions as those involve writing a lot of data (full hibernation) but
save kernel session which can be written out and read back fairly quickly.
Then there is multicore enabled resume - doesn't help with disk io but with
decompression of hibernated data.

~~~
justanotheratom
curious why you think multicore enabled resume would not help with disk io?
Atleast on an SSD, I would think it should.

~~~
Gonsalu
If hibernation didn't use compression, there was no need for CPU involvement
due to DMA. Since there would be no CPU involvement, being multi-core enabled
wouldn't be of help.

------
gks
That's actually pretty slick. Not sure if other operating systems do something
similar already. I know my Macs "sleep" rather than hibernate and are nearly
ready immediately upon hitting the power button or flipping the lid open.
While that isn't the same as what Microsoft is doing here it is a pretty
clever way to achieve faster boot times.

Microsoft does have some intelligent people working there. It's such a bummer
it can't get some real work done outside of Office and Windows. I'd say their
games unit is pretty solid too but everything else seems to be a real hit or
miss scenario.

Neat reading these things though.

~~~
lloeki
_> I know my Macs "sleep" rather than hibernate_

More precisely they do both. Close the lid and they save RAM to disk, then
sleep. Open the lid and they resume instantly from sleep and discard the
hibernation content, but wait long enough to drain the battery (or pop off the
battery e.g for a swap on older Macs) and they will resume from disk.

IIRC Win 7 knows how to do that, though it might not be default.

~~~
Mavrik
It is the default on battery powered systems. The system goes to hibernation
if sleeping for several hours or if battery level is low.

~~~
lloeki
I wonder why not on desktops? My work transparently survived a nightly power
outage on my sleeping iMac.

------
exithrowaway
I have a feeling the reason more folks shut their whole computer down in
windows is because sleep / resume is "untrustworthy". I've tried using
sleep/resume over multiple windows laptops , and half the time it either
didn't turn the display on, or worse, the wifi wouldn't enable which caused me
to reboot anyways.

I haven't had the same problems since I switched to mac, aside from
occasionally having the screen not come up immediately. This lets me run many
things and not feel fearful about it all getting lost when I resume.

* that said, I did watch a non-techie guy always shut down his imac when he didn't use it, seemed awkward to me but eh.

~~~
epochwolf
I've had Windows XP/Vista crash on resume or fail to sleep at all more than
often than not.

------
defdac
"Of course, there are times where you may want to perform a complete shutdown
– for example, if you’re opening the system to add or change some hardware. We
have an option in the UI to revert back to the Windows 7 shutdown/cold boot
behavior, or since that’s likely a fairly infrequent thing, you can use the
new /full switch on shutdown.exe. From a cmd prompt, run: shutdown /s /full /
t 0 to invoke an immediate full shutdown. Also, choosing Restart from the UI
will do a full shutdown, followed by a cold boot."

~~~
lloeki
I was wondering how this would impact multi-boot systems, as mixing
hibernation and multi-boot is an extremely bad idea (unless you know what
you're doing, and even then there a are so many ways to shoot yourself in the
foot).

------
xpose2000
I will buy Windows 8 for these improved boot/hibernation times alone. It's
painful to watch my computer wake up from hibernation in 15 to 30 seconds.
(That's with SSD)

------
rhplus
Here's a flashback to a similar post in 2008 about the fundamentals work done
for Windows 7 boot performance:

[http://blogs.msdn.com/b/e7/archive/2008/08/29/boot-
performan...](http://blogs.msdn.com/b/e7/archive/2008/08/29/boot-
performance.aspx)

------
mkup
And what if I turn off my computer with Windows 8 and add/remove/swap PCI
cards? HDDs? It will crash when booting and corrupt my data, isn't it?

In Windows 95 I had two options: reboot and poweroff. In Windows 2000 I had
three options: reboot, poweroff and sleep. In Windows XP/Vista I have four
options: reboot, poweroff, sleep and hibernate. Finally, in Windows 8 I will
have five options: reboot, poweroff-which-is-not-really-a-poweroff, poweroff-
which-is-really-a-poweroff, sleep, sleep-and-then-hibernate-if-battery-is-low.

True Microsoft Way. It remembers me funny examples from Alan Cooper book 'The
Inmates Are Running the Asylum'.

~~~
polshaw
> It will crash when booting and corrupt my data

I'm sorry but i have to call you out here; i would be suprised if MS hasn't
thought of this in some way; whether detecting changes and initating a more
complete boot or dealing with it in the GUI.. but even if it required you to
select a 'full' shutdown/boot, i would say it was completely worth it for a 7s
boot time.

Further, i find your imagination regarding the practical handling of these
power states rather lacking. The way i see it there will simply be 'reboot',
'power off' (which hibernates the kernel as described in the article,
reloading it where checks show necessary), and 'standby' (which also writes
ram to disk allowing resuming from hibernate with power loss -- i would
imagine this could be turned off with a setting). So, contrary to your rant, i
am going to bet that there will be one _less_ standard option. But i guess
things were better in the w95 days?.

~~~
mkup
> whether detecting changes and initating a more complete boot or dealing with
> it in the GUI.

Sure, they can detect hw changes and make full cold boot, therefore losing all
RAM data which was saved to the disk at the point of hibernation. (It would be
like a quick dirty reset.) Or they can restore that data back to RAM and crash
the kernel instantly. In either case, RAM contents are lost.

So each time I turn off the PC, I have to plan ahead, "do I want to use
poweroff-type-I or poweroff-type-II option?" If I won't guess right, then I
lose my data.

~~~
polshaw
This new 'power off' isn't meant to be a full hibernate. It only stores the
kernel-related RAM, not your data. So you would only lose your kernel data,
which would be reloaded in the 'full' boot. Full hibernate is still a separate
entity (or at least, a part of standby as i'd predict).

This is not a change from now; if you hibernate and then change your hardware,
yes, you will lose data.

~~~
mkup
OK, now I get the idea

Still there could be some edge cases - like hibernating filesystem cache as a
part of kernel-related RAM , then shutting down, booting Linux, changing the
filesystem and then booting windows (which does not know that filesystem pages
were changed from outside and working with obsolete copy from cache).

This one is a non-issue actually, because Linux ntfs-3g driver deletes
hiberfil.sys when mounting NTFS partition in R/W mode, but there could be
other edge cases like this one.

------
ck2
Of course in the real world you'll need to add anti-virus, anti-rootkit, anti-
spyware, keyboard scrambler and personal firewall to windows so you need to
add about 5-10 seconds to their sterile boot times.

~~~
demetris
Of these five I only have the firewall enabled on my Windows 7 desktop. And
that only because I can’t be bothered to look into some issues with
interdependencies when you disable the Windows firewall. (Can’t recall what
exactly now.)

I don’t think the firewall adds anything significant to the startup time; it
is just one of the dozens of services that start automatically.

Then, for many people an antivirus program may also be useful. Would that add
5 to 10 seconds to the startup time of a modern machine?

For the other 3—anti-rootkit, anti-spyware, keyboard scrambler— why do you
think they are necessary for every user of Windows?

~~~
seabee
> I don’t think the firewall adds anything significant to the startup time

Think how long iptables takes to load, plus installing a couple of system
hooks to detect unknown programs and a GUI window to warn about them. This
stuff only takes a long time to load if you're loading in a huge framework and
JIT at startup - startup times are very quick for C++ programs using Win32 API
calls or WTL.

I'd say anti-virus and anti-spyware are mostly treated as one these days
(anti-malware) - with things like Microsoft Security Essentials, Norton
Internet Security, etc. I use MSE and it sure as hell doesn't add 5 seconds to
startup. It doesn't even add 1. But perhaps it's because I'm running a 'post-
modern' machine with an SSD...

------
ojosilva
I find it a bit suspicious that the video has been spliced at 0:33. Maybe the
boot hadn't really finished and a "Still loading" window popped-up.

------
mikeknoop
From all the MSDN posts I've seen thus far, it looks like MS is going to kick
their "every-other-os-is-great" trend with Windows 8.

~~~
serge2k
Now they just have to enforce a rule on OEMs that every windows 8 PC must meet
requirements that allow it not only to work, but actually make it work well.
Especially in regards to ram requirements.

I like what they did with WP7 in that regard.

~~~
kevin_morrill
Thanks to the antitrust trial in the late 1990s, they've mostly been neutered
in this regard.

~~~
sid0
The agreement has expired, right?

~~~
kevin_morrill
Very much alive in the European Union still. If you just lost billions of
dollars in legal entanglements, I doubt you're going to do it again. No matter
how valuable it might be to customers.

------
KeyBoardG
Another great point hidden in there is the sleep+hibernate feature in which
when sleeping, if power is lost the system's state is not. You would simply
boot from hybernation from the sleep point.

~~~
justanotheratom
I believe that has been the case since Vista.

------
celalo
This one of rarest stories about Microsoft on HN. It is easy to forget about
Microsoft all together. Good to notice Win8 could really add up to the
previous versions.

~~~
wmf
All of the B8 posts have gotten good HN coverage because they're written in
our language.

~~~
Luyt
Plus, they publish their videos in the MP4 format so you don't have to install
Silverlight crapware first (or are even unable to watch it at all if you're
not on Windows).

------
olaf
fast? faster!

------
pointyhat
My Windows 7 hasn't been rebooted for the last 22 days. I'm not sure I'm that
impressed with fast booting.

~~~
smiler
Did you look at the article? Microsoft has data that says roughly 50% of
people shutdown their PCs. So clearly, a lot of people do care about fast
booting

~~~
pointyhat
Yes but that's just an education issue. You don't need to shut them down all
the time. Perhaps they should make the whole shutdown/sleep/hibernate thing
more intuitive.

~~~
cryptoz
Standby modes still use electricity that drains battery life and draws
unnecessary power from the grid. It may be faster for the user, but it's not
necessarily better for them.

Also, I haven't used Windows laptops in a while, but the Sleep mode on XP was
really terrible - if I selected Start -> Shutdown and then closed the lid,
when I came back and opened the lid I would find Windows resuming the shutdown
procedure due to automatic sleep mode.

Fast boot times are very important because there are lots of people who _do_
need to turn their machines off. Maybe Microsoft have fixed various usability
problems, but the electricity ones still stand.

Why have running electronics that you're not using?

~~~
goblin89
Doesn't turning machine off and on each time shorten life of various its
components? That way, a user would need to buy a new one sooner, which is
definitely not better for them and the environment. I'd agree with grandparent
in that _most_ people normally do not need to turn their machines off
completely and are better using sleep mode / hibernate, and this is the thing
that needs optimization in the first place.

~~~
seabee
> Doesn't turning machine off and on each time shorten life of various its
> components?

More so than 8+ hours of use, do you think?

I've heard the myth often enough, though never any evidence either way.

~~~
pointyhat
CCFL backlights, hard disks, CPU fans and solder joints all fail during
thermal cycling.

------
recoiledsnake
That looks like an insanely fast boot, under 10 seconds, must've been an SSD.
Hope Windows 8 leads HDD manufacturers to make Hybrid hard drives, say a 3TB
disk with 16GB SSD embedded inside. The OS can decide what files to keep on
there based on usage (boot files and frequently used programs are an obvious
choice).

~~~
0x0x0x
Not disparaging them, but on my MBP/SSD Lion boots to login screen in about 2
seconds and boots to desktop w/ auto-login turned on in ~5.

~~~
zzleeper
Are you talking about cold boots, or resumes from sleep/hibernate?

~~~
0x0x0x

        Machine off, cold start to login screen: 6.7s
        At desktop clicking restart to login screen: 5.9s.
        Wake from sleep to login screen: 3.2s
        Lift lid to login screen: 2.8s.
    

Those are single run YMMV, etc.

~~~
cliftonk
Same numbers here on my macbook pro. Another important stat is that when our
laptops wake up, we re-establish wifi connections in ~100 ms, compared to the
average of 10 seconds on PCs.

~~~
recoiledsnake
>average of 10 seconds on PCs

Got a citation for that? My PC seems to connect instantly.

~~~
sjs
Asking for a citation is fair but he did say average and most folks on HN do
not use average computers. My guess is that you have an above average machine.

~~~
polshaw
Maybe, but apple only make 'premium' laptops (especially since killing the
macbook), not comparable to an 'average' (read: a few years old, fairly
budget) laptop.

------
BonoboBoner
Fast boot no longer matters. Fast sleep/wakeup is important. I love that ipad-
like instant possible usage of my macbook air. I open it and it is just there.

~~~
AndrewDucker
Same is true on Windows. It takes less than the time it takes for me to open
the lid of my laptop for it to be ready to use.

------
glhaynes
"we want to start with boot time – no feature gets talked about and measured
more."

What?

I've never understood why I should care since it's something I do once a week
or less for a few seconds.

~~~
jerf
Your homework is to go to the office of a company of more than 10,000
employees at the start of the work day, turn on your computer along with
everybody else, and sit there doing nothing until you manage to pull up a
browser and hit a web site of your choice and can actually manipulate it.

My father's laptop, larded with the corporate, err, "value add software", once
took five minutes to pass that gauntlet, without even any local network
activity. You do want to make sure you can pull open the browser and do a bit
of real work, though; the desktop appeared in about a minute, but you couldn't
actually _do_ anything. With the Maverick release of Ubuntu, the same test
could be passed in 45 seconds. (Still not what I'd call speedy, I just include
that for reference. Yes, it's a laptop and the hard drive hurts, but the
hardware wasn't _that_ bad. Also, this was XP, which I know from experience on
that hardware should have taken roughly 45 seconds too.)

You might understand why it's a bit of a sore point with many people whose
wallets Microsoft is listening to after that experience.

(It appeared to me, based on the process list and the way the machine was
performing, that the simultaneous presence of backup software trying to scan
every file access and virus scanning software trying to scan every file
access, and for all I know trying to each perform other real scans of the
disk, was causing major disk thrash, which combined with the fact the virus
scanner insisted on scanning various files before the OS could execute them
caused major, major slowdown. I'd never put up with this on my machine, but
somehow I suspect this is not an uncommon case in the corporate world...)

~~~
drivebyacct2
Right, that start up time is not Windows starting, its the bullshit software.
Meaning that even if Windows 8 boots a bit faster, that same bloatware is
still going to make it slow...

~~~
ak217
That and the slow booting BIOS. In a legacy PC, there is very little need for
most of what the BIOS does, and that firmware code is usually not well-
optimized by the OEMs... I wonder what's taking EFI so long.

~~~
drivebyacct2
Crappy implementations from Apple? Sorry, I've been scorned several times and
I'm frankly not impressed with the effort exerted to make their EFI impl
decent (largely because I think they don't want it to be as robust as it could
be).

~~~
drivebyacct2
Thanks for the downvotes. You all must have an EFI that boots installation
media reliably, or have one that has a proper BIOS emulation with usb support,
or have one that has support for graphics switching when not in OS X, or have
one that doesn't require an HFS+ partition with "bless"ings.

------
nabaraj
Are you kidding me? Hibernating kernel is like saving all the malicious script
to save so it can re-run again on next startup.

~~~
rbanffy
You have a point. If you shut down this way, you won't have a clean boot the
next time and will be carrying over some context from previous sessions.

I am not sure I like the idea.

------
brainless
>>> Qualitatively, people say they prefer to shut down because they want to
have their PC completely “off” so that it uses no power – either to preserve
battery life or to reduce their energy use. Hibernate is also a good option
for this since it similarly has no power draw, and many people really like it.
However, it’s clearly not for everyone, since one of the other things we’ve
heard is that many people want to turn their PCs on and have it be a “fresh
start” rather than running all of the stuff from their previous session.

Really so? It is not that people want to "start fresh", it is because the boot
times from hibernate have been pathetic.

Now I am on a MacBook and I never almost shutdown, just sleep. Yes sleep
consumes power, but what I mean is that I would not want to "start fresh" each
time. No way.

How many people here want to "fresh start" at each boot?

~~~
drivebyacct2
>How many people here want to "fresh start" at each boot?

For Windows? I only restart because I _need_ a fresh start.

~~~
brainless
I completely agree with needing a fresh start. I do not know why others would
need it on Windows. But I do that so that the PC lags a little less. Windows,
I feel from daily use _, gets slower the more you keep it open.

_ I do not use Windows in recent times, either Ubuntu or Mac. But still want
to see a better Windows 8 so I can use that too.

