# Single Node Installation

## **Prerequisites:**

{% hint style="success" %}
Before continuing to deployment for On-Premises, Make sure all the prerequisites from below link are met.
{% endhint %}

{% content-ref url="prerequisites" %}
[prerequisites](https://k2cyber.gitbook.io/k2io-documentation/k2-portal/on-premises/deploy-on-local-infrastructure/prerequisites)
{% endcontent-ref %}

## Installation Steps

### Step 1: Download Installer

Download the tar of on-premises installation files from K2 Portal.

Alternatively Go to [On-Premises Installer | K2 Portal](https://www.k2io.net/centralmanager/#!/app/help/installation/onpremises)

### Step 2: Untar it using the following command.

```
tar -xvf k2onpreminstaller.tgz --no-same-owner
```

### Step 3: Navigate to the k2onpreminstaller directory.

```
cd k2onpreminstaller
```

### Step 4: Update the topology\_config.ini

Update the topology\_config.ini file to add following configurations in the file.

#### Deployment type:

* Prevent-web (Only specific components related to the Prevent-web agent)

#### Installation Location:

* Update installation location with absolute path to a directory where you wish to place all the K2 components.

Note: Do not use the installer directory(k2onpreminstaller) as the installation location.

#### Single VM:

* true

#### Enable clair components:

* Set it to true if you wish to install the clair components(image vulnerability scanning) on single machine, false otherwise.

#### Backup Target Location\[Only applicable on Local VM deployment]:

* Set a directory location to store the cloud backups taken every night.

*Note:*

* It is recommended to use a directory which is mounted on a separate disk to ensure the safety of backups in case of a disaster.
* The backup directory used should support mount & unmount operations as it will be used to restore the backups in case of a disaster.

#### K2 UI Public IP:&#x20;

Public IP of the machine to be be configured in K2 components.

#### Slack Channel URL:

* Set a slack channel URL to enable alerts and receive them in your configured channel which are associated to the host machine and the K2 components deployed on it.
* If not set, no alerts will be generated and the monitoring will work as expected.

#### Default login credentials:

* Username: <demo@k2ui.com>
* Password: demo12345

Note: If you have updated the credentials in topology\_config.ini file, then use those credentials to login.

### Step 5: Install K2 components using the following command.

```
bash k2onpreminstall.sh -i 2>&1 | tee -a k2onprem_install_output.txt
```

### Step 6: Access Your K2 Portal Link

**https\://${*****MY\_K2PORTAL\_IP*****}/**[**centralmanager/**](https://www.k2io.net/centralmanager/)

Specify the host IP on which you have performed the installation in the below-given box. In the case of six machine installation, please use the IP specified under the host5 section in the topology\_config.ini file

### Once the installation is complete, you will get the login credentials using which you can login on the K2 UI opened via the above link.

### Step 7 : Troubleshooting

If you face any issues in the installation check our troubleshooting page

{% content-ref url="troubleshooting" %}
[troubleshooting](https://k2cyber.gitbook.io/k2io-documentation/k2-portal/on-premises/deploy-on-local-infrastructure/troubleshooting)
{% endcontent-ref %}
