---
title: "Set up Splunk notifications"
description: "Setting up Splunk notifications in Opsview involves installing the notifybysplunk script and configuring notification methods, users, and profiles in the UI. The FAQ provides step-by-step instructions for different Opsview versions, including how to add supplemental text for specific checks."
url: "https://docs.itrsgroup.com/docs/faq/opsview/4922751760285-opsview-set-up-splunk-notifications/index.html"
---
## Prerequisites

- None

### Process

1. Log in to the [orchestrator](https://docs.itrsgroup.com/docs/faq/opsview/4920429084957-opsview-orchestrator/index.html) as `root`.
2. Download the `notify_by_splunk` script using `curl`:

```
curl -sLo /tmp/notify_by_splunk.tar.gz https://downloads.opsview.com/opsview-support/notify_by_splunk.tar.gz
```

3. Install the `notify_by_splunk` script.

```
tar -C /opt/opsview/monitoringscripts -x -f /tmp/notify_by_splunk.tar.gz --overwrite
```

4. Log in to the UI and navigate to **Configuration** > **Advanced** > **Variables**.

5. Click **Add New** in the top left of the page and input the following settings:

| **Field** | **Value** |
| --- | --- |
| **Name** | SPLUNK |
| **Label Arg1** | Host |
| **Default Arg1** | <insert the FQDN of your Splunk server> |
| **Label Arg2** | Port |
| **Default Arg2** | 8088 |
| **Label Arg3** | Token |
| **Default Arg3** | <insert your Splunk token> |

Tick the **Encrypt** box for **Default Arg3** and leave all non-specified fields empty.

6. Click **Submit Changes**.
7. Navigate to **Configuration** > **Users and Notifications** > **Notification Methods**.
8. Click **Add New** in the top left of the page and input the following settings:

| **Field** | **Value** |
| --- | --- |
| **Name** | Splunk |
| **Enable** | ✔️ |
| **Run on** | Orchestrator |
| **Command** | `notify_by_splunk -H '%SPLUNK:1%' -p '%SPLUNK:2%' -t '%SPLUNK:3%'` |

Additional command options

Additional options for the **command** field are available, including:

```
-I : to not verify SSL certs (for use with self-signed certs)
-N : use HTTP not HTTPS
-v : additional information in the log file (will get noisy on a busy system)
```

Logging information is saved to `/var/log/opsview/opsview.log`.

9. Click the **Test** tab, then click **Send**.
10. Click **Submit Changes**.
11. Navigate to **Configuration** > **Users and Notifications** > **Users and Roles**.
12. Click **Add New** in the top left of the page and input the following settings in the **User** tab:

| **Field** | **Value** |
| --- | --- |
| **Name** | Splunk |
| **Username** | splunk |
| **Comment** | Notifications into Splunk |
| **Role** | Administrator |
| **Set password** | <set a secure password> |

13. Switch to the **Notification Profiles** tab.
14. Click **Add New** and set the following settings:

| **Field** | **Value** |
| --- | --- |
| **Profile Name** | Splunk |
| **Alert me by** | Splunk |

15. Configure the notification profile to alert on hosts and service checks as desired then click **Update**.
16. Click **Submit Changes**.
17. Apply Changes.

**For version 6.8.7 and previous, follow the below:**

You can add supplemental text for specific checks by editing the file `/opt/opsview/monitoringscripts/etc/notifications/notify_by_splunk.cfg`. If this file does not exist, create it using this command:

```
cp /opt/opsview/monitoringscripts/etc/notifications/notify_by_splunk.cfg.in /opt/opsview/monitoringscripts/etc/notifications/notify_by_splunk.cfg
```

**For version 6.8.8 and after, follow the below:**

You can add supplemental text for specific checks by adding/updating the **notify\_by\_splunk.cfg** file. Create this file (either new, or copy the content already at `/opt/opsview/monitoringscripts/etc/notifications/notify_by_splunk.cfg` if it exists), then set it up on your system by running the following command as the **opsview** user:

```
/opt/opsview/orchestrator/bin/orchestratorimportscripts etc-notifications /path/to/notify_by_splunk.cfg
```


