---
title: sa_backup - backup tool for Security Analytics 10.6
description: Since I no longer have access to my previous post sa_backup-1.0.9 - backup tool for Security Analytics 10.3, 10.4, 10.5 and a built-in backup feature
---

- [Home](https://mydev.netwitness.com/home)
- Integrations 
    - [Netwitness Platform Integrations](https://mydev.netwitness.com/netwitnessplatformintegrations)
    - [Third Party Integrations](https://mydev.netwitness.com/thirdpartyintegrations)
- [Knowledge Center](https://mydev.netwitness.com/knowledge-base)
- Community 
    - [Blogs](https://mydev.netwitness.com/netwitness-security-llc-blog)
    - Discussions
- Customers 
    - [Manage Products and Licenses](https://mydev.netwitness.com/nwportal)
    - Downloads
- Partners 
    - [Partner Program](https://mydev.netwitness.com/partner)
    - [Partner Resources](https://mydev.netwitness.com/partnerresources)
    - [Submit a New Deal Registration](https://mydev.netwitness.com/dealregistration)
    - [Become a Partner](https://mydev.netwitness.com/becomeapartner)
    - [Update Your Partner Locator Profile](https://www.netwitness.com/partner-locator/?utm_source=pardotnewsletter&utm_medium=email&utm_campaign=partner_march)
    - [NetWitness LinkedIn Partner Hub](https://linkedin.com/showcase/netwitnesspartners/)
- Education 
    - [Instructor Led Training Schedule](https://mydev.netwitness.com/instructorledtrainingschedule)
    - [NetWitness Training Catalog](https://mydev.netwitness.com/netwitnesstrainingcatalog)
    - [Security Awareness Training](https://mydev.netwitness.com/securityawarenesstraining)
    - [New Product Readiness](https://mydev.netwitness.com/newproductreadiness)
    - [On-Demand Virtual Labs](https://mydev.netwitness.com/ondemandvirtuallabs)
    - [Additional Training Information](https://mydev.netwitness.com/additionaltraininginformation)
    - [Frequently Asked Questions](https://mydev.netwitness.com/educationfaq)
    - [Contact NetWitness Education Team](https://mydev.netwitness.com/contact-netwitness-education-team)
- Support 
    - [Contact Support](https://mydev.netwitness.com/contact-support)
    - [Create a New Case](https://mydev.netwitness.com/create-support-case)
    - [View My Cases](https://mydev.netwitness.com/viewmycase)
    - [Product Version Life Cycle](https://mydev.netwitness.com/product-version-life-cycle)
    - [Warranty & Replacement Parts](https://mydev.netwitness.com/warranty-and-replacement-parts)
    - [Community Support Forum](https://mydev.netwitness.com/community-support-forum)
    - [Technical Support Guide](https://mydev.netwitness.com/technical-support-guide)

![search](https://21725316.fs1.hubspotusercontent-na1.net/hubfs/21725316/Ladder/Image/search.svg)

![search](https://21725316.fs1.hubspotusercontent-na1.net/hubfs/21725316/Ladder/Image/search.svg)

![search](https://21725316.fs1.hubspotusercontent-na1.net/hubfs/21725316/Ladder/Image/search.svg)

![search](https://21725316.fs1.hubspotusercontent-na1.net/hubfs/21725316/Ladder/Image/search.svg)

# sa\_backup - backup tool for Security Analytics 10.6

- Home
 */*- [Netwitness blogs](https://mydev.netwitness.com/netwitness-security-llc-blog)
*/*- sa\_backup - backup tool for security analytics 10.6

 31 Mar, 2017

**Author:** Admin

*Since I no longer have access to my previous post [sa\_backup-1.0.9 - backup tool for Security Analytics 10.3, 10.4, 10.5](https://community.rsa.com/docs/DOC-31629) and a built-in backup feature is still pending on RSA I would like to share an updated script.*

**sa\_backup** is a tool to take a backup of configurations and some data of all Security Analytics components available on the appliance.

Tested with versions 10.3, 10.4, 10.5, 10.6.

The script is attached and also available on the GitHub: [https://github.com/Jazzmax/rsa\_sa\_backup](https://github.com/Jazzmax/rsa_sa_backup)

The direct GitHub link to the script:  [https://raw.githubusercontent.com/Jazzmax/rsa\_sa\_backup/master/sa\_backup.sh](https://community.rsa.com/external-link.jspa?url=https%3A%2F%2Fraw.githubusercontent.com%2FJazzmax%2Frsa_sa_backup%2Fmaster%2Fsa_backup.sh) so can be grabbed using wget.  

Restore instructions are on the Github Wiki: [Backup restore · Jazzmax/rsa\_sa\_backup Wiki · GitHub](https://github.com/Jazzmax/rsa_sa_backup/wiki/Backup-restore) 

This has been tested when restoring on the same appliance and a fresh/re-imaged appliance (RMA-like scenario).

### Features

- The following components are backed up:
  
    - OS configuration files: 
          - /etc/sysconfig/network-scripts/ifcfg-\*\[0-9\] - HWADDR is disabled
          - /etc/sysconfig/network
          - /etc/hosts
          - /etc/resolv.conf
          - /etc/ntp.conf
          - /etc/fstab - renamed to fstab.{hostname} to prevent overwriting the original fstab on restore
          - /etc/krb5.conf
    - Puppet configuration (puppetmaster, puppet client, ssl files, node\_id, puppet.conf, csr\_attributes.yaml, mcollective configuration)
    - Core Appliance Services configuration (/etc/netwitness/ng)
    - SA server configuration (/var/lib/netwitness/uax, jetty keystore, jetty-ssl.xml)
    - Reporting Engine (configuration or full backup (optional))
    - RabbitMQ server (mnesia database, configuration for 10.3)
    - MongoDB (entire dump of the mongodb instance of SA and ESA servers)
    - PostgreSQL database (10.3)
    - Malware Analysis configuration
    - ESA server configuration
    - System Management Service (SMS) configuration
    - Incident Management (IM) configuration and DB
    - Log Collector (configuration and statDB)
    - Warehouse Connector
    - Custom user files
- After taking a backup the tool restores the original service status (start/stop)
- Logs the progress to a file
- Logs fatal errors to syslog
- Checks if the tool is already running
- Removes archives older than "n" days.
- Rotates log file
- Command line arguments - see the usage information.
- Inline or file configuration to enable/disable backup of components
- Option to backup custom user files
- Test mode
- Remote backup to NFS

 

The tool does **NOT** do:

\- Backup of packets, meta, sessions or index data.  
\- Backup of a license server (fneserver).

 

### Usage

```
Usage: ./sa_backup.sh [OPTION...]Please modify the configuration section in the script or use an external configuration file.Examples:  sa_backup --config=backup.conf --verbose  sa_backup --backuponly=COREMain operation mode:-c, --config=CONFIG_FILE      Use configuration file-b, --backuponly=COMPONENTS   Backup only specified components:                                  CORE - Core services                                  SYS - OS configuration                                  PUPPET - puppet master/agent configuration                                  RABBITMQ - rabbitmq configuration                                  MONGO - MongoDB/tokumx dump                                  JETTY - SA application server settings                                  RE - Reporting Engine                                  MALWARE - Malware Analysis configuration                                  ESA - Event Stream Analysis configuration                                  IM - Incidint Management configuration                                  IMDB - Incidint Management DB                                  SMS - System Management System                                  LC - Log collector                                  WHC - Warehouse connector                                  PGQSL - PostgreSQL database-t, --test                    Test mode; no backup performed-v, --verbose                 tar verbose switch-?, -h, --help                Give this help list‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
```

Edit the configuration section in the script before running it.

```
BACKUP_TYPE=local                             # local | nfs BACKUPPATH=/root/sabackups              # Local backup directoryLOG=sa_backup.log                       # The backup log fileLOG_MAX_DIM=10000000                    # Max size of log file in bytes - 10MB RETENTION_DAYS=0                            # Local backups retention in days (0 - no cleanup)                         # System files SYS_ENABLED=true# SA server / Jetty serverSASERVER_ENABLED=true# Reporting engineRE_ENABLED=trueRE_FULLBACKUP=1                         # 0 - backup only RE configuration;                                         # 1 - full RE backup# Puppet PUPPET_ENABLED=true# RabbitMQ serverRABBITMQ_ENABLED=true# Core Appliance ServicesCORE_ENABLED=true# MongoDB MONGODB_ENABLED=true# Malware AnalysisMALWARE_ENABLED=true# ESA ESA_ENABLED=true# Incident ManagementIM_ENABLED=true# Incident Management database IMDB_ENABLED=trueIM_MONGO_PASS="im"                      # Password for the MongoDB IM database .                                         # Host, db name, and db user will be read from SA IM configuration file‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
```

**This script must be run as "root" user.**

***Restoring is manual.***

You need to extract all tar.gz files using:

> tar -C / -xvphzf backup.tar.gz

To restore MongoDB extract the mongo dump directory and run:

> mongorestore -v --drop mongodb-dump.2015-06-07-22-40

**Note**: on ESA appliance to be able to restore the entire db dump you would need to temporarily disable the authentication in /etc/tokumx.conf:

> sed -i "s/\\(auth \*= \*\\).\*/\\1false/" /etc/tokumx.conf

> service tokumx restart

After the restore has been done enable the authentication back:

> sed -i "s/\\(auth \*= \*\\).\*/\\1true/" /etc/tokumx.conf

> service tokumx restart

in version 1.0.15 

\+ Added Incident Management remote database backup  
\* Fixed --backuponly option, other minor fixes  
\* Let SA 10.6 backup   
\* check\_SAVersion checks the sarelease file first

This document was generated from the following discussion: [sa\_backup - backup tool for Security Analytics 10.6](https://community.rsa.com/thread/191137)

 Topic:

[0 Comment](https://mydev.netwitness.com/netwitness-security-llc-blog/sa-backup-backuptoolforsecurityanalytics10-6#comments-listing)

###### CATEGORIES

- All
- [Blog](https://mydev.netwitness.com/netwitness-security-llc-blog/tag/blog)

##### RECENT POST

[Netwitness Platform Integration with AWS Application Load Balancer Access logs](https://mydev.netwitness.com/netwitness-security-llc-blog/netwitnessplatformintegrationwithawsapplicationloadbalanceraccesslogs)

 23 Jul, 2024

[The Sky Is Crying: The Wake of the 19 JUL 2024 CrowdStrike Content Update for Microsoft Windows and We Should Take Away From It](https://mydev.netwitness.com/netwitness-security-llc-blog/715124)

 20 Jul, 2024

[DDoS using BotNet Use Case](https://mydev.netwitness.com/netwitness-security-llc-blog/ddosusingbotnetusecase)

 7 May, 2024

[NetWitness Platform](https://www.netwitness.com/)

[Acceptable Use Policy](https://www.netwitness.com/wp-content/uploads/Acceptable-Use-Policy-092022.pdf) [Privacy Statement](https://www.netwitness.com/wp-content/uploads/NetWitness-Privacy-Statement-07292024.pdf)

![NetWitness Logo](https://mydev.netwitness.com/hubfs/Portal-Partner%20Program/netwitness-logo-RGB-white%201.png)

[![LinkedIn](https://mydev.netwitness.com/hubfs/Portal-Partner%20Program/linkedin.png)](https://www.linkedin.com/company/netwitness-platform/) [![YouTube](https://mydev.netwitness.com/hubfs/Portal-Partner%20Program/Youtube.jpg)](https://www.youtube.com/@netwitness)

© 2026 NetWitness LLC. All rights reserved.

```json
{
  "@context" : "https://schema.org",
  "@type" : "BlogPosting",
  "author" : {
    "@type" : "Person",
    "name" : "Admin",
    "url" : "https://mydev.netwitness.com/netwitness-security-llc-blog/author/admin"
  },
  "dateModified" : "2026-03-20T11:53:33.013Z",
  "datePublished" : "2017-03-31T04:00:00.000Z",
  "headline" : "sa_backup - backup tool for Security Analytics 10.6",
  "mainEntityOfPage" : {
    "@id" : "https://mydev.netwitness.com/netwitness-security-llc-blog/sa-backup-backuptoolforsecurityanalytics10-6",
    "@type" : "WebPage"
  },
  "publisher" : {
    "@type" : "Organization",
    "logo" : {
      "@type" : "ImageObject",
      "url" : "https://mydev.netwitness.com/hubfs/netwitness-logo-CMYK.jpg"
    }
  }
}
```