Archive

Archive for 2010

November 18th, 2010 1 comment

For quite some time now, it has happened to me occasionally that attaching the debugger to the w3wp.exe (IIS worker process) to debug a web application gets extremely slow. I’m talking about several minutes to load all the symbols before it could actually start debugging. In the VS status bar you could see that it took about 1 second for each assembly to load – and we’ve got LOTs of them. In the past, the problem usually went away by itself after a reboot or some other Windows “feature”. This week however it just didn’t get any better. After some Googleing I now think that I have found the solution to the problem: simply delete ALL breakpoints and set a couple of new ones. Don’t ask me how or why exactly, but it seems to be quite reliable.

Categories: Tags:

Increase Memory for Visual Studio 2008

I often get an Not enough storage is available to complete this operation Error when compiling a large Solution. By storage they mean Memory (RAM) in fact.
Visual Studio is limited by how much RAM it will use but theres a trick to increase the Memory it will use.

Quick HowTo:
1.
Windows xp: backup the boot.ini file and then put the /3gb switch in your boot.ini.
Windows Vista: run the following from the visual studio command prompt:
bcdedit /set increaseuserva 3072

2.
- be sure to backup devenv.exe
- using the visual studio command prompt, navigate to c:\program files\microsoft visual studio 9\common7\ide\
- execute the following command:
editbin /largeaddressaware devenv.exe

Here’s the Link to the original entry:

http://stevenharman.net/blog/archive/2008/04/29/hacking-visual-studio-to-use-more-than-2gigabytes-of-memory.aspx

Categories: Tags:

Win7 Boot from VHD – Part II

To install Windows 7 on a virtual disk, follow these instructions.

• Boot from the Windows 7 installation disc
• Press SHIFT+F10 to open the command prompt
• Start diskpart.exe
• If you already haven’t already created a vdisk that you would like to install Win7 on, create one (see previous post)
• Attach the virtual disk

> select vdisk file="C:\path\to\vhd" > attach vdisk > exit

• Continue with the installation by selecting “Custom Install”
• Select the virtual disk (if you have formatted and named your disk, you will see that name now, otherwise you will have to consider the disk size)
• Install Windows 7

The installer will create a boot menu entry for your new Windows installation and your existing non-virtual installation. Unfortunately, they are (by default) both called “Windows 7″. Very helpful… The virtual installation will be the first entry in your boot menu and started by default. Once your installation is complete, you can fix this issue with the “bcdedit.exe” command line tool.

> bcdedit.exe

This will give you a list of all boot manager entries. Find the one that refers to your VHD file and copy it’s ID – {current} if you are currently running your virtual installation and usually {default} if you’re running the physical installation.

> bcdedit.exe /set description "New boot menu entry"

You can also create copies of your bood menu entries and adjust them to, let’s say, point to a different VHD file.