none
Unable to install SQL Server (setup.exe), VS Shell installation has failed with exit code 1638.

    Question

  • Detail:

    (01) 2017-10-19 02:14:41 Slp: Log provider 'Microsoft.SqlServer.Chainer.Infrastructure.LogProviderFile' has been registered
    (01) 2017-10-19 02:14:41 Slp: Log provider 'Microsoft.SqlServer.Chainer.Infrastructure.LogProviderConsole' has been registered
    (01) 2017-10-19 02:14:41 Slp: Log provider 'Microsoft.SqlServer.Chainer.Infrastructure.LogProviderStatus' has been registered
    (01) 2017-10-19 02:14:41 Slp: Reading XML resource 'Microsoft.SQL.Chainer.PackageData.Package.xml'
    (01) 2017-10-19 02:14:41 Slp: Reading schema resource 'Microsoft.SQL.Chainer.Package.Package.xsd'
    (01) 2017-10-19 02:14:41 Slp: Document 'Microsoft.SQL.Chainer.PackageData.Package.xml' validated with schema 'Microsoft.SQL.Chainer.Package.Package.xsd' has been successfuly loaded into datastore path '/Datastore/Package'
    (01) 2017-10-19 02:14:41 Slp: ----------------------------------------------------------------------
    (01) 2017-10-19 02:14:41 Slp: Running Action: ReadProductXML
    (01) 2017-10-19 02:14:41 Slp: Reading XML resource 'Microsoft.SQL.Chainer.Product.Product.xml'
    (01) 2017-10-19 02:14:41 Slp: Document 'Microsoft.SQL.Chainer.Product.Product.xml' validated with schema 'Microsoft.SQL.Chainer.Product.Product.xsd' has been successfuly loaded into datastore path '/Datastore/Product'
    (01) 2017-10-19 02:14:41 Slp: Completed Action: ReadProductXML, returned True
    (01) 2017-10-19 02:14:41 Slp: ----------------------------------------------------------------------
    (01) 2017-10-19 02:14:41 Slp: Running Action: LoadExtensions
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'MSI' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.MsiExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'MSI' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'Config' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.ConfigExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'Config' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'Common' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Chainer.ExtensionCommon.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'Common' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'SqlConfigBase' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.SqlConfigBase.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'SqlConfigBase' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'Slp' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.SetupExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'Slp' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'RulesEngine' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.RulesEngineExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'RulesEngine' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'WorkflowData' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Chainer.WorkflowData.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'WorkflowData' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'SlpConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.SlpExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'SlpConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'Clst' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.Cluster.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'Clst' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'AgentConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.AgentExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'AgentConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'SqlPowershellConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.PowershellExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'SqlPowershellConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'SSISConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.SSISExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'SSISConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'ISMasterConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.ISMasterExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'ISMasterConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'ISWorkerConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.ISWorkerExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'ISWorkerConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'DReplayConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.DistributedReplayExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'DReplayConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'ASConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.ASExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'ASConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'ReplConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.Repl_ConfigExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'ReplConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'ManagementToolsConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.ManagementToolsExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'ManagementToolsConfig' version '14.0.1000.169' loaded
    (01) 2017-10-19 02:14:42 Slp: Loading extension 'ManagementToolsAdvancedConfig' from file 'C:\Program Files\Microsoft SQL Server\140\Setup Bootstrap\SQL2017\x64\.\Microsoft.SqlServer.Configuration.ManagementToolsExtension.dll'
    (01) 2017-10-19 02:14:42 Slp: Extension 'ManagementToolsAdvancedConfig' version '14.0.1000.169' loaded

    Wednesday, October 18, 2017 7:21 PM

All replies

  • Hi Venandyka,

     

    The exit code 1638 means "Another version of this program is already installed", this error message is provided by Windows Installer, please check if you have installed other later version of VS Shell on your machine.

     

    Besides, have you installed Visual Studio 2017 on your machine? Based on my experience, this can also affect the installation of SQL Server 2017. The version of VS Shell inside some versions of Visual Studio 2017 is later than the VS Shell inside SQL Server, as a result, you will meet this problem, please check it.

     

    As a workaround for it, you can first uninstall Visual Studio 2017, then install SQL Server 2017, after that, install Visual Studio 2017 again.

    Best Regards,

    Teige

     


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, October 19, 2017 6:13 AM
    Moderator
  • Please check the LOG. I have the same issue (VS SHELL), but checking the log file I found that I have

    Microsoft Visual C++ 2017 and 2012, NOT 2015

    Uninstall 2017 and install 2015 and after 2017.

    After these operations you can install SQL Server.

    • Proposed as answer by DeepaSoman Saturday, December 30, 2017 3:58 AM
    Wednesday, October 25, 2017 1:01 PM
  • The problem is likely that there's a newer version of the Visual C++ Redistributable than SQL Server is trying to install, e.g., from Visual Studio 2017. So another way to address this, if you don't need the latest C++ redistributable, is to go to Add or Remove Programs and uninstall all references to Visual C++ 2017 Redistributable. After this, the SQL Server installation should proceed without errors.
    • Proposed as answer by IdleHands Thursday, October 26, 2017 4:40 PM
    Wednesday, October 25, 2017 5:43 PM
  • Sorry, I got the same problem, I uninstall my Visual Studio 2017, but still, I have the same error "VS Shell installation has failed with exit code". Any other idea?

    I would really appreciate if there is something else I can do

    Thursday, October 26, 2017 3:50 AM
  • I just fixed this issue because of this thread. I uninstalled 2 references to Visual C++ 2017 Redistributable from Add/Remove Programs. I've tried a million things, but that finally worked!
     Thanks @IdleHands!
    • Edited by messenjahofchrist Saturday, October 28, 2017 3:59 PM
    • Proposed as answer by Ichi.S Tuesday, June 12, 2018 1:28 AM
    • Unproposed as answer by Ichi.S Tuesday, June 12, 2018 1:28 AM
    • Proposed as answer by Ratatouile Saturday, July 21, 2018 10:57 PM
    Saturday, October 28, 2017 3:58 PM
  • Excelente, fue lo que me funcionó, busque y busque y  lo  mejor fue esta respuesta. 

     uninstalled 2 references to Visual C++ 2017 Redistributable from Add/Remove Programs

    Monday, October 30, 2017 6:00 PM
  • Thanks! This helped me install SQL Server 2017 on my machine.
    Saturday, December 30, 2017 3:56 AM
  • Perfect! As you described to us. SQL Express Setup succeeded! Big thank you! 
    Monday, January 8, 2018 4:23 PM
  • Perfect solution i have uninstalled both microsoft visual c++ Redistributable 2017 x86 and x64 after that every thing installed fine, and after installation i installed redistibutable again
    Tuesday, January 9, 2018 9:02 AM
  • I'm glad to see a work-around that works for everyone, but I hardly call it a solution.  SQL Server should just handle this, it is completely ridiculous to even need to uninstall VS 2017 C++ redist.  This is an embarrassing way to "fix" SQL installation, Microsoft.
    Monday, March 5, 2018 6:17 PM
  • We can just repair this, don't need to remove. It says that something was wrong on the installation of visual studio, very common with VS2017
    Thursday, March 8, 2018 9:17 PM
  • Thank you.

    this one worked perfect for me.

    SQLSERVER 2017

    Wednesday, April 4, 2018 10:03 AM
  • Thanks ... i did the same thing as well and it worked. 
    Sunday, April 22, 2018 9:15 AM
  • Just uninstalling Microsoft Visual C++ 2017 was enough for me.
    • Edited by Scott421 Saturday, May 19, 2018 5:57 PM added version of C++
    Saturday, May 19, 2018 5:57 PM
  • Yes this fixed my installation issue. Thanks

    Suresh

    Friday, June 8, 2018 4:08 AM
  • This helped me as well
    Monday, June 25, 2018 2:31 PM
  • I did some further investigation and it turns out (more specifically) the c++ dev environment was already installed. Microsoft Visual C++ (year) Redistributable. So yes, un-installing Visual Studio, then installing SQL server, then re-installing Visual Studio should do.
    Tuesday, July 10, 2018 9:57 AM
  • Yes, it worked! Thanks for sharing!
    Tuesday, July 17, 2018 4:38 AM
  • Thank you so much. uninstalling the two files you mentioned solved the installation issue
    Wednesday, August 8, 2018 9:46 AM
  • This worked for me. 
    Thursday, August 9, 2018 4:46 PM
  • This worked for me.
    Friday, August 10, 2018 12:01 PM
  • repair solved our problem you don't need to uninstall.
    Monday, September 17, 2018 3:13 PM
  • I just replaced installations file of the c++ 2015 by new one with same names from 

    https://visualstudio.microsoft.com/downloads/

    (look in Other Tools and Frameworks/Microsoft Visual C++ Redistributable for Visual Studio 2017).

    And it worked for me.

    


    Wut?


    Tuesday, September 25, 2018 9:56 AM
  • Teige,

    I am not happy with the proposed answer.  

    WHY

    VS 2017 takes about two hours to install and the same to uninstall.  SQL Server 2017 is ten to fifteen minutes if the only part of the installation is the Database Engine.  My question would be - are we sure it is VS2017 and not SSMS 2017?   

    BETTER ANSWER

    I like the answer that Luc Reid has given.   Perhaps the moderator can check the validity of the answer given by IdleHands and if it is valid, mark it as the proposed answer.  Removing the C++ Distributable for 2017 takes about a half a minute.  If it messes up Visual Studio 2017, there is something called "Repair".   IdleHands solution is short, quick, and more to the point, saves time.

    VS 2017 C++ Distritributable Repair.  Okay well, it wound up a bit more complicated but still simpler than uninstalling and later, reinstalling VS 2017... explanation follows

    Click the VS 2017 XXX in Control Panel and select "Change"  Add the "Desktop Development with C++" from the upper right corner (or repair it if you already installed it).  Its a 360 MB download and install and it doesn't take two hours.  I see others with similar solutions.  We aren't talking brain surgery with this fix.  It just takes a bit of planning to save you about a 1/2 day of installation time.

    MAYBE AN ANALOGY HELPS

    When I go out for a meal and have to wait for my food, the wait is worth it when the food is good.  But when the wait turns to hours and causes frustration, it no longer matters whether the meal is good or not.   Some things are just not worth the wait.

    RESULTS

    1) Uninstalled the 2017 C++ Distributable 2) Installed SQL 2017 (no problems) 3) Repaired Visual Studio 2017 - VOILA - the 2017 C++ Distributables are back.  YAY!

    I expect that since my main goal was to get the Database Engine running, its likely the Anaconda, R, Python, etc installation may also fail compatibility as well.  Remains to be seen.  

    Thanks Luc Reid.  You saved me half a day.   Terrific Answer.  Visual Studio has taken ages to install in the past - this VS version, 2017, is one where you turn it on and go do something else for the rest of the day.   It takes forever.


    R, J


    • Edited by Crakdkorn Thursday, November 1, 2018 1:38 AM
    Thursday, November 1, 2018 1:37 AM
  • great solution   it makes sense and it works
    Thursday, November 8, 2018 2:09 AM
  • thank you
    Tuesday, November 27, 2018 12:03 PM
  • I just replaced installations file of the c++ 2015 by new one with same names from 

    https://visualstudio.microsoft.com/downloads/

    (look in Other Tools and Frameworks/Microsoft Visual C++ Redistributable for Visual Studio 2017).

    And it worked for me.

    


    Wut?


    thank you
    Tuesday, November 27, 2018 12:04 PM