> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flashduty.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Raritan PX PDU alert integration

> Raritan PX-Series PDUs send email notifications through event rules; use a Flashduty email integration with rules to trigger and close PDU alerts.

Raritan PX-Series PDUs send email through the **Send email** action of an event rule, and the email subject and message can be customized. The Flashduty [email integration](/en/on-call/integration/alert-integration/alert-sources/email) receives these emails and uses rules on the email title to decide whether each one triggers or resolves an alert, so no separate Raritan integration is needed: create an email integration in Flashduty, add its email address to the PDU's Send email action, set the email subject to the fixed format below, and configure the push rules.

<div className="hide">
  ## In Flashduty On-call

  ***

  Get the integration email address in either of the two ways below. **In both cases choose the Email integration type**, not Raritan.

  ### Use a dedicated integration

  1. In the Flashduty console, select **Channels** and open a channel
  2. Select **Settings** → **Integrations** → **Dedicated integrations** and click **Add an integration**
  3. Select **Email** and click **Save**
  4. Open the new integration card, copy the **email address**, then configure the push rules below

  ### Use a shared integration

  1. In the Flashduty console, select **Integration Center → Alert events**
  2. Select **Email**, enter an integration name and copy the **email address**
  3. Configure the push rules below
  4. Set a default route, select a channel and click **Save**
</div>

## Configure push rules in Flashduty

***

The subject format below puts the device name, the event rule name and an assertion flag in the title. The flag `1` means the event condition became true and `0` means it cleared. The rules extract the device name and event rule name as the Alert Key. Trigger and resolve emails yield the same key, so a resolve email closes the matching alert.

1. Set **Push mode** to **Trigger or close alert based on rules**
2. Add the two rules below in this order. Each rule's condition is **Email title** **Match** the given regex, and the Alert Key is extracted from the **Email title**
3. Under **Default rules**, choose: if none of the above rules match, **discard email**

Rule 1: close the alert

```
Condition: Email title  Match  /^Raritan PX \| .* \| 0$/
Regex: /^Raritan PX \| (.+) \| (.+) \| 0$/
```

Rule 2: trigger an alert

```
Condition: Email title  Match  /^Raritan PX \| .* \| 1$/
Regex: /^Raritan PX \| (.+) \| (.+) \| 1$/
```

The close rule comes before the trigger rule. The default rule discards emails that do not follow the subject format, such as default emails sent by other event rules, so they don't create alerts that can never close on their own.

## Configure Raritan PX

***

The paths below come from the Raritan PX-Series PDU user guide (firmware 4.3.11) and are used in the PDU web interface.

1. **SMTP**: configure the mail server on the **SMTP Server** page; the Send email action uses it by default
2. **Create the action**: go to **Device Settings** → **Event Rules**, create an action, choose **Send email** in **Action**, and enter the Flashduty email integration address in **Recipient email addresses**
3. **Email subject**: select **Custom subject** and enter:

```
Raritan PX | [DEVICENAME] | [EVENTRULENAME] | [ISASSERTED]
```

`[DEVICENAME]` (the device the event occurred on), `[EVENTRULENAME]` (the name of the matching event rule) and `[ISASSERTED]` (1 when the event condition became true, 0 when it became false) are placeholders listed in the user guide; they are replaced with actual values when the email is sent. A rendered subject looks like:

```
Raritan PX | PX3-rack12 | Rack12 temperature high | 1
```

4. **Create the event rule**: go to **Device Settings** → **Event Rules**, create a rule, select the event to watch (for example **Above upper critical threshold** of a temperature sensor), set **Trigger condition** to **Both** so the action runs when the event occurs and when it clears, and select the Send email action from step 2 in **Available actions**
5. **Email body**: the rules read only the email title; the default or a custom message both work

## Limitations

***

* **Unique event rule names**: the Alert Key is built from the device name and the event rule name, so events that share one rule name merge into one alert. Create a separate event rule with its own name for each event you want to monitor.
* **Trigger condition**: with **Asserted** only, the PDU sends trigger emails but no resolve emails, and alerts do not close automatically.
* **Type and severity**: in Flashduty these alerts show the Email integration type, and their severity is always Warning. You can adjust it with [alert pipelines](/en/on-call/integration/alert-integration/alert-pipelines) based on the title.
