ViPR Controller: How to manually backup the ViPR Controller database using ViPR Controller CLI
Summary: ViPR Controller: How to manually backup the ViPR Controller database using ViPR Controller CLI
This article applies to
This article does not apply to
This article is not tied to any specific product.
Not all product versions are identified in this article.
Instructions
ViPR Controller backups can be manually created using the EMC ViPR Command Line Interface (CLI) prior to making changes to the database, prior to upgrades, when scheduled backups cannot run, and when node(s) are down.
Before you begin:
- Requires System Administrator (SYSTEM_ADMIN) role in ViPR Controller.
- A maximum of 5 manually created backup copies can be created.
- By default, ViPR Controller will not generate a backup set when 1 or more nodes are down or unavailable in a 3 node deployment, or 2 or more nodes are down or unavailable in a 5 node deployment. You can however choose to override the default and force the creation of the backup set.
- For best results confirm that ViPR Controller is not under heavy load, no orders running, no database repair is in progress.
- For further details and a complete list of requirements, reference the EMC ViPR Controller System Disaster Recovery, Backup and Restore Guide in the ViPR Product Documentation Index.
- For further details on how to install ViPR Controller command line interface, reference the EMC ViPR Controller Installation, Upgrade, and Maintenance Guide in the ViPR Product Documentation Index. For this example a VIPR Controller node will be used.
- For further details on CLI refer to the ViPR Controller CLI Reference Guide in the ViPR Product Documentation Index.
Note: VMware snapshots are not a supported method for backing up the ViPR Controller database.
Log in:
1. Log into a vipr node with root or a user with SYSTEM_ADMIN role in ViPR Controller using Putty.
If the root user is used with the correct password and receive the following error, be sure to confirm that "Permit root ssh access" is set to yes in the ViPR Controller GUI System > General Configuration > Security tab:
login as: root
Using keyboard-interactive authentication.
Password:
Access denied
Using keyboard-interactive authentication.
Using keyboard-interactive authentication.
Password:
Access denied
Using keyboard-interactive authentication.
Get ready to authenticate:
You must authenticate a user before any viprcli commands can be successfully executed.
1. Change to the correct directory:
cd /opt/storageos/cli/
2. Edit the viprcli.profile file with vi:
vi viprcli.profile
3. Set the VIPR_HOSTNAME to the fully qualified domain name (FQDN) of the ViPR Controller host or the virtual IP address of your ViPR Controller configuration (ViPR Virtual IP or VIP).
Correct (where the #s are replaced with the VIP):
VIPR_HOSTNAME=##.###.###.##
Incorrect (< and > should be removed):
VIPR_HOSTNAME=<##.###.###.##>
VIPR_HOSTNAME=##.###.###.##
Incorrect (< and > should be removed):
VIPR_HOSTNAME=<##.###.###.##>
Authenticate:
1. Change to the correct directory:
cd /opt/storageos/cli/bin
2. Authenticate:
./viprcli authenticate -u root -d /tmp (you are prompted for the password)
Correct (you must see "Cookie saved successfully" before moving to the next step):
vipr1:/opt/storageos/cli/bin # ./viprcli authenticate -u root -d /tmp
Password :
root : Authenticated Successfully
/tmp/rootcookie10081 : Cookie saved successfully
Password :
root : Authenticated Successfully
/tmp/rootcookie10081 : Cookie saved successfully
Incorrect (wrong password):
vipr1:/opt/storageos/cli/bin # ./viprcli authenticate -u root -d /tmp
Password :
The token is not generated by authentication service.
Password :
The token is not generated by authentication service.
Incorrect (VIP not set correctly):
vipr1:/opt/storageos/cli/bin # ./viprcli authenticate -u root -d /tmp
Password :
Password :
HTTPSConnectionPool(host='%3C<VIP>%3E', port=4443): Max retries exceeded with url: /login (Caused by NewConnectionError('<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7fd7dd5e9990>: Failed to establish a new connection: [Errno -2] Name or service not known',))
Manual backup
1. Create the backup on each of the nodes. This is not the final and complete backup. This will create the individual backup for each of the nodes in the /data/backup directory. The complete backup will be zipped together from these individual backups with a the "download-backup" option later. This step can take several minutes depending on the size of the ViPR controller database.
./viprcli system create-backup -n ViPRBACKUPYYYYMMDD
If the below message is received the user is not authenticated. The user must be authenticated before viprcli commands can be successfully run. See Authenticate above.
vipr1:/opt/storageos/cli/bin # ./viprcli system create-backup -n ViPRBackupYYYMMDD
Error: Failed to create backup
Reason:'/opt/storageos/cli/cookie/12941 : Cookie not found : Please authenticate again'
Error: Failed to create backup
Reason:'/opt/storageos/cli/cookie/12941 : Cookie not found : Please authenticate again'
If the below message is received the user has exceeded the number of backups currently allowed by ViPR Controller. The maximum number of manually-created backup copies (0-5) that can be created is specified in the ViPR Controller UI via System > General Configuration > Backup. Once this number is reached, you are not allowed to create a new backup manually until the old ones are deleted. If the maximum number of backup copies has already been reached the request will fail. See notes for "delete-backup" command:
vipr1:/opt/storageos/cli/bin # ./viprcli system create-backup -n ViPRBackupYYYMMDD
Error: Failed to create backup
Reason:'HTTP code: 500, Server Error [ViPR internal server error. Error details: Manual backup number(5) has been up to the limit(5), no copies can be created until you manually delete the older manually created copies from the nodes.]'
Error: Failed to create backup
Reason:'HTTP code: 500, Server Error [ViPR internal server error. Error details: Manual backup number(5) has been up to the limit(5), no copies can be created until you manually delete the older manually created copies from the nodes.]'
If the below message is received there is likely at least one node down. By default, ViPR Controller will not generate a backup set when 1 or more nodes are down or unavailable in a 3 node deployment, or 2 or more nodes are down or unavailable in a 5 node deployment. You can however choose to override the default and force the creation of the backup set by using -f in the create-backup command. To check the status of your ViPR Controller nodes from the ViPR Controller UI, go to the Dashboards > Health > Services:
vipr1:/opt/storageos/cli/bin # ./viprcli system create-backup -n ViPRBackup20151020
Error: Failed to create backup
Reason:'HTTP code: 500, Server Error [ViPR internal server error. Error details: Failed to create backup(ViPRBackupYYYYMMDD) on nodes([<IPs of the ViPR Controller nodes>]). Probable cause:Node is unavailable]'
Error: Failed to create backup
Reason:'HTTP code: 500, Server Error [ViPR internal server error. Error details: Failed to create backup(ViPRBackupYYYYMMDD) on nodes([<IPs of the ViPR Controller nodes>]). Probable cause:Node is unavailable]'
The force option can be used in this case:
vipr1:/opt/storageos/cli/bin # ./viprcli system create-backup -f -n ViPRBackupYYYYMMDD
2. List the backup to confirm it was created. The user should see the backup just created:
./viprcli system list-backup
3. Combine the backups from all the nodes into the backup. This step creates the complete backup. This step can take several minutes depending on the size of the ViPR controller database. In this example the backup will be placed in the tmp directory:
./viprcli system download-backup -n ViPRBACKUP20171010 -fp /tmp/ViPRBACKUPYYYYMMDD.zip
4. Use a tool like WinSCP or FileZilla to copy /tmp/ViPRBACKUPYYYYMMDD.zip to a safe location off of the ViPR Controller nodes.
Additional Information
In the event the maximum number of manually-created backup copies has been reached, they can be deleted through the GUI or through viprcli.
GUI
System > Data Backup and Restore > select unneeded backup(s) > Delete
CLI
1. List the backup to confirm it was created. The user should see the backup just created.:
./viprcli system list-backup
2. Select a backup that can be deleted and use it in the following command:
viprcli system delete-backup -name <name>
3. Try the backup again:
Article Properties
Article Number: 000019548
Article Type: How To
Last Modified: 15 Sept 2025
Version: 4
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.