Wednesday, August 12, 2009

Using Visual Studio Command-Line (devenv.com) starts failing on Setup projects with ERROR: Unrecoverable build error

I wanted to provide notice that we are currently seeing all builds failing on the build server that runs the builds via CruiseControl.NET as a domain account. Here is a write of what we know so far:

  • The errors produced by the command-line execution of Visual Studio (devenv.com) for every MSI, which state: ERROR: Unrecoverable build error
  • The issue cannot be reproduced when you log into Build Server and open the solution via Visual Studio (devenv.exe) and perform the compile.
I’ve resolved the issue. Here is the write up from a discussion I found about it:

I tried both the suggested remedy from the kb article and registering ole32.dll and still did not have success. I run devenv from the command line from my continuous integration server and one day it just started failing. No code had changed, it just started failing.

I searched all over and finally found someone in the same position that said they fixed it by deleting the user profile for the account that runs the build. I tried this today and it totally fixed the issue. Looks like MS doesn't cleanup the temp folders when running and after thousands of builds it can no longer scratch temp data to disk. I found one directory with over 65055 directories in it. lol Needless to say deleting the user profile directory took almost and hour.

So I did the following:
  • Deleted the directory: C:\Documents and Settings\\Local Settings\Temp
  • Logged in as ccnet user
  • Restarted the CruiseControl.NET service
This resolved the issue.

1 comment:

Sakthivel Rajarethinam said...

Thank you! I was scratching my head for few hours to find the issue but couldn't figure it out. I saw your blog and resolved the issue :-)

-Sakthi

There was an error in this gadget