# Passing Parameters as Arguments

Here is how to perform a Silent Install using `msiexec` to pass parameters as arguments.

### **Prerequisites**

* Make sure to use the `.msi` installer files to run the `msiexec` commands. For example, for **Thinfinity**® **Workspace** the installer would be: `[installer_file.msi]` .
* Make sure to run your command prompt with administrator privileges.

To install a `.msi` file silently, the required argument is `/q` or `/quiet` which allows the installation to run silently, without displaying the user interface.

<pre><code><strong>msiexec /i [installer_file.msi] /q
</strong></code></pre>

Additionally, you can use the `/log` argument followed by a file name to generate a log of the installation process. For example:

```powershell
msiexec /i [installer_file.msi] /q /log myLog.log
```

<details>

<summary>Installing Thinfinity Workspace in All Components mode</summary>

Use the next command to install all the components of **Thinfinity Workspace.**

```powershell
msiexec /i [installer_file.msi] /q
```

</details>

<details>

<summary>Installing Thinfinity Workspace Gateway</summary>

To install only a **Gateway**, a **Broker** (Primary or Secondary), or an **Agent**, use the `SM_TYPE` parameter to specify the component. For example:

{% hint style="info" %}
**Info**\
If the `SM_TYPE` parameter is not specified, **Thinfinity Workspace** will be installed in *All Components* mode by default.
{% endhint %}

<pre class="language-powershell"><code class="lang-powershell"><strong>msiexec /i [installer_file.msi] /q SM_TYPE="SM_Gateway"
</strong></code></pre>

```powershell
msiexec /i [installer_file.msi] /q /l*v ServerGW.log CMDLINE="%CMDLINE%"  SM_TYPE="SM_Gateway"
```

</details>

<details>

<summary>Installing Thinfinity Workspace Broker Primary/Secondary</summary>

When installing a **Broker**, it's necessary to define its type using the `BROKERROLE` parameter. It can take one of two values: `BROKERROLE="BR_Primary"` or `BROKERROLE="BR_Secondary"`.

Use the next command to install the **Thinfinity Workspace** **Primary Broker**:

```powershell
msiexec /i [installer_file.msi] /q BROKERROLE="BR_Primary"
SM_TYPE="SM_Broker"
```

Use the next command to install the **Thinfinity Workspace** **Secondary Broker**:

```powershell
msiexec /i [installer_file.msi] /q BROKERROLE="BR_Secondary"
SM_TYPE="SM_Broker"
```

</details>

<details>

<summary>Installing Thinfinity Workspace Agent</summary>

Use the next command to install the **Thinfinity Workspace** **Agent**:

```powershell
msiexec /i [installer_file.msi] /q /log SM_TYPE="SM_Agent"
```

</details>

### Additional Services Parameters

**Thinfinity Workspace** allows you to selectively skip the installation of certain services, which can help reduce network security vulnerabilities. There are four parameters that control specific services and files that can be configured: **CLOUDMANAGER**, **WEBDAVSERVER**, **MULTITERMINAL**, and **FILEMANAGER**.\
If any of these parameters are set to "0", the files corresponding to that service will be skipped during installation.

For example:

```
msiexec /i [installer_file.msi] /q /MULTITERMINAL=0 /CLOUDMANAGER=0
```

Will install **Thinfinity Workspace** without including the resources needed to create zScope access profiles or the Cloud Manager services.

If the parameters receive any other value, the components will be installed.
