# ArubaCX Network Integration

## Overview

The ArubaCX network plugin is implemented as a HPE Morpheus Enterprise `GenericIntegrationProvider` in Groovy. The plugin handles network and cluster events generated by HPE Morpheus Enterprise and modifies the configuration of ArubaCX switches based on the cable connections between the affected servers and switches. HPE Morpheus Enterprise integrates directly with ArubaCX to create or delete networks for OVS Port Groups that are added or deleted within a configured Cluster.

## Features

- Network - Create or Delete OVS Port Group.

## Prerequisites

- A pair of ArubaCX 8325 series switches
- All the hosts in the Cluster are connected to these pair of switches
- REST API access to the ArubaCX switches with administrative rights
- User credentials for the ArubaCX switch pair with API access granted and read/write access to the switch configuration

### Server Network Configuration (Netplan)

#### Procedure

1. On each host, configure a `bond0` interface on the management interfaces
2. The management interfaces should be connected to the ArubaCX switch pair Sample configuration: 

   ```
   ```
   {  
       bonds:  
         bond0:  
           interfaces:  
             - ens2f0np0  
             - ens1f0np0  
           parameters:  
             mode: "active-backup"  
       ...  
   }
   ```
   ```

### Switch Configuration

#### Procedure

1. Configure the management interface and IP address on both switches in the pair
2. The switch pair must be configured with `vsx-sync` enabled for high availability and redundancy 

   Sample configuration:

   ```
   ```
   vsx  
       inter-switch-link lag 256  
       role primary  
       keepalive peer 192.168.0.1 source 192.168.0.0  
       vsx-sync loop-protect-global mclag-interfaces vsx-global
   ```
   ```

   ```
   ```
   vsx  
       inter-switch-link lag 256  
       role secondary  
       keepalive peer 192.168.0.0 source 192.168.0.1  
       vsx-sync loop-protect-global mclag-interfaces vsx-global
   ```
   ```
3. Create a Multi-Chassis Link Aggregation Group (MC-LAG) between the ArubaCX switch and the upstream network, referred to as `lag1`
4. Configure the `lag1` interface on both switches in the pair Sample configuration: 

   ```
   ```
   interface lag 1 multi-chassis  
       no shutdown  
       no routing  
       vlan trunk native 1  
       vlan trunk allowed 1,175  
       lacp mode active  
       loop-protect
   ```
   ```
5. The switch ports connected to the server’s management interfaces should be set to “Trunk mode” with a “Native VLAN” Sample configuration: 

   ```
   ```
   interface 1/1/1  
   no shutdown  
   no routing  
   vlan trunk native 175  
   vlan trunk allowed 175
   ```
   ```

## Adding ArubaCX Integration

### About this task

NOTE

Making full use of the HPE Morpheus Enterprise ArubaCX integration requires credentials for Aruba CX switch pair with API access granted and read/write access to switch configuration. See ArubaCX 8325 documentation for more information on user rights administration in that product.

### Procedure

1. Navigate to Administration > Integrations
2. Select + New Integration > Other > ArubaCX 

   ![../../_images/arubacx_new_integration.png](https://support.hpe.com/hpesc/public/api/document/sd00007621en_us/GUID-D9808197-A648-4D9C-864F-4A60FC8C7A35-high.png)
3. Enter the following: 

   NAME
   :   Name of the integration in HPE Morpheus Enterprise

   ENABLED
   :   Deselect to disable the integration

   USERNAME
   :   User username for all switches

   PASSWORD
   :   User password for all switches

   IPV4 ADDRESS
   :   Primary switch IP address for switch pair 1

   IPV4 ADDRESS
   :   Secondary switch IP address for switch pair 1

   IPV4 ADDRESS
   :   Primary switch IP address for switch pair 2

   IPV4 ADDRESS
   :   Secondary switch IP address for switch pair 2

   IPV4 ADDRESS
   :   Primary switch IP address for switch pair 3

   IPV4 ADDRESS
   :   Secondary switch IP address for switch pair 3

   IPV4 ADDRESS
   :   Primary switch IP address for switch pair 4

   IPV4 ADDRESS
   :   Secondary switch IP address for switch pair 4

   UPLINK LAG INTERFACE
   :   Name of the uplink LAG interface (default is 'lag1')
4. Select SAVE CHANGES

### Results

Upon save the ArubaCX Network integration will be created. See example screenshots created with and without leaf-spine enabled:

![../../_images/arubacx_settings.png](https://support.hpe.com/hpesc/public/api/document/sd00007621en_us/GUID-5D534A49-DDA0-4E90-856C-F6244B48C327-high.png)![](https://support.hpe.com/hpesc/public/api/document/sd00007621en_us/GUID-74EB5EDA-F973-4471-B1D1-74DBF6F4AAA4-high.png)

NOTE

All fields can be edited after saving.

Sample Reference Architecture for EVPN Configuration

1. Minimum four leaf switches, two spine switches, and one core switch
2. At least two servers in separate racks
3. Configure switches to encapsulate L2 traffic via VXLAN overlay across racks
4. VMs on servers in different racks communicate through the EVPN switch configuration
5. Route traffic between racks through spine switches

## Add ArubaCX Integration to a Cluster

### Procedure

1. In Infrastructure > Clusters select the target Cluster
2. Select the Edit icon for the Cluster
3. In the “Integrations” dropdown, select an available ArubaCX Integration
4. Save Changes 

   ![../../_images/arubacx_edit_cluster.png](https://support.hpe.com/hpesc/public/api/document/sd00007621en_us/GUID-6978CDB6-74D2-492A-B461-2F0EC476F018-high.png)
