Ok, here is post #3 on command line installs, this time I will be covering the Outlook Client.
The Outlook Client installer can be downloaded from here. Download it and run it to extract out the installation files. The files will be extracted and then the installer will launch, cancel the installer at the first opportunity. Place the extracted installation files in a shared folder on a server somewhere.
There are 2 different approaches you can take with the Outlook Client installer.
1) You can execute a command line statement to install the Outlook Client on a local PC, or
2) You can execute a command that will generate an MSI installer for you to later deploy out to client PC’s.
Let’s start with the first approach...
The command line to install the Outlook Client looks like the below:
\\VBOX\CRMInstall\Setupclient.exe /Q /L C:\crm_client_install.log
Full details on what this all means can be found here. Now we don’t actually need a config file this time around, everything can be specified in the command line.
It is important to understand that the installation of the Outlook Client and the configuration of the Outlook Client to point to your CRM Server are 2 separate steps. All we are doing at this stage is installing the Client.
The above command line does not install the offline capability, However, the Go Offline button will be visible to the user and when clicked a wizard will launch that the user can use to add this capability. To hide the Go Offline button use the following command line install instead:
\\VBOX1\CRMInstall\Setupclient.exe /Q /L C:\crm_client_install.log /disableofflinecapability
Or if you want the install to include offline capability use the following command line install instead:
\\VBOX1\CRMInstall\Setupclient.exe /Q /L C:\crm_client_install.log /installofflinecapability
To run the install open a command prompt, navigate to the extracted installation files and then run your command. Little will happen initially, your command will simply clear as per the below:
If your install fails have a look at the log file created. If the issue is not clear you can try re-running the install with /LV rather than /L which will give you verbose logging.
And now the second approach…
This approach is not that different from the first, we are still executing Setupclient.exe at the command line but this time nothing is actually installed, instead an installer is created. I guess you just go this way if you want an MSI file.
The first step is to run the following command:
Setupclient.exe /A /Q /L C:\crm_client_install.log /targetdir "c:\Program Files\Microsoft Dynamics CRM Client"
Here we have added /A to indicate we want to create an admin installer and we are specifying a target directory for where the installer should be created.
So run the command, check the log file until you can see the process has completed and then browse to the target directory. There you will see an MSI has been created and the install files have been copied to an accompanying folder.
Now, to actually deploy the MSI file out to clients you can should be able to use a command like the below:
MSIEXEC.EXE /I "R:\GT_Shared\MSI\CrmClient_32.msi" /QN /LWAMOE C:\crm_client_install.log ALLUSERS=1
The /QN is meant to force a silent install. It doesn’t. I tried a few alternative switches and nothing seemed to give me a silent install. Not my area of expertise here. Perhaps software packaging folk know how to achieve this. Curiously, I did notice when I tried the first approach in this blog that the log file suggests that behind the scenes an MSI is being used and I saw this command…
msiexec /i "R:\GT_Shared\CRMShare\Client.msi" /q INSTALLLEVEL="3" INSTALLTYPE="INSTALL" SOURCEFOLDER="R:\GT_Shared\CRMShare" TARGETDIR="C:\Program Files\Microsoft Dynamics CRM" INSTALLDIR="C:\Program Files\Microsoft Dynamics CRM" /l+ "C:\crm50clientmsi.log" LOGFILE="C:\crm50clientmsi.log" ALLOWRUN="1" REBOOT=ReallySuppress NOSELECTION=1
… which must produce a silent install so there will be some clues there:
And finally, to do the actual configuration…
The command line for configuring the Outlook Client looks like this:
Microsoft.Crm.Application.Outlook.ConfigWizard.exe /Q /i \\VBOX1\CRMInstall\CONFIG\client_config.xml /l c:\crm_client_config.log
And the config file looks like this:
<Deployments> <Deployment> <DiscoveryUrl>http://vbox1:5555</DiscoveryUrl> <Organizations> <Organization IsPrimary='true'>TestCompany</Organization> </Organizations> </Deployment> </Deployments>
From a command prompt I browse to the folder where the CRM Outlook Client was installed (under Program Files) and then execute the command:
The command line provides no indication of processing, but check Task Manager and the log to see whether the configuration is running or not.
If no log file gets created or the log indicates error trying running the command without the /Q to see what’s going on.
A successful run creates a log file that ends like this (no visible indicator appears on screen):
Finally, launch Outlook to confirm and you should see your CRM Organisation available in Outlook:
Hope this helps someone