# Installing OctoXLabs

## Prerequisites﻿ <a href="#prerequisites" id="prerequisites"></a>

* A Linux system (Ubuntu/Debian or Red Hat-based distribution).
* Root or sudo privileges.
* OctoXLabs installation package.

### Step 1: Upload the Installation Package﻿

Upload the installation package to the /tmp directory on your Linux system. You can use tools like scp or any other file transfer method.

```
scp octoxlabs-package.deb user@yourserver:/tmp/
```

Replace octoxlabs-package.deb with the actual package file name.

### Step 2: Install the Package﻿ <a href="#step-2-install-the-package" id="step-2-install-the-package"></a>

Navigate to the /tmp directory and install the package using the appropriate command based on your Linux distribution:

For Debian-based distributions (Ubuntu, etc.):

```
dpkg -i /tmp/PACKAGE_PATH
```

For Red Hat-based distributions (RHEL, CentOS, etc.):

```
rpm -i /tmp/PACKAGE_PATH
```

{% hint style="info" %}
Replace PACKAGE\_PATH with the actual file name of the installation package.
{% endhint %}

### Step 3: Run the Setup Script﻿ <a href="#step-3-run-the-setup-script" id="step-3-run-the-setup-script"></a>

Once the installation is complete, execute the setup script:

```
sudo octox-ctl -x setup
```

### Step 4: Configure the Setup﻿ <a href="#step-4-configure-the-setup" id="step-4-configure-the-setup"></a>

The setup script will guide you through the following configurations:

1. **Select Host IP:**

   1. The script will detect the available IP addresses on your host.
   2. Choose the IP address where the installation was performed and press Enter.

2. **Enter Root Company Name:**
   1. The script will prompt you for a root company name.
   2. Enter the name and press Enter.

### Step 5: Set the Connector's Token﻿ <a href="#step-5-set-the-connector-s-token" id="step-5-set-the-connector-s-token"></a>

1. From the user interface, navigate to **Settings > Connector (in Data Source Settings)**.
2. Select the **Edit** button for **Default Connector**.
3. Execute the command in the CLI:

```
octox-ctl -x token
```

4. Paste the resulting token into the **Token** field in the user interface. (Optionally assign a proxy if required.)
5. Click **Save**, then press **Send Test**; if the test succeeds, the connector is ready for use.

### Step 6: Finalize Setup﻿ <a href="#step-6-finalize-setup" id="step-6-finalize-setup"></a>

The setup will conclude after the script executes successfully. You should see a confirmation message indicating that OctoXLabs has been installed and configured.

### Troubleshooting﻿ <a href="#troubleshooting" id="troubleshooting"></a>

* E**rror with dpkg or rpm:** Ensure you’re using the correct package for your distribution.
* **Permission Denied:** Confirm that you have root or sudo privileges.
