# Appendix E - Splunk Integration Support

N2W Backup & Recovery Instance is now supporting the monitoring of backups, DR, copy to S3, alerts, and more by Splunk. The N2W add-on features:

* Ability to define data input from N2W via a Technology Add-on (TA)
* Ability to monitor resources and instances
* An N2W app with 2 dashboards for displaying operational insights:
  * N2W activity monitor - Information about the data
  * N2W Alerts

**Limitations:**

* No support for Microsoft Azure
* No support for multiple CPMs
* Supported with Splunk Enterprise only

Integration consists of installing Splunk and configuring the TA for N2W.

## E.1 Configure N2W Server for Splunk <a href="#e-4-configuration-of-n-2-ws-for-splunk" id="e-4-configuration-of-n-2-ws-for-splunk"></a>

**To configure the N2W Server:**

1. Edit the N2W configuration file as follows:

```
>> su cpmuser
>> vi /cpmdata/conf/cpmserver.cfg
[external_monitoring]
enabled=True
```

​    2. Restart apache:

```
>> sudo service apache2 restart
```

&#x20;   3\. To check the status of the Splunk integration, in N2W, go to **Help** > **About** and verify that **'External monitoring (Datadog / Splunk) enabled'** is **Yes.**

## E.2 Installation on Splunk <a href="#e-1-installation-of-splunk" id="e-1-installation-of-splunk"></a>

Splunk can work with a proxy for reaching N2W APIs.

{% hint style="info" %}
Verify that you have the correct app installation files:

* `N2WS_app_for_splunk.spl`
* `ta_N2WS_for_splunk.spl`

Both files can be downloaded from the Splunk MarketPlace.
{% endhint %}

**To install:**

1. Log on to your Splunk Web and in the Enterprise **Apps** screen, select **Settings** <img src="https://firebasestorage.googleapis.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MQkZglysQuTBKIg_jII%2F-MQkklhKbB7Anhmrs-Ht%2FSplunk%20Gear%20icon.png?alt=media&#x26;token=1177201b-1724-45cc-9944-4b34da477c60" alt="" data-size="line"> .

![](https://gblobscdn.gitbook.com/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MQkodkley0t-LztqmiS%2F-MQkpF_AIZpwucPZxFb6%2Fimage.png?alt=media\&token=66ad7724-14fe-4e00-be20-4bb10a9654e2)

&#x20;        The **Manage Apps** page opens.

&#x20;    2\. In the upper right, **select Install app from file**.

![](https://gblobscdn.gitbook.com/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MQkZglysQuTBKIg_jII%2F-MQkmZ3AKoJ1Yq72v9bv%2Fimage.png?alt=media\&token=86be5d97-eab8-4383-906b-249becd66270)

&#x20;    3\. For an initial installation:\
&#x20;        a. Browse for the `N2WS_app_for_splunk.spl` file. Select **Upload**.

![](https://gblobscdn.gitbook.com/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MQkZglysQuTBKIg_jII%2F-MQknz4LW_gMWjlrDFED%2Fimage.png?alt=media\&token=5013fc1b-3568-4cab-8eb7-ffea040c6327)

&#x20;        b. Browse for `ta_N2WS_for_splunk.spl`. Select **Upload**.

&#x20;   4\. For updates, browse for the current file and select **Upgrade app**.

Installation of Splunk is fully documented at <https://docs.splunk.com/Documentation/Splunk/8.1.1/Installation/InstallonLinux>

## **E.3 Configuration of TA for N2W** <a href="#e-2-configuration-of-ta-for-n-2-ws" id="e-2-configuration-of-ta-for-n-2-ws"></a>

Two configurations are required:

* TA of the REST API
* Data inputs from N2W for Alerts and Dashboard information

**To configure the TA:**

1. Go to **splunk** > **App N2WS Add-on** > **Configuration**.
2. If needed, select the **Proxy** tab, complete the settings, and select **Save**.

![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/tozSDiSK9Wyvfq1p4qjh/image.png)

&#x20;  3\. In the **Logging** tab, select the TA **Log level**: DEBUG, INFO, WARNING, ERROR, CRITICAL.

&#x20;  &#x34;**.** In the **Add-on Settings** tab, set the **API Url** of the target server and the **API Key.** You can copy and paste the **API URL** and **API Key**, or both can be left empty for the customer to fill in.

* The API Url is the address of your N2W server.
* You can generate an API Key in N2W at **User** > **Settings** > **API Access**.

![](https://gblobscdn.gitbook.com/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MQlQsi4pHLgqdtiKo9p%2F-MQlVJ5SbsD-Xn8cBqMK%2Fimage.png?alt=media\&token=d1102f6c-2a47-4a7a-8913-87b47147bbac)

&#x20;   5\. Select **Save**.

**To configure data Inputs:**

{% hint style="warning" %}
Both **Dashboard** and **Alerts** inputs should be defined.
{% endhint %}

1. In the App menu, select **Inputs** ![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/bWbPQ2GvTP9xWPSpJzta/Splunk%20app%20Inputs.png) .
2. In the **Create New Input** menu, select **N2WS Dashboard information** or **N2WS Alerts** ![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/NPdCxhkXwO204PoJMnLz/alerts%20icon.png) **.**
3. Enter the relevant data input information:
   1. **Name** - Unique name of the input.
   2. **Interval** - Time interval for fetching the data from N2W in seconds. 300 is recommended.
   3. **Index** - The Splunk index (silo) to store the data in:
      * For Alerts, **n2ws\_alerts**
      * For Dashboard information, **n2ws\_di**
   4. **Last alert ID** - Leave blan&#x6B;**.**
4. Select **Update**.

When finished, the Inputs should look like this:

![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/Arv5szgRaM98ukv3TbeQ/image.png)

To manage the Inputs, in the **Actions** column, select from the **Action** menu: **Edit**, **Delete**, **Disable**, or **Clone**.

**To configure default data indexes:**

1. Select **Settings** on the upper right corner and then select **Indexes**.

![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/IbZcrbySJ99ZHOFHLJjj/image.png)

&#x20;   2\. Verify that the following indexes exist under the N2W app. If not, select **New Index** to add indexes of the CPM information.

* **n2ws\_alerts**
* **n2ws\_di**

![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/TaY5IiyPP6kjrYtb80Dt/image.png)

&#x20;   3\. In the file system, copy `macros.conf` from the default folder to the local folder. For example,\
&#x20;       Source: `C:\Program Files\Splunk\etc\apps\N2WS_app_for_splunk\default` \
&#x20;       Target: `C:\Program Files\Splunk\etc\apps\N2WS_app_for_splunk\local`&#x20;

&#x20;  4\. Edit the `macros.conf` file under '`local`' and change the default index to the new indexes that were created. &#x20;

![](https://content.gitbook.com/content/5oB64hgFIX2jdQ2O72cF/blobs/G44MTzR9y9dyo5A25ieY/image.png)

&#x20;  3\. Restart the **Splunkd** service from Windows Services.

## E.4 Viewing Dashboards <a href="#e-3-viewing-dashboards" id="e-3-viewing-dashboards"></a>

Go to Splunk **Apps** and find **N2WS app for splunk**. The N2WS app contains tabs for N2W activity monitor and N2W Alerts. **Edit** and **Export** options are available in the upper right corner of each dashboard.

### **E.4.1 N2WS activity monitor** <a href="#n-2-ws-activity-monitor" id="n-2-ws-activity-monitor"></a>

* Filter for Time Range (defaults to last 24 hours) and Users, including root and delegates.
* Displays All Accounts, Policies, Protected Resources, Managed Snapshots, Backups DR, S3 Backups, Volume Usage, and other requested data.

![](https://gblobscdn.gitbook.com/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MRZIacjsI2yYc6X-nBv%2F-MRZMr8QxLXvDJ_1z9Sk%2FSplunk%20N2WS%20activity%20monitor.jpg?alt=media\&token=234fb4e7-9c93-47c2-b7bb-56e8ba8d8acd)

For Protected Resources and Managed Snapshots, select the displayed number to drill down and view a table of the resources and the number of items for each resource type for the selected users, or managed snapshots, count of each type, and a total.

### **E.4.2 N2WS Alerts** <a href="#n-2-ws-alerts" id="n-2-ws-alerts"></a>

The Alerts dashboard includes filters for:

* Time range - Last 24 hours (default)
* User - All (default) or username
* Severity - All or Info or Warning
* Category - All or Tag Scan, volume usage limit exceeded

![](https://gblobscdn.gitbook.com/assets%2F-MCmcYDqe7zxX8UChJRp%2F-MRZRF6ijvNiLMpDFOcw%2F-MR_bUWiCSuXjhzAuHav%2FSplunk%20N2WS%20alerts.png?alt=media\&token=754044c9-0706-4c8d-bab7-cc338460540c)

The list defaults to descending sort order. Select any column to change sort order.

* Time - Date, time, event ID
* User
* Severity
* Category
* Message
