Enterprise

# Install a standalone Driver

> Install the Synnax Driver on a computer other than the Core, log it in to the Core, and start it.

Each Core includes the [Driver](https://docs.synnaxlabs.com/reference/hardware), which connects the devices on the Core’s computer. To connect devices on a different computer, install a standalone Driver on that computer. It connects to one Core over the network.

## Step 1Install the Driver

**NI Linux Real-Time**

Before you install:

* Set the data acquisition modules of the controller to the NI-DAQmx real-time programming mode in NI MAX. See the [NI CompactRIO user manual](https://www.ni.com/docs/en-US/bundle/ni-compactrio/page/programming-modes.html).
* Turn on SSH on the controller. You can turn it off after you install the Driver.

Open an SSH connection to the controller and log in as `admin`. On NI Linux Real-Time, `admin` is root, so the commands on this page need no `sudo` there. Run:

```bash
curl -LO https://github.com/synnaxlabs/synnax/releases/download/driver/v0.60.0/install-driver-nilinuxrt.sh && chmod +x install-driver-nilinuxrt.sh && ./install-driver-nilinuxrt.sh
```

The script installs the Driver as a service and starts it. The service also starts each time the controller starts. The Driver runs as root.

**Linux**

> The Driver needs a recent glibc. See [Requirements](https://docs.synnaxlabs.com/reference/enterprise/requirements) for the supported Linux versions.

Download the Driver:

```bash
curl -LO https://github.com/synnaxlabs/synnax/releases/download/driver/v0.60.0/synnax-driver-v0.60.0-linux
```

Move it into a folder on your `PATH`, and make it executable:

```bash
sudo mv synnax-driver-v0.60.0-linux /usr/local/bin/synnax-driver
```

```bash
sudo chmod +x /usr/local/bin/synnax-driver
```

Install the systemd service:

```bash
sudo synnax-driver install
```

The `install` command creates a `synnax` system user, the empty environment file `/etc/synnax/driver.env`, and the `synnax-driver` service. It does not start the service. It gives the service real-time permission and writes the udev rule `/etc/udev/rules.d/99-synnax-driver-latency.rules`, so Arc automations can run with [precise timing](https://docs.synnaxlabs.com/reference/control/arc/timing?platform=Linux#get-the-best-timing-from-a-computer). For [EtherCAT](https://docs.synnaxlabs.com/reference/hardware/ethercat/configure-device#network-interface-access), it gives the service raw Ethernet access and writes the udev rule `/etc/udev/rules.d/99-synnax-driver-ethercat.rules`. After you upgrade the Driver, run `sudo synnax-driver install` again.

**Windows**

Download the Driver:

```powershell
Invoke-WebRequest -Uri "https://github.com/synnaxlabs/synnax/releases/download/driver/v0.60.0/synnax-driver-v0.60.0-windows.exe" -OutFile "synnax-driver.exe"
```

Move `synnax-driver.exe` to a permanent folder, such as `C:\Program Files\Synnax\`. Then add that folder to the `Path` system environment variable, so that each terminal can run `synnax-driver`. Then open a new terminal.

**macOS**

Download the Driver:

```bash
curl -LO https://github.com/synnaxlabs/synnax/releases/download/driver/v0.60.0/synnax-driver-v0.60.0-macos
```

Move it into a folder on your `PATH`, and make it executable:

```bash
sudo mv synnax-driver-v0.60.0-macos /usr/local/bin/synnax-driver
```

```bash
sudo chmod +x /usr/local/bin/synnax-driver
```

Check the installation:

```bash
synnax-driver version
```

The output ends with the version:

```text
Synnax Driver v0.60.0
```

## Step 2Log in to the Core

Create a user for the Driver with the [Host role](https://docs.synnaxlabs.com/reference/enterprise/users#roles). Then run `login`. On Linux, run it with `sudo`. On NI Linux Real-Time, run it as `admin` with no `sudo`:

```bash
sudo synnax-driver login
```

The command asks for the address of the Core, and checks that it can reach the Core. Then it asks for the username and the password:

```plaintext
Host [localhost]: 10.0.0.45
Port [9090]:
Secure (Y/N) [N]:
Username: driver
Password:
```

When the output shows `credentials saved successfully!`, the Driver is logged in.

> The Driver saves the password as plain text in its state file, and each user of the computer can read the file. Give the Driver a user with only the Host role, not an administrator.

### Log in to a Core that uses TLS

Answer `Y` to `Secure` when the Core uses TLS, and give the host name of the certificate, not an IP address. A certificate from a public authority, such as Let’s Encrypt, needs no more setup.

For a certificate from your own authority, or from a Core that runs with `--auto-cert`:

* **Linux, NI Linux Real-Time, and Windows** -> add the CA certificate to the trust store of the operating system. See [Install certificates](https://docs.synnaxlabs.com/reference/enterprise/certificates).
* **macOS** -> the Driver does not read the macOS keychain. See the macOS tab of [Install the certificate](https://docs.synnaxlabs.com/reference/enterprise/certificates?platform=macOS#install-the-certificate). Set `GRPC_DEFAULT_SSL_ROOTS_FILE_PATH` in the shell that runs `login` and `start`.

On Linux and NI Linux Real-Time, you can instead set the same variable in `/etc/synnax/driver.env`, before you run `login`. See [Environment file](https://docs.synnaxlabs.com/reference/enterprise/driver/configuration#environment-file). The Driver then trusts only the certificates in that file.

## Step 3Start the Driver

**NI Linux Real-Time**

The Driver started before you logged in, so restart it:

```bash
synnax-driver restart
```

**Linux**

Set the service to start when the computer starts, then start it:

```bash
sudo systemctl enable synnax-driver
sudo synnax-driver start
```

**Windows**

The Driver has no service on Windows. Run it in a terminal, and keep the terminal open:

```powershell
synnax-driver start --standalone
```

**macOS**

The Driver has no service on macOS. Run it in a terminal, and keep the terminal open:

```bash
synnax-driver start --standalone
```

## Step 4Check the Driver

**NI Linux Real-Time**

Check the service:

```bash
synnax-driver status
```

A running Driver prints:

```plaintext
Synnax Driver is running (PID: 28191)
```

**Linux**

Check the service:

```bash
synnax-driver status
```

**Windows**

The terminal that runs the Driver shows its logs.

**macOS**

The terminal that runs the Driver shows its logs.

The Driver shows in the devices toolbar under the host name of its computer. To connect devices to it, see [Devices](https://docs.synnaxlabs.com/reference/hardware/devices).
