---
title: 'Tutorial: Configuring UCARP/VRRP Failover Advanced Settings'
canonical: https://openvpn.net/as-docs/tutorials/tutorial--ucarp-vrrp-failover-advanced/
product: Access Server Docs
description: Configure the UCARP/VRRP failover VHID for Access Server when your setup requires this specific identifier.
---

# Tutorial: Configuring UCARP/VRRP Failover Advanced Settings

## Overview

This tutorial covers setting a unique VHID and configuring additional UCARP parameters for Access Server.

## Prerequisites

- Installed Access Servers [configured for failover](https://openvpn.net/as-docs/tutorials/tutorial--failover.md).
- Console access (both nodes) with root privileges.
- Proper planning to handle two failover events during the configuration.

## Step 1: Adjust the VHID on the primary node

1. Connect to the primary node console and get root privileges.
2. Switch to the scripts directory:

   ```
   cd /usr/local/openvpn_as/scripts/
   ```
3. Adjust the VHID:

   ```
   ./sacli --key "ucarp.vhid" --value <NUMBER> ConfigPut
   systemctl restart openvpnas
   ```

   Replace **\<NUMBER\>** with a value from 1 to 255.
4. Wait a full minute for the primary node to relay the new configuration to the secondary node.

## Step 2: Restart the Access Server service on the secondary node

1. Connect to the secondary node console and get root privileges.
2. Restart the Access Server service:

   ```
   systemctl restart openvpnas
   ```

## Step 3: Define extra parameters for UCARP (optional)

1. To pass additional parameters to UCARP, use the following command:

   ```
   ./sacli --key "ucarp.extra_parms" --value "<PARAMETERS>" ConfigPut
   systemctl restart openvpnas
   ```

   Replace **\<PARAMETERS\>** with the desired UCARP parameters.

## Step 4: Override UCARP up/down scripts (optional)

Suppose, for example, you want to override the standard scripts that Access Server uses when the node becomes active or assumes the standby role. In that case, you can pass new **--upscript** and **--downscript** parameters directly to UCARP and specify new scripts instead. For example, you could copy the original **ucarp\_standby** and **ucarp\_active** up/down scripts in the **/usr/local/openvpn\_as/scripts/** directory and edit them to suit your needs. If you edit the scripts directly, they will be reset to standard whenever you upgrade or reinstall Access Server. Thus, we recommend creating copies of the up/down scripts to customize instead with the following commands.

1. Create your up/down scripts.
2. To override the default UCARP scripts:

   ```
   ./sacli --key "ucarp.extra_parms" --value "--upscript /root/up --downscript /root/down" ConfigPut
   systemctl restart openvpnas
   ```
3. To revert to the default scripts:

   ```
   ./sacli --key "ucarp.extra_parms" ConfigDel
   systemctl restart openvpnas
   ```

---

Prev: [High Availability and Network Behavior](https://openvpn.net/as-docs/tutorials/high-availability-and-network-behavior.md)
Next: [Tutorial: Configure Global NAT Behavior Settings](https://openvpn.net/as-docs/tutorials/tutorial--global-nat.md)
Index: https://openvpn.net/as-docs/llms.txt
