Registry setting keeps Windows from wigging out when you open lots of IE7 tabs - Jon Galloway

Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

Should I freak out nowSummary

Opening too many tabs in Internet Explorer 7 can cause the Windows shell to switch to "Evil Mode". Fortunately, there's a registry setting that fixes the problem by increasing the Windows heap size.

The Problem

Internet Explorer starts to go nuts when you open a lot of tabs. Jeff Atwood wrote that he started to see problems when he had IE 45 tabs open:

When researching blog posts, I tend to open a lot of browser windows and tabs. At least twice per week, I have so many browsers and tabs open that I run into some internal limitation of the browser and I can't open any more. My system gets a little wonky in this state, too: right-clicking no longer shows a menu, and I'm prevented from launching other applications. But if I close a few errant browser windows or tabs, everything goes back to normal.

I've hit this problem regularly in both Windows XP and Vista - when I open a lot of tabs in IE7, weird things start happening. While IE and File Explorer are no longer integrated beyond sharing some base DLL's, the problems caused by opening too many IE tabs will affect File Explorer and the rest of the Windows shell.

Some of the problems I'd see:

  • The context menus in File Explorer are missing a lot of options or don't display at all
  • Programs will fail to open when you double-click on a shortcut
  • The Start Menu doesn't open
  • General malaise

Closing tabs or windows seemed to help the problem, but sometimes the only solution was a reboot. That was especially annoying for me, as I tend to leave my computers running for month and have been known to have multitudes of tabs open for weeks on end.

EnableEvilMode=false

Fortunately a comment on Jeff's blog points to a solution in Ed Bott's blog: Increase the size of the Desktop Heap. Like a lot of software problems, this one is hard to figure out until you know what's causing it. Once you know the cause, it all kind of makes sense and it's easy to find out more. Sure enough, Kevin Dente wrote about this exact problem under Windows XP almost 4 years ago:

According to a somewhat dated but still relevant MS KB article, “this static value is used to prevent ill- behaved applications from consuming too many resources”. Well, apparently it IE meets the “ill-behaved” criteria, because it seemed to cause Windows to bump into this limit, and Windows wasn’t handling it very gracefully. Anyway, to make a long story longer, when I bumped up the desktop heap size (from its default of 3MB up to 8MB), bingo, all of the problems magically disappeared. Whew, what a relief.

To make this change, navigate regedit to HKEY_LOCAL_MACHINE\\System\\CurrentControlSet\\Control\\Session Manager\\SubSystems. The “Windows” value contains a big honkin’ string, and one part of it is “SharedSection=xxxx,yyyy,zzzz”. The second number (yyyy) is the one that you want to increase.

I usually provide the text for a REG file whenever I recommend a registry change, but because this is smack dab in the middle of a long, complex string it's only you'll have to take care of manually. The good news is that I've tested this for months on three Windows machines (2 Vista, one XP) and it's worked great.

If you're interested in understanding exactly what the Shared Section of the Desktop Heap has to do with IE tabs and the Windows Wonkiness (a technical term), there's more information on the NT Debugging blog.

Published Monday, January 14, 2008 11:49 PM by Jon Galloway

Comments

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

Also not an issue in 64-bit Vista, as 64-bit editions have a much larger desktop heap by default.

Have I mentioned how much I like 64-bit Vista? It Just Works.

Tuesday, January 15, 2008 3:53 AM by Jeff Atwood

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

Awesome!  Thanks for sharing, I also tend to have many many tabs open for weeks on end.  Now if only you'd fix your blog so that I would quit getting this login dialog from some pubs.hiddennetwork each and every time the page loads.

LMAO @ Atwood (It just works)

Tuesday, January 15, 2008 9:17 AM by Josh Stodola

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

It's crazy how quickly some machines run into this problem - as few as 8 or 9 tabs on one of my machines.

Tuesday, January 15, 2008 3:14 PM by kevindente

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

In case you didn't think anyone noticed that you haven't posted 3 times this week...well, I have.

I like your stuff, Jon -- more!

Saturday, January 19, 2008 1:10 AM by Matt

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

Does anyone know how to increase the number of Home Page tabs to higher than the 8 that is allowed by IE7?

I am used to having about double that able to open automatically in IE6 after installing MSN8.5, I think it is.

Tuesday, January 29, 2008 5:38 PM by Cindy

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

This issue pre-dates XP - it also affected NT4.

Symptoms were the same - starting an application resulted in a new process but no new window, menus wouldn't appear etc.

Tuesday, May 20, 2008 5:33 PM by Peter

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

OK, I have looked at this registry file, but am curious what number you put for "The second number (yyyy) is the one that you want to increase."

Just want to make sure I put the right info...

Sunday, June 8, 2008 12:27 AM by Chantili

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

I have this problem but do not have this listed in registty

no Shared section when I get to the subsystem

HKEY_LOCAL_MACHINE\\System\\CurrentControlSet\\Control\\Session Manager\\SubSystems

Please help

Monday, July 21, 2008 5:19 PM by Rietveld

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

I* never had this problem until I did a clean install of XP home. Now I have the problem with only 5 tabs only. Went to do the registry fix but I donot have the shared section listed when I go to HKEY_LOCAL_MACHINE\\System\\CurrentControlSet\\Control\\Session Manager\\SubSystems

Monday, July 21, 2008 5:25 PM by rietveldg

# re: Registry setting keeps Windows from wigging out when you open lots of IE7 tabs

When you get to subsystems don't expand it, just click on it and you will see in the right window:

Default

Debug

Kmode

Optional

Posix

Required

Windows

and Windows is the one to double click on to get the values you want to change.  That second value works well at 8MB (8192) as Jon stated. As follows

%SystemRoot%\system32\csrss.exe ObjectDirectory=\Windows SharedSection=1024,8192,512 Windows=On SubSystemType=Windows ServerDll=basesrv,1 ServerDll=winsrv:UserServerDllInitialization,3 ServerDll=winsrv:ConServerDllInitialization,2 ProfileControl=Off MaxRequestThreads=16

Friday, October 2, 2009 10:36 AM by Doug Jones