[SERVER-33926] Unattended installation fails when deselecting Compass Created: 16/Mar/18  Updated: 29/Oct/23  Resolved: 13/Apr/18

Status: Closed
Project: Core Server
Component/s: Packaging
Affects Version/s: 3.6.3
Fix Version/s: 3.6.3

Type: Bug Priority: Major - P3
Reporter: Matthew Bartenschlag Assignee: Mathew Robinson (Inactive)
Resolution: Fixed Votes: 2
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Microsoft Windows 10 Enterprise (64-bit)


Issue Links:
Documented
is documented by DOCS-11590 Update unattended installation for Wi... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Steps To Reproduce:
  1. Download mongodb-win32-x86_64-2008plus-ssl-3.6.3-signed.exe.
  2. Run the unattended installer using ADDLOCAL="all" (e.g., msiexec /q /i mongodb-win32-x86_64-2008plus-ssl-3.6.3-signed.msi INSTALLLOCATION="mongo" ADDLOCAL="all" /l*v mongo-all.log)
  3. Uninstall both mongodb and compass from Add/Remove Programs
  4. Re-run the unattended installer (e.g., msiexec /q /i mongodb-win32-x86_64-2008plus-ssl-3.6.3-signed.msi INSTALLLOCATION="mongo" ADDLOCAL="Server,Client" /l*v mongo-client-server.log)
Sprint: Build 2018-04-23
Participants:
Story Points: 13

 Description   

Summary

  • Unattended installation documentation does not explicitly mention that Compass will be installed when using ADDLOCAL="all".
  • Unattended installation does not appear to work unless Compass is selected.

Details

The Install on Windows page of the mongodb manual provides a section describing unattended installations.

When using ADDLOCAL="all", the installer downloads and installs Compass. I do not want Compass, so I uninstalled both Compass and mongo CE before re-installing using ADDLOCAL="Server,Client". This causes the installer to fail and roll back the entire installation.

MSI (s) (68:E0) [10:11:35:725]: Executing op: ActionStart(Name=InstallCompassScript,Description=Installing MongoDB Compass... (this may take a few minutes),)
MSI (s) (68:E0) [10:11:35:738]: Executing op: CustomActionSchedule(Action=InstallCompassScript,ActionType=1025,Source=BinaryData,Target=WixQuietExec64,CustomActionData="C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -NoLogo -NoProfile -NonInteractive -ExecutionPolicy Bypass -Command "& '' ; exit $($Error.Count)")
MSI (s) (68:7C) [10:11:35:759]: Invoking remote custom action. DLL: C:\windows\Installer\MSI3154.tmp, Entrypoint: WixQuietExec64
MSI (s) (68:A0) [10:11:35:760]: Generating random cookie.
MSI (s) (68:A0) [10:11:35:769]: Created Custom Action Server with PID 7948 (0x1F0C).
MSI (s) (68:78) [10:11:35:826]: Running as a service.
MSI (s) (68:78) [10:11:35:830]: Hello, I'm your 32bit Impersonated custom action server.
WixQuietExec64:  The expression after '&' in a pipeline element produced an object that was not valid. It must result in a command 
WixQuietExec64:  name, a script block, or a CommandInfo object.
WixQuietExec64:  At line:1 char:3
WixQuietExec64:  + & '' ; exit $($Error.Count)
WixQuietExec64:  +   ~~
WixQuietExec64:      + CategoryInfo          : InvalidOperation: (:String) , RuntimeException
WixQuietExec64:      + FullyQualifiedErrorId : BadExpression
WixQuietExec64:   
WixQuietExec64:  Error 0x80070001: Command line returned an error.
WixQuietExec64:  Error 0x80070001: QuietExec64 Failed
WixQuietExec64:  Error 0x80070001: Failed in ExecCommon method
CustomAction InstallCompassScript returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)
MSI (s) (68:E0) [10:11:36:320]: Note: 1: 2265 2:  3: -2147287035
MSI (s) (68:E0) [10:11:36:322]: User policy value 'DisableRollback' is 0
MSI (s) (68:E0) [10:11:36:322]: Machine policy value 'DisableRollback' is 0
Action ended 10:11:36: InstallFinalize. Return value 3.



 Comments   
Comment by Mathew Robinson (Inactive) [ 13/Apr/18 ]

Hey Matthew, thanks for bringing this to our attention. So the answer to your actual problem is that you need to add an additional variable to not install compass. If you want an unattended installation without compass the command is:

msiexec.exe /q /i mongodb-win32-x86_64-2008plus-ssl-3.6.3-signed.msi ^
            INSTALLLOCATION="C:\Program Files\MongoDB\Server\3.6.3\" ^
            ADDLOCAL="all" ^
            SHOULD_INSTALL_COMPASS="0"

I'll make sure we get a doc change in to have that added. You also found a bug in our installer for Compass so thanks for that to!

Generated at Thu Feb 08 04:35:01 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.