Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VisualStudio2013Premium may require a reboot before continuing installation #30

Open
icnocop opened this issue Dec 15, 2015 · 5 comments

Comments

@icnocop
Copy link

icnocop commented Dec 15, 2015

Hi.

Thank you for Chocolatey and VisualStudio2013Premium.

Windows Server 2012 R2 Standard
Chocolatey 0.9.9.11

When installing Visual Studio 2013 Premium, vs_premium_download.exe may return an exit code of -2147185721 indicating that a Restart is required before installation can continue.
See https://msdn.microsoft.com/en-us/library/ee225238(v=vs.120).aspx.

For example:
cinst VisualStudio2013Premium -InstallArguments "/Features:'WindowsPhone80'" -y

chocolatey.log (snippet):

2015-12-15 11:58:20,560 [INFO ] -  Installing VisualStudio2013Premium...
2015-12-15 12:27:55,625 [ERROR] -  [ERROR] Running C:\Users\ADMINI~1\AppData\Local\Temp\chocolatey\VisualStudio201
2015-12-15 12:27:55,749 [ERROR] -  3Premium\12.0.40629.20150920\VisualStudio2013PremiumInstall.exe with /Passive 
2015-12-15 12:27:55,749 [ERROR] -  /NoRestart /AdminFile C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Too
2015-12-15 12:27:55,749 [ERROR] -  ls\AdminDeployment.xml /Log C:\Users\ADMINI~1\AppData\Local\Temp\vs.log  was 
2015-12-15 12:27:55,749 [ERROR] -  not successful. Exit code was '-2147185721' Error Message: 
2015-12-15 12:27:55,749 [ERROR] -  .
2015-12-15 12:27:55,749 [ERROR] -  At C:\ProgramData\chocolatey\helpers\functions\Start-ChocolateyProcessAsAdmin.p
2015-12-15 12:27:55,749 [ERROR] -  s1:92 char:5
2015-12-15 12:27:55,749 [ERROR] -  +     throw $errorMessage
2015-12-15 12:27:55,749 [ERROR] -  +     ~~~~~~~~~~~~~~~~~~~
2015-12-15 12:27:55,749 [ERROR] -      + CategoryInfo          : OperationStopped: ([ERROR] Running...or Message: 
2015-12-15 12:27:55,749 [ERROR] -  .:String) [], RuntimeException
2015-12-15 12:27:55,749 [ERROR] -      + FullyQualifiedErrorId : [ERROR] Running C:\Users\ADMINI~1\AppData\Local\ 
2015-12-15 12:27:55,749 [ERROR] -     Temp\chocolatey\VisualStudio2013Premium\12.0.40629.20150920\VisualStudio20  
2015-12-15 12:27:55,749 [ERROR] -    13PremiumInstall.exe with /Passive /NoRestart /AdminFile C:\ProgramData\ch   
2015-12-15 12:27:55,749 [ERROR] -   ocolatey\lib\VisualStudio2013Premium\Tools\AdminDeployment.xml /Log C:\Use    
2015-12-15 12:27:55,749 [ERROR] -  rs\ADMINI~1\AppData\Local\Temp\vs.log  was not successful. Exit code was '    
2015-12-15 12:27:55,749 [ERROR] -  -2147185721' Error Message: 
2015-12-15 12:27:55,749 [ERROR] -  .
2015-12-15 12:27:55,937 [DEBUG] - Command ['"C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -NoProfile -NoLogo -ExecutionPolicy Bypass -Command "[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Tools\ChocolateyInstall.ps1' -installArguments '/Features:'WindowsPhone80'' -packageParameters ''"'] exited with '1'
2015-12-15 12:27:55,953 [DEBUG] - Calling command ['"shutdown" /a']
2015-12-15 12:27:56,000 [DEBUG] - Command ['"shutdown" /a'] exited with '1116'
2015-12-15 12:27:56,046 [DEBUG] - Capturing package files in 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium'
2015-12-15 12:27:56,046 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\VisualStudio2013Premium.nupkg'
  with checksum '9E64A94A5425B2A39197648692E78AF2'
2015-12-15 12:27:56,046 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\vs.png'
  with checksum 'F437DC89537F91BF3E1363CECE11514E'
2015-12-15 12:27:56,046 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Tools\AdminDeployment.xml'
  with checksum '1B952ABDDDDFD2281B46A4B381CF6D75'
2015-12-15 12:27:56,046 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Tools\ChocolateyInstall.ps1'
  with checksum 'EB801D2B83DDBFCD8081163036AA04F6'
2015-12-15 12:27:56,046 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Tools\ChocolateyUninstall.ps1'
  with checksum '7D78BD987B13788045D68CFC6100F8E2'
2015-12-15 12:27:56,046 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Tools\common.ps1'
  with checksum 'CAD2FE3515E9D169FA58CD3ECC49A900'
2015-12-15 12:27:56,046 [DEBUG] - Attempting to create directory "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920".
2015-12-15 12:27:56,249 [DEBUG] - Attempting to copy "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.registry.update"
 to "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.registry".
2015-12-15 12:27:56,249 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.registry.update".
2015-12-15 12:27:56,249 [DEBUG] - Attempting to copy "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.files.update"
 to "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.files".
2015-12-15 12:27:56,281 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.files.update".
2015-12-15 12:27:56,281 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.sxs".
2015-12-15 12:27:56,281 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\VisualStudio2013Premium.12.0.40629.20150920\.pin".
2015-12-15 12:27:56,281 [ERROR] - The install of visualstudio2013premium was NOT successful.
2015-12-15 12:27:56,281 [ERROR] - Error while running 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium\Tools\ChocolateyInstall.ps1'.
 See log for details.
2015-12-15 12:27:56,281 [DEBUG] - Attempting to create directory "C:\ProgramData\chocolatey\lib-bad".
2015-12-15 12:27:56,281 [DEBUG] - Moving 'C:\ProgramData\chocolatey\lib\VisualStudio2013Premium'
 to 'C:\ProgramData\chocolatey\lib-bad\VisualStudio2013Premium'
2015-12-15 12:27:58,312 [WARN ] - 
Chocolatey installed 1/2 package(s). 1 package(s) failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
2015-12-15 12:27:58,312 [ERROR] - Failures:
2015-12-15 12:27:58,343 [ERROR] -  - visualstudio2013premium
2015-12-15 12:27:58,343 [DEBUG] - Exiting with 1

vs.log (snippet):

[04A8:0754][2015-12-15T12:27:53]i000: MUX:  Exit with 0x80048BC7 (Incomplete and reboot required)
[04A8:0260][2015-12-15T12:27:54]i500: Shutting down, exit code: 0x80048bc7
...
[04A8:0260][2015-12-15T12:27:54]i007: Exit code: 0x80048bc7, restarting: No

I didn't expect cinst to exit with code 1.

Thank you.

@mwrock
Copy link
Owner

mwrock commented Dec 16, 2015

yeah. thats a tough one because its unlike 3010 where a restart is required after install and before use. In this case the machine must be restarted and then you need to invoke the installer again. Otherwise VS simply is not installed. There is really no way around that when adding the winphone emulation. You might try something like boxstarter which I wrote to address these kinds of issues. It will detect that code and reboot thae machine, log you back in and then rerun the package.

@icnocop
Copy link
Author

icnocop commented Dec 16, 2015

Thank you.

Should that exit code be added as a valid exit code then?

-validExitCodes @(0, 3010, -2147185721)

@mwrock
Copy link
Owner

mwrock commented Dec 16, 2015

I don't think so or the install will never finish. It will see that exit code and then consider itself successful. I suppose you could then run a forced cinst on the package a second time to complete the install. However, I think the failure is better otherwise a user is mislead into thinking the install has completed.

@icnocop
Copy link
Author

icnocop commented Dec 16, 2015

Thank you.

I will test it with Boxstarter.

@tunisiano187
Copy link

Maybe this issue can be closed no ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants