• (cs) in reply to foxyshadis
    foxyshadis:
    Proposition: Open regmon, set it to record only writes, minimize and ignore it and go do other things. Come back a few minutes later. Note that most programs write to the registry quite a bit, explorer being the worst, but so do most document programs (most recently used lists esp.), anti-virus, anything that uses the built-in random number generator, counters in background tasks, spyware rewriting keys every x seconds, etc. There's a lot of stuff writing to the registry all the time.

    I have.  I have also used several disk-based systems that would put such a load to shame.  Of course none of them were laden with spyware, but that's hardly an argument to perpetuate such a misdesign.

    foxyshadis:
    I meant out of sync for the text files processors everyone loves (sed,grep,etc); of course the APIs wouldn't be affected, I mean, the current registry is already implemented with lazy-write journaling.

    I see what you mean.  If FS journaling couldn't handle this satisfactorily (I'm no expert), I wouldn't imagine it would be much of a problem if these changes are not reflected immediately at that level.

    foxyshadis:
    It's not the OS's problem that programs feel a need to strew shit all over the system.

    You misunderstand.  Of course I know that the OS can not control the application to this degree.  I am talking about what the OS can control -- that is, any changes that are made through its configuration API.

    foxyshadis:
    As for cryptic, most of the important registry areas are anything but, being reasonably well documented. How would you rather store all file-type settings, besides HKCR?

    For starters, how about the names "HKEY CLASSES ROOT", "HKEY LOCAL MACHINE", "HKEY CURRENT USER".  WTF.  Is "/Configuration/Classes" not clear enough?  Of course it's the root, you don't need to include that in the name!  Does the average reader here even know that "HKEY" means "Handle to Registry Key"?  Why do we even need to be introduced to the concept of a 'handle' at this point?

    Some of the WTFs on this site can be explained with documentation.  That doesn't make them any less of a WTF.

    foxyshadis:
    What would be a better way to store all services, besides HKLM/System/CCS/Services?

    /Configuration/System/Services!  WTF is the current control set anyway?  What's the difference between current, 001 and 002?

    foxyshadis:
    What would be a better way to store settings than giving everything a folder in HKLM/Software and HKCU/Software?

    Many users have already chimed in with the benefits of the OS X approach.  That's not to say it is always the best approach, however.
  • Pax (unregistered) in reply to bp

    I've seen this sort of thing before (one of Microsofts early language products) where they checked the amount of memory in the machine using a signed compare rather than unsigned.  This meant that 512K was more than the 384K required but that 640K was not enough.  Needless to say I just modified that cmp instruction but that's not really an option for the bulk of people.

    Pax.

  • byron (unregistered) in reply to Pax

    my favourite has always been "An Unexpected Error Occured".

    if the error was expected, then it wasn't an error, was it?

  • Foolhardy (unregistered) in reply to Chris F

    NT keeps track of the config keys that worked recently. It numbers them to tell them apart. The CurrentControlSet is a symbolic link to the numbered Control set that is being currently used. In the \REGISTRY\MACHINE\Select key the current, default, last known good (switched to by the F8 startup menu) and last failed control set numbers are listed. This way, if you bork your current control set and the system won't boot up anymore, you can switch to the last known good one that NT was good enough to archive for you.

    As for key names, internally the only root is \REGISTRY in the Object Manager's namespace for all named kernel objects. Win32 maps HKLM to \REGISTRY\MACHINE and HKCU to \REGISTRY\USER\[user's SID]. The HKEY* names are so long because they are global constants that need to be unique for all the header files.

    The registry dates back to the first version of NT, when a user profile consisted of a registry hive. A user might have a home directory, but otherwise there was no place to store user config information. IIRC, the registry is based on something similar that VMS has, since most of the core NT devs used to be VMS devs.

    The size savings, OTOH appear to be abysmal: I exported my HKCR key to a text .reg file and to a discrete hive. The text file is 18350KB and the binary hive is 17096KB. That's a savings of almost 7%. Not to mention that the text file compresses much better. I think the hive reserves space so that values can potentially expand without shifting, though.

    Still, breaking it up into files would certainly introduce FS overhead, including tons of wasted space in clusters. My HKCR has 78614 keys alone. One file each... that's 314MB worth of 4k clusters, and I thought my disk had too many files already. Some could be consolidated, but the CLSID key has some 10K children keys. Should they all be lumped into a gigantic text file? Either that or it's 40MB in FS clusters + MFT entries. Filesystems are meant for large files, the registry is meant for tiny entries.

    The registry provides safe concurrent updates and key level security (for example used for preventing normal users from interfering with their group policy restrictions) which would be like line-level security for a text file. I guess you could still have those things if you used a server process to arbitrate file access like the registry does (don't let apps edit files directly), at least for certain shared areas. But then, you still have the registry, it's just that the storage format has changed.

    I don't think Microsoft ever intended joe user to be editing the registry, as evidenced by the vague and dire warnings on every help page that mentions it. The HKEYs are how Win32 names them, so that's how developers/advanced users will expect them to be named.

  • (cs) in reply to Foolhardy

    I don't mean I entirely agree with the folder heiarchies; like I said, a fair bit of it could be split up or conversely linked together into a saner root key that wouldn't have so much implementation detail cruft around it. Some kind of regedit++ for fast and efficient registry hacking - I doubt MS would release that except as a powertoy since it's giving dynamite to anyone who finds it. But that's still the same thing, just structured slightly differently; the information inside is so complex and interlinked that any implementation will be complex, even if current hindsight could even out some of the bumps.

    And it is still not intended to be user-friendly. The only way it could be made so is adding extensive comments to every part of the registry, the way conf files do. (Longhorn will include "DO NOT EDIT THIS DIRECTLY" keys in many areas though, since using system APIs and letting the system update all important areas is vastly better; although I'm guilty of doing so.)

    I'd rather have a binary registry with extensive chucksums and recovery info, that the OS knew how to automatically rebuild on any kind of error, than a text file where minor corruption in the wrong area could hose the OS. (It's not really like that now - for kicks, try inverting the first bit of the registry hive, if you have a linux partition.)

  • (cs) in reply to Jon Limjap

    Jon Limjap:
    Just delete the folder?

    Yes.  It's simple and clean.

    Jon Limjap:
    I find great convenience that when I click "Uninstall" in the Add/Remove Programs control panel, it does all the deleting and unregistering for me, including the removal of all shortcuts and file associations. If you have a computer with more than one user on it, the manual way just doesn't feel right.

    I rarely have an unistall that completes everything successfully.  They always tell me that can't do this or that so stuck I'm looking around for the garbage they leave behind.  You are offering them also as a solution for unregistering which isn't necessary if you never put anything in the registry.  And why does unistalling work better for multiple users?

    But in any event, who says that you can't create an unistall routine without an installer?

    Jon Limjap:

    I've gone through the days of ARJing and PKZIPing way before Winzip came along, and I'll never go back to those days if developers make user-friendly, functional, and meaningful installers anyway.

    An installer can be a helpful thing for users.  I overstated my case a little bit.  I just think they make things more complicated that they need to be and using the registry is pointless for most applications.

  • (cs) in reply to Charles Nadolski

    Charles Nadolski:

    To add to my own post, the installer also specifies if the user can install it on the local account, or for all users.  This way settings can be copied to the user's documents and settings folder or to the general user's folder, instead of all the settings being copied to the application's folder, allowing for multiple users to use the program.  I believe I mentioned that earlier, but I may have written that unclearly, resulting perhaps in a misunderstanding :)

    You can make an application available to all users without an install.  Of course, the user doing thisl needs to have access to do that, just like an install.

  • (cs) in reply to Andy
    Anonymous:

    dubwai:

    Personally, I think installs are a big WTF.  The best installs I've ever used are zip files.  There are even self-extracting zip files for the computer-impaired.  Why do so many people think that because Windows has a registry, their software must put stuff in it.  There's probably a good reason for certain software projects but most of the software I have seen doesn't need it.

    I can only assume you've never written major enterprise level software, or shrinkwrapped mass market software.

    Why do ignorant people always assume they know everything?

    Anonymous:

    Zips are fine for techies, but it doesn't fly when your grandma wants to install a new email client,

    I don't know about your grandmother, by mine is 98 and doesn't really know what a computer is.

    Anonymous:

    or your company has 10000 desktops to autodeploy to with an SMS type tool.... Or how about services? Can't just unzip a service.... Also, a lot of software is installed in one permission mode, and run in another. The software can't assume it will be able to set up needed parts if run under a basic User permission.... Technologies like Click-Once will reduce the need for installation software, but likely we will still need something like it for some time to come....

    Zip files can contains all kinds of things, scripts for example.  You should look into scripts.  They can do a lot of cool things.

  • (cs) in reply to Halo_Four
    Anonymous:

    The registry is intended to be a centralized repository in an expected heirarchical format.  It's behavior is very predictable.  Granted, it does get abused, and fairly often, but it's very useful.  It integrates nicely with Group Policies in Active Directory to make it immediately possible for me to alter any of the 15,000 settings that come with Windows or any number of settings I can write into my own adminstrative template scripts.  In about four mouse clicks I can set that any user or computer existing in a particular organization and belonging to any particular set of security groups will have any number of individual policies applied which immediately propogate those settings.

    I think the registry is fine for Windows to use.  It's part of the OS.  I think it's a WTF for every software tool to go and set up stuff in the registry.

  • (cs) in reply to Foolhardy

    I find it ironic that people are arguing that the registry has optimizations and helps the OS start up more quickly.  Windows is one of the slowest OSs if not the slowest.  It takes forever to boot up and the once I'm 'in' I have to wait at least five more minutes before I can actually do any work (read my email, open a browser, etc.)  I have a dual boot system at home and linux blows Windows out of the water (by a long, long, shot.)

    Another, unrelated thing I don't get about Windows is why I'm unable to browse the hard-drive when it's having problems with the network.  What a genius idea.  I've got some sort of flaky network issue so I end up waiting for it to figure out which way is up for about 30 minute every day.  Our computer support says it's network latency (BS) and that I'd have to go to Mac OS or Linux to solve the problem.  Assholes.

  • Sven2 (unregistered) in reply to dubwai
    dubwai:

    I find it ironic that people are arguing that the registry has optimizations and helps the OS start up more quickly.  Windows is one of the slowest OSs if not the slowest.  It takes forever to boot up and the once I'm 'in' I have to wait at least five more minutes before I can actually do any work (read my email, open a browser, etc.)  I have a dual boot system at home and linux blows Windows out of the water (by a long, long, shot.)


    I just rebooted and timed it: 45 seconds from until the logon screen; then another 12 seconds until my desktop was there and fully functional. And that includes virus scanner and tablet driver startup time - otherwise, it's just a regular WinXP Home installation which came with the laptop. I disabled a few services I never/rarely need; but I didn't apply any "tweaking" tools or stuff like that. But then, I don't have an animated desktop plant either :'(

    But even if your startup times are true for joe user: Imagine Windows had a slower solution than the registry for reading the zillions of config strings it needs to have so it knows whether the login button must be round or rectangular, or which spamware is to be loaded first. Then the slowest OS in the world, as you state it, would startup even slower? :)
  • (cs) in reply to dubwai
    dubwai:

    It takes forever to boot up and the once I'm 'in' I have to wait at least five more minutes before I can actually do any work (read my email, open a browser, etc.)  I have a dual boot system at home and linux blows Windows out of the water (by a long, long, shot.)

    I noticed you left out which version of Windows you are using.  Was that on purpose?  It takes between 15 and 25 seconds for Windows XP to get to a usable state for me. That includes my work and home PCs.  

    Between the time you push the power button and the time you start to work, your computer goes through several steps, such as initializing the basic input/output system (BIOS), loading the operating system, initializing devices, and prompting you to log on with a password. Windows XP speeds up these steps so that in many cases your computer will be ready to work in 30 seconds or less.

    Emphasis mine.

    Rearranging the code and data needed to start your system. After you start your computer with the same hardware and software a few times, Windows XP moves the files for startup to the most efficient place on the hard disk for faster access.

    Both quotes taken from http://www.microsoft.com/windowsxp/evaluation/features/fastlogon.mspx

  • Sven2 (unregistered) in reply to Sven2

    By the way, since we're getting off the topic. Here I have some dialog I encountered:

    [image]

    And no, I do not have a 1024 bit processor ;)

  • Sven2 (unregistered) in reply to Sven2

    Here it is:

    http://www.goldwipf.de/misc/PCv3.png

    [image]

  • (cs) in reply to RyGuy
    RyGuy:
    dubwai:

    It takes forever to boot up and the once I'm 'in' I have to wait at least five more minutes before I can actually do any work (read my email, open a browser, etc.)  I have a dual boot system at home and linux blows Windows out of the water (by a long, long, shot.)

    I noticed you left out which version of Windows you are using.  Was that on purpose?  It takes between 15 and 25 seconds for Windows XP to get to a usable state for me. That includes my work and home PCs.  

    Windows XP.

    RyGuy:
    Between the time you push the power button and the time you start to work, your computer goes through several steps, such as initializing the basic input/output system (BIOS), loading the operating system, initializing devices, and prompting you to log on with a password. Windows XP speeds up these steps so that in many cases your computer will be ready to work in 30 seconds or less.

    Emphasis mine.

    I often go get breakfast while my computer boots up.

    RyGuy:
    Rearranging the code and data needed to start your system. After you start your computer with the same hardware and software a few times, Windows XP moves the files for startup to the most efficient place on the hard disk for faster access.

    Both quotes taken from http://www.microsoft.com/windowsxp/evaluation/features/fastlogon.mspx

    That's great that their advertising says it 's fast.  What about actual results?

  • (cs) in reply to RyGuy

    RyGuy:
    I noticed you left out which version of Windows you are using.  Was that on purpose?  It takes between 15 and 25 seconds for Windows XP to get to a usable state for me. That includes my work and home PCs. 

    Interestingly enough, I have an old crappy version of windows at home and it loads and boots much faster than my work version.  Of course, it's on different hardware.  On the dual boot, the linux version takes longer to get to the login screen but once you've gotten there, it's ready to go.  Windows looks ready but throws up an hourglass.

    Are you saying that from the moment you push the power button, to when you use it, it takes 15 seconds?  The boot splash takes up a good portion of that on my work machine.

    They other annoying thing about Windows is that I cannot take my machine home and plug it into the network with a cold reboot.  It goes nuts and I have to kill the power if I try.  I just don't think it's good quality software.  It just seems like a huge hack under a pretty façade.

  • (cs)
    Alex Papadimoulis:

    The user might not know the answer, but at least he passed the test [:P]

  • (cs) in reply to dubwai
    dubwai:

    I just don't think it's good quality software.  It just seems like a huge hack under a pretty façade.



    That's what I've always thought of Windows too. On my dual boot machine Windows takes over 30 seconds longer before I can do stuff than on Linux. You get this false sense that Windows is quicker because it throws up the login screen first but it is just kidding you, it still has LOADS more thrashing to do before it will even think of doing what you want!

    Windows really is sub-standard software and I don't understand why people use it at all. If you are scared by Linux and have no issue with paying for software then use OS X, it makes Windows look positively difficult to use and it just works which is much more than I can say for windows. Also, Linux is not like it used to be, I installed two differnt distros over the weekend and both were easier to install than Windows (Ubuntu & Fedora Core 4).  In fact the  FC 4 installer would serve as a good example to Windows!

    Anyhow, to get remotely back on topic, it is so easy when coding to bodge the error messages because lets face it, we all expect our code to be perfect and hence the errors never to be seen! Also, the sign of a good error message is when google can solve your problem based on the message. Happened me today with a Java + PostgreSQL error and it really made my day!
  • Disgruntled DBA (unregistered) in reply to deathz0rz
    Anonymous:
    actually, 'bladeren' means 'browse'


    So it is not related to the word for "to bluff" which is "to blave"?
  • (cs) in reply to Disgruntled DBA

    this thread is a WTF. Sort of takes thread hijacking to a new level.. I normally love the pop-up potpourii type threads, but this one needs to be pruned. Reminds me of listening to 2 geeks rattling off about Microsoft vs Linux.

  • (cs) in reply to drew

    drew:
    this thread is a WTF. Sort of takes thread hijacking to a new level.. I normally love the pop-up potpourii type threads, but this one needs to be pruned. Reminds me of listening to 2 geeks rattling off about Microsoft vs Linux.

    Yeah, why would you expect to find geeks here? [8-)]

  • (cs) in reply to Disgruntled DBA

    Anonymous:
    Anonymous:
    actually, 'bladeren' means 'browse'


    So it is not related to the word for "to bluff" which is "to blave"?

    Would that be the Princess Bride?

  • (cs) in reply to Chris F

    Chris F:
    For starters, how about the names "HKEY CLASSES ROOT", "HKEY LOCAL MACHINE", "HKEY CURRENT USER".  WTF.  Is "/Configuration/Classes" not clear enough?  Of course it's the root, you don't need to include that in the name!  Does the average reader here even know that "HKEY" means "Handle to Registry Key"?  Why do we even need to be introduced to the concept of a 'handle' at this point?

    The reason they are called handles, is because the API takes a root handle and accesses it through that:

    From a VBScript I Wrote:


    Const HKLM = &H80000002
    Set REG = GetObject("winmgmts:{impersonationLevel=impersonate}!\\localhost\root\default:StdRegProv")
    REG.GetStringValue HKLM, "SOFTWARE\Valve\Steam", "InstallPath", DIRSteam

  • mikeyd (unregistered) in reply to Simon

    How does that system allow per-user configuration? Are your settings stored in your home folder? If so, how do you prevent using the config from an incompatible version?

  • (cs)

    I've always liked the browser (Netscape-family only?) error message that says (approximately):

    404 File Not Found.
    Additionally, a File Not Found error was encountered while trying to use an ErrorDocument to handle the request.

    I always think to myself that it should also say:

    Also, the webmaster is incompetent.
    Not only that, but this hardware is too slow.
    And your mother dresses you funny.

  • (cs) in reply to stevekj

    That ErrorDocument error message is an Apache error message - not browser-specific, web-server-specific.

  • ultraobscene01 (unregistered) in reply to Maurits

    I got this error when I first started my IT Help Desk position way back when...

     

    [image]
  • Anonymous (unregistered) in reply to ultraobscene01

    Could you imaging the nightmare working with non-cached roaming profiles if the registry was stored in thousands of files?

  • (cs) in reply to Anonymous
    Anonymous:
    Could you imaging the nightmare working with non-cached roaming profiles if the registry was stored in thousands of files?

    Well, no.  Unix guys have had networked user-scoped configuration for decades now.  I wonder how they accomplished such incredible tasks with hardware that was orders of magnitude less capable?
  • (cs) in reply to Chris F

    I get this wierd error message on one of my computers when i turn it off (and thus I cant take screenshots). svchost.exe tries to read on memory 00000000000000000x0 (somethng like that) and is forcibly closed. I like that message.

    And, the same machine booted in 10 seconds from power on to desktop (completely loaded) when it had an fresh install. Now its more like a minute. Noticed this tendency on every single install of windows I've ever had. And, no, its not spyware/viruses as I'm pretty well protected from such stuff.

  • The MAZZTer (unregistered) in reply to Ulvhamne

    Well, when I did a fresh install of XP on this machine, I noticed it was ALOT faster.  When I patched it to SP2, guess what happened. :D

  • (cs) in reply to The MAZZTer

    Anonymous:
    Well, when I did a fresh install of XP on this machine, I noticed it was ALOT faster.  When I patched it to SP2, guess what happened. :D

     

    It boots even faster? Like greased Lightning? Hehe.

  • (cs) in reply to Ulvhamne

    The error messages of my old SWI-PROLOG application always stuck with me. If you managed to create an infinite loop and crash the program, it would often give the error :

    "Error.....the answer to your question is 42 !" [:D]

    The most intriguing one I ever found was when my program was starting to show really wierd behaviour and I paused it and requested its current evaulation targets. Among the targets I expected there was one very wierd one :

    "Researching alien goal" [^o)]

    That's the kind of freaky thing that makes you look over your shoulder if you're being watched

    Cheers,

    Lodewijk

     

  • QQ (unregistered) in reply to lgonggr

    Sorry for offtopic, but..

    I can see why registry would be a good thing in enterprises with loads of pcs, remote administration, automated installs and yadda yadda. But what always bugs me the most is the fact, that I install application A, spend 2 hours configuring it to my taste, then some few years later reinstall/move, I can't just take the settings with myself.. i have to waste time again! Apps which keep settings in files in their dirs, well, they can be just copied and they work fine! And yeah, i guess I could try copying registry branches, but don't we all know that apps scatter stuff around, and furthermore, you could end up transferring some installation dependent stuff which was never meant to be in the new installation.. meh   

  • (cs) in reply to Ulvhamne

    <font size="4">1 ?- AnswerToLifeTheUniverseAndEverything.
    % ... 1,000,000 ............ 10,000,000 years later
    %
    %       >> 42 << (last release gives the question)
    </font>
    This was done using SWI-Prolog 5.4.2. I don't know if a "greatly improved" version has been released yet. Or maybe they refer to the SWI-Prolog release at the end of the universe?

  • heiopei (unregistered) in reply to joost
    joost:
    1 ?- AnswerToLifeTheUniverseAndEverything. % ... 1,000,000 ............ 10,000,000 years later % %       >> 42 << (last release gives the question)

    This was done using SWI-Prolog 5.4.2. I don't know if a "greatly improved" version has been released yet. Or maybe they refer to the SWI-Prolog release at the end of the universe?

    same here

Leave a comment on “A Pop-Up Potpourii Redux”

Log In or post as a guest

Replying to comment #:

« Return to Article