One of the main problems with Windows Vista (and earlier versions) is that Windows consumes quite a lot of diskspace, with few means to trim down the installation. To make matters worse, Windows tends to accumulate a lot of megabytes and even gigabytes of space during its lifetime, leaving users at a loss as to how to reclaim this lost space. In a post on the Engineering 7 weblog, Microsoft program manager of the core OS deployment feature team (…) Michael Beck explains what Microsoft is doing in order to reduce the disk footprint of Windows 7.
Not too long ago, disk space was pretty much a non-issue to many people. Hard drives have become insanely large lately, as well as insanely cheap. When you have 1TB of disk space, it is rather insignificant if Windows takes up 8GB or 7GB. However, as of late, small solid state drives have come onto the scene, especially in netbooks like the Aspire One, the Asus Eee, and others. They usually come in sizes of 4 or 8GB, which is certainly not enough to fit a Vista installation – and with no way to trim the OS pre-installation, there’s little you can do (not that you’d want Vista on those cheap SSDs with crappy controller chips, anyway).
Let’s talk about the %systemroot%winsxs
directory first. On my main Vista desktop machine, this directory appears to be eating a whopping 8GB of disk space – and this installation is only a few months old! This directory, new to Windows Vista, is the subject of many discussions on disk space, but as Beck explains, it needn’t be. This directory doesn’t actually contain a lot of data at all, only about 400MB.
The Windows SxS directory represents the “installation and servicing state” of all system components. But in reality it doesn’t actually consume as much disk space as it appears when using the built-in tools (DIR and Explorer) to measure disk space used. The fact that we make it tricky for you to know how much space is actually consumed in a directory is definitely a fair point!In practice, nearly every file in the WinSxS directory is a “hard link” to the physical files elsewhere on the system – meaning that the files are not actually in this directory. For instance in the WinSxS there might be a file called advapi32.dll that takes up >700K, however what’s being reported is a hard link to the actual file that lives in the WindowsSystem32, and it will be counted twice (or more) when simply looking at the individual directories from Windows Explorer.
This is done for servicing and imaging reasons. “The value of this is that the servicing platform (the tools that deliver patches and service packs) in Windows can query the WinSxS directory to determine a number of key details about the state of the system, like what’s installed, what versions, and what updates are on the system to help determine applicability of Windows patches to your specific system,” Beck explains, “This functionality gives us increased servicing reliability and performance, and supports future engineering efforts providing additional system layering and great configurability.” The directory also helps in making Vista ‘image aware’, important for administrators who wish to deploy and manage many installations (a system doesn’t have to be running to have its winsxs directory probed, or patches applied to it).
Beck explains that much of the disk space in Vista goes to reliability, security, and recovery features, such as system restore, hibernation, page file, registry back up, and logging. In Windows 7, users will have more (and easier) control over how much disk space these systems may use. They also promise to allow you to set these parameters ahead of time, and that Windows itself will also be more sensible about the default settings.
Another pressing issue is that Windows consumes more and more disk space as time goes by. “For many, the ‘growth’ over time of the installation proves to be the most perplexing,” Beck admits, “And we hear that and need to do better to (a) make smarter choices and (b) make it clearer what space is being consumed and can be reclaimed.” To give you an idea of which components eat what amount of disk space, Beck made a table that covers all of the disk space consumed by a fresh Windows Vista SP1 Ultimate installation.
In conclusion, as we develop Windows 7 it’s likely that the system footprint will be smaller than Windows Vista with the engineering efforts across the team which should allow for greater flexibility in system designs by PC manufacturers. We will do so with more attention to defaults, more control available to OEMs, end-users and IT pros, and will do so without compromising the reliability and robustness of Windows overall.
My Windows Vista directory alone nears the 14GB (6 if you didn’t count the winsxs directory), so I’m hoping Windows 7 will indeed be less hard drive intensive. By the way, if you want to know more about Windows’ use of virtual memory, NT guru Mark Russinovich has an in-depth post on the subject.
Geez… so Microsoft is saying that they are treating hard links exactly as the actual file, so much so that it appears that hard links are the same size as the original file?
That’s kinda dumb. Maybe they should try BeOS, and just copy their symlink model.
I could very easily duplicate the winsx whatever folder in BeOS using MAYBE 1 MB of space, and it will be reported as such as well.
Symlinks are what Microsoft calls hardlinks, they are simply ‘virtual’ file system object which point to another file and which can act exactly as the file to which it points.
BeOS supports two types of Symlinks: absolute & relative, the only difference being how the linked file is located ( with an absolute path: “/boot/home/Desktop/someFile” vs “../someFile” ).
BeOS shows Symlinks as being what they are, and gives them a faint underscore to differentiate the real file from the Symlink. However, when a program blindly opens a Symlink the system just substitutes the linked file by negotiating the Symlink.
The difference is that it is incredibly trivial to determine if the file being dropped is a Symlink. So all Microsoft needs to do is ensure that they can do the same – trivially check to see if the file is a “hardlink” and treat it as such in Explorer until invocation or data access is required.
Operations that would be performed on a link versus the actual file are different, but some things will be common, such as size & name, those things will require special handling. BeOS does this with the BSymlink class ๐
Explorer should just implement a quick check to see if the file is a hardlink or not, and follow the BeOS standard of very subtle differentiation. Size in BeOS is assumed to be 0 for a symlink, but they still take size in the folder and report as such, accurately.
Oh well, that is the problem with numerous teams working on separate parts of a single product without enough intercommunication.
Personally, I think Microsoft could cure an incredible amount of their problems if they simply started feeding the final pre-release builds up to higher support teams, each team consisting of fewer and fewer members, until you get to a single person who would examine issues raised and determine validity of the issues, and be able to suggest fixes.
I’d do it, I know I could do it, I’ve done it in the past. Apparently people liked it ๐
Oh well, I turn down Microsoft’s offers because I’d prefer to work right here from home ๐ They can’t pay me to move, either.
–The loon
… besides, my uncle used to work for Microsoft and they withheld pay for so long he decided to rob a bank to try and get by. He planned it out rather well, but the teller’s car he was going to take wanted her house keys, so he wasted time getting the car key off the ring while the silent alarm was triggered. He got off with a slap on the wrist ๐
Edited 2008-11-22 19:51 UTC
Vista has both symlinks and hard links. here is the output of mklink on my computer
Microsoft Windows [Version 6.0.6001]
Copyright (c) 2006 Microsoft Corporation. All rights reserved.
C:\Users\Matt>mklink
Creates a symbolic link.
MKLINK [[/D] | [/H] | [/J]] Link Target
/D Creates a directory symbolic link. Default is a file
symbolic link.
/H Creates a hard link instead of a symbolic link.
/J Creates a Directory Junction.
Link specifies the new symbolic link name.
Target specifies the path (relative or absolute) that the new link
refers to.
Ah I see, thanks for that!
I love being corrected when I’m wrong – it’s the best way to learn!
So I guess then that hardlinks are designed so that if you overwrite it, the linked file itself is overwritten, and a special procedure is needed to remove the link.
Still, Explorer & any other app should still be able to realize when the file is a link rather than the actual file.
Thanks again ๐
–The loon
The idea behind a symlink is that it points to another file. The idea behind a hardlink is that it is another handle on the file, no different then the first handle on it, just stored in a different logical place.
just google it and you will probably find a billion links to clearer and more succinct explinations than mine ๐
symlinks are a better idea 99% of the time. when i read that ms was implmenting hard links my first thought was “why?”. my guess is that winsxs is one of the only reasons they exist on the platform.
Edited 2008-11-22 20:28 UTC
Nice little tidbit about how Microsoft’s unwillingness to pay your degenerate-thief-lowlife-scumbag uncle has something even remotely to do with the article.
I used to compress my binaries
I used to use better compression on my archives
…now Videos and Music changes all that.
If they really wanted to reduce the footprint of Vista2 all they have to do is say get rid of all the bundled garbage from the OS starting with there browser, Office crapware, chat client etc etc and probably focus on improvements to performance rather than a smoke and mirrors user interface.
Microsoft didn’t impose enough restrictions on software vendors to prevent bloating the system. For example, some software will just put a huge .msi file somewhere in “installation data”. Windows generally has a very bad software management system. Result is that Windows installations degrade over time and often a reinstall is needed to get a properly working thing without all the bloat.
As if this is not bad enough, Windows itself tends to accummulate lots of garbage data, caches, logs, update backups, registry blossoming, and whatnot.
My 1 year old XP installation now boots much slower than initially for unknown reason. Bootvis revealed that it spends 40 seconds in “Disk” loading part, which should normally take 2 seconds, for no clear reason – I failed to find any diagnostic tool that could reveal what’s happening. Add to that various crapware startup tools that each app vendor feels free to add, and you get a 2-3 minute booting time.
On the other hand, I enjoy packaging systems found in Linux distributions like Fedora or Ubuntu. It’s so much simpler to update the system and add / remove whatever i need. It’s also easy to add additional repos when you need stuff that has legal problems (patented codecs etc.). The approach found in OSS feels light years ahead of the “unmanageable blob” approach of Windows.
Caches logs and backups aren’t garbage…
5 bucks says you need to defrag.
If that isn’t it, check out what is loading at startup, and what services are set to autorun with msconfig. If you can’t figure out what is taking so long, open up your logs, and see if there is anything timing out in the application log or system log. If you aren’t the kind of person that uses them, there are probably several hundred thousand entries at this point, so feel free to clear them then reboot to get a better picture of what is going on.
The entire theory of storage is cheap & memory is just ridiculous. Has anyone thought of the cluster it creates when having to do disaster recovery and the price tag on the MEGA storage backup solution???
Plus, ANY crummy operating system and application will run when you throw memory and disk storage at it.
It is easier to maintain an environment not bloated with software that requires 20G to install just the OS with no apps…
Microsoft needs to understand the concept of making software/operating systems that do not require a super computer to run them. I hate to say it but Windows Server NT 4.0 was a small installation and the OS continues to grow leaps and bounds.
In my opinion we need to get back to making applications that run on less memory and utilize less system resources. The average home user does not need to be required to purchase a machine with 4G of ram and a 1T of disk space to use a basic machine…
I really follow this idealistic idea, but I don’t think MICROS~1 will, sadly.
Systems as you suggested are very welcome to fields of use where the costs for running the machines are more important than the costs of purchasing them. Of course it’s cheap today to buy huge hard drives and tons of RAM, a fast state-of-the-art GPU, mainboard and processor. But now for the power supply and the energy consumption – I think they’ve grown more expensive than, let’s say, a 10 years old typical PC. Energy consumption is usually better on “less performant” systems (“low end stuff”), but NB that performance is not a property of hardware or software alone – it’s about the combination of both. Well written software is usable even on “low end stuff”, just have a look at the many non-“Windows” operating systems such as BeOS (and its successors), the Linusi or the UNIXes.
The tendency is this: Increase hardware power. Sell software that eats it up completely and cries for more. Sell better hardware. Sell more hungry software… you’re getting the idea. That’s what industry calls progess – selling all new stuff every few years just in order to keep the users doing the same stuff they did years before.
With today’s means, it’s relatively easy to build systems as you suggested. But that’s not the way MICROS~1 makes profit. You need to buy – you mustn’t use free products that offer better performance (and, in conclusion, better usage of the present hardware and furthermore better cost relationships). Whenever a new “Windows” comes out, you can already prepare to buy new hardware. The “old” stuff goes to the waste dump. The environment says “thank you”. So instead of creating more efficient software industry just throws mre memory and bigger disks at the customers.
My usual final take:
disk capacity + memory installed
——————————————- = usage speed = const.
OS and software requirements
The “const.” conclusion is obvious because that’s what happens if you keep increasing numerator and denominator of this quotient.
And functionality seems to increase roughly as the cube root of (disk capacity + memory installed). That’s the *real* tragedy.
Edited 2008-11-23 20:50 UTC
Indeed, my Linux powered 1.6GHz Atom Netbook (Eee 900A) feels much more sluggish than my L2 cache less 400MHz PPC (MPC5200) driven multimedia frame (a design study based on Efika 5200B) powered by MorphOS 2.x.
“One of the main problems with Windows Vista (and earlier versions) is that Windows consumes quite a lot of diskspace”
Jeez. Right now we can get 1 TB hard drives for not much more than a hundred bucks. Unless Windows take more than 50 Gigs (which is far from it), I fail to see the problem.
1.) Read the article
2.) Look for the words Netbook / SSDs
“Jeez. Right now we can get 1 TB hard drives for not much more than a hundred bucks. Unless Windows take more than 50 Gigs (which is far from it), I fail to see the problem.”
The problem lies in computers such as netbooks. If they have an SSD, then the space is a huge issue. In your scenario that is desktop computers and standard laptops. Currently SSD’s generally only come in 4-8 GB sizes. With the growth of the Netbook market, not being able to install your flagship OS as there is not enough space would be an issue, would it not?
Yes, the SSD right now is limited in size and it is a major issues if the Operating System takes up the entire disk leaving a minute amount of space for the end user.
Also, another note one has to take in the amount of space required by Microsoft Office.
Still the biggest problem is the mentality of programmers/developers that have been told disk space and memory is cheap. What happens if the price of storage and memory sky rocket as the Oil situation that brought the economy to a halt.
What happened between Windows 2000 Professional and Windows 7?
All programs/operating systems need to be written with the mentality of disk storage & memory are a premium then the performance aspects by the end user would be surpassed and any new hardware would increase performance and enable home users to have a QoS.
A typical well featured linux distro is still the same size as it was in 1998 – a single 650-700meg CD. Some quite usable compact distros are still only 50MB in total. Why the hell is Vista 8GB just for the OS alone?
Are you kidding?
Have you seen how much space band aids take up these days. With the amount of wounds windows had and has, just the scars would fill 7 gig
You must still be using Slack with Fce … Ubuntu is a pig of disk space.
Look again. Even the x86_64 version of Ubuntu still fits on, and can run from, a single CD. That’s the full version and not some cut down version. And there’s room for the installer, so the Live CD and install CD are one and the same.
Edited 2008-11-24 16:47 UTC
You are partially correct.. Except for the fact that everything on a LiveCD is compressed substancially to fit it on a CD. It can be done like this because you’re not making any changes to the core of the OS, and any new updates to it will mean a reburn of the disc. Not an issue, but figured I should point that out. Same goes for Knoppix and pretty well most LiveCDs that have that much jammed in on it.
Not to be contrary. But I said:
“””
Even the x86_64 version of Ubuntu still fits on, and can run from, a single CD. That’s the full version and not some cut down version.
“””
That is all *completely* correct and not just partially correct.
Except when you ‘install’ on a hard drive, it bloats out. So when talking about OS’ bloatness (which is what this topic is about), you’re comparing compressed to non-compressed.
Sure, it runs, but you can also enable compression on NTFS partitions. However, nobody wants to do this since it usually makes the system sluggish. It’s true that ‘some’ compressions make reads/writes faster (at the expense of CPU cycles), but usually isn’t the best compression technique out there.
Andrew,
Of course the installed image is larger than the compressed installation image; Surely any OSNews reader should recognize that implicitly without anyone having to jump in to share that startling “insight”.
Anyway, IIRC, the installed OS is about 1.5GB. Not bad at all by 2008 standards. By comparison, I believe Vista requires about “a 20GB disk with at least 15GB available free space”. About a 10 fold difference. Even with NTFS compression, you’re never going to get that within a factor of 5 of Ubuntu’s installation size. Even Windows advocates in this thread have admitted that you’d never squeeze it onto an 8GB SSD.
Edit: And why did I even bother to type all this out, anyway?
Edited 2008-11-24 21:16 UTC
That is the official requirement for home basic, which is the “We have a sub 100$ sku” edition. When you talk about vista, you are talking home premium/ultimate/business which have a 40gig requirement.
Oy vey! How many DVDs does that come on? Or perhaps it would be more interesting to consider “CD equivalents” of 700MB.
I remember, back in the day, we had a manufacturing accounting package that came in on over 50 5-1/4″ floppies. Installation was somewhat tedious, as you can imagine, and quite frustrating when they ran into bad media. Actually, it was a DOS package so I didn’t have to mess with it.
Edited 2008-11-24 21:54 UTC
I had one of the last word for macintosh versions that came on ~50 floppies. MS used some odd formatting scheme to squeeze a few extra kb out of the discs too, the downside was that it made them even more prone to error then normal floppies (which were already pretty bad). After a few months, a handful of them had errors on them (which is really fun to find out, 34 discs in). Managed to image them even though they wouldn’t install normally, and then make new copies.
Anyways, vista has a 15gig or so footprint no matter what the edition. That includes things like every usb device and printer driver that windows supports, and fonts for almost every language on earth.
But that is for install, we are not talking hibernation file, pagefile, system restore backups (which get created regularly, and are sometimes triggered by updates), shadow copy (which stores diffs of all files in the user documents at regular intervals), copious amounts of log files, registry hives, several different types of cache files, multiple different versions of the .net framework (and by extension, multiple versions of the base class library). There is also this system they introduced in xp to keep track of multiple versions of the core system files, as certain vendors liked to overwrite system libraries with their own versions.
Whats worse is the way NTFS is going, every version is more fragmentation prone. Couple that with an os that generates an astonishing amount of files, and you end up with something that needs to be defragmented and cleaned up about once a month to maintain performance.
Well, I guess the good news is that there are plenty of ways that Microsoft can innovate the size down.
Calls to mind an advertisement I was saw in a magazine in my doctor’s waiting room back when FAT32 was new. For years, of course, people who knew even the tiniest bit about filesystems knew that the huge cluster sizes required by the poor design decisions of fat12, and perpetuated by fat16, resulted in absolutely unimaginable wastefulness regarding file storage on contemporary drives. But according to the advertisement “Microsoft engineers had thought of a way (no doubt in some rarified, high-level think tank) to make computers save files in a fraction of the space they could before”.
I’ll be on the lookout for similar innovation re: the Windows 7 installation footprint. ๐
Edited 2008-11-25 00:35 UTC
So, Windows 7 will run on the crappiest of the crappiest hardware (netbooks), and now they say it will fit on a small drive. I suppose next they will announce that it will come with Microsoft Live Pony.
Anyone remember what Vista was supposed to be like and what was delivered?
Big difference is that anyone with build 6801 can test this out for themselves, as this is not something that is planned, but something that is actually done. The keynote demo of win7 at the PDC was done on a netbook.
Out of curiosity, what were the specs of the netbook?
Lenovo S10, which is a 375$ machine, and higher end in the netbook world. people have been installing build 6801 on a few different netbooks now, with results comperable to XP.
this guys installed on an Asus eee 1000h with 1.6 ghz cpu and a gig of ram http://blog.laptopmag.com/eee-pc-1000h-runs-windows-7-well his biggest issue was that 720p video didn’t run that great.
The assembly folder “winsxs” exists on Windows XP too.
Bad housekeeping has always been an issue in Windows. Actually you can use the cleanmgr.exe to do that manually.
Try the /sageset:1 and /sagerun:1 parameters where 1 is just a preset number.
You’ve never used SCO Open Server. It’s a veritable rat’s nest of symlinks. (At least they were symlinks and not hardlinks.) I never quite understood what it was that they were trying to accomplish with them. Whatever it was, I never needed it, and reveled in the simplicity and clarity of FHS when I escaped to it.
Edited 2008-11-24 15:13 UTC