How to Export the CMDB
Last updated on August 19, 2021.
Document Status: Document Developer Quality Complete.
Intended Audience
This document is intended for use by the LSI or developer.
Introduction
The Rapid Provisioning System (RPS) allows users to export all the data sorted in the CMDB using both the RPS web GUI and PowerShell.
The exported data is exported in an XML or JSON format and allows a user to re-import the data at a later time or on another system that has RPS installed.
To learn more about the re-import process, see How to Import RPS Data Into the CMDB.
Export the CMDB Using the RPS Web GUI
From the RPS header, select Admin → Export.
Figure 1: Navigating to the RPS Export screen.
This will take you to the "Export Data" view.
If the export must be encrypted, click the Choose File button next to "Certificate File". Select the certificate to encrypt the file with.
Figure 2: Select the certificate file.
Select the data to be exported. The following individual data can be selected to export from the CMDB: Root Node(s), Target Item(s), Target Group(s), Resource Item(s), Resource Group(s), Task Map(s), and Task Item(s).
Figure 3: Select individual data to export.
Alternatively, if all data in the CMDB should be exported, check the Select All checkbox at the top of the view to select all items in the CMDB for export.
Figure 4: Select all data to export.
Once at least one item is selected for export, the Export Selected button will be enabled.
Once everything to export is selected, click the Export Selected button to begin the export process.
Figure 5: Click Export Selected.
Note
The export file will download to the default local download location configured in the current browser.
Export the CMDB Using PowerShell
Import the RPS API module.
Import-Module C:\ContentStore\Modules\Rps-Api
Run the
Export-RpsData
cmdlet.Parameter options for the
Export-RpsData
cmdlet are:Parameter Name Type Required Description Path String True Path and filename where the output file will be saved to. Ex: C:\outputs\cmdbExport.xml
Format String True Output format for the export file. Only XML and JSON are currently supported. Default: XML. TargetItems TargetItem[] False Supply an array of target items to export. ResourceItems ResourceItems[] False Supply an array of resource items to export. TaskMaps TaskMap[] False Supply an array of task maps to export. IncludeAll SwitchParameter True When selected will export all data from the CMDB, excluding security data. IncludeGlobal SwitchParameter False Switch to export all global resources, task maps, and tasks. NodeId Guid True ID of the node to be exported. All related targets and descendant targets will be included. SetLocal SwitchParameter False Set the provided NodeId as the Local in the exported data. SetLocalNodeId Guid False Set the provided SetLocalNodeId as the Local in the exported data. Force SwitchParameter False Overwrite the previously exported file, if it exists. CertificateThumbprint String False The thumbprint of the certificate that will be used to encrypt the resulting configuration file, if provided. Certificate String False The certificate that will be used to encrypt the resulting configuration file, if provided.
Export-RpsData Usage Examples
Some common ways to use the cmdlet include:
Export all data and encrypt it with a certificate thumbprint:
Export-RpsData -IncludeAll -Path "c:\temp\encryptedrps.xml" -CertificateThumbprint "2b8a73beb5da48d8ae612075428437bd677b86bb"
Export all data and encrypt it with a certificate:
$exported = Export-RpsData -IncludeAll -Path "c:\temp\encryptedrps.xml" -Certificate "C:\ContentStore\Certificates\APP.rps.local_NodeEncryption.cer"
Export a specific node in JSON format:
Export-RpsData -IncludeAll -Format json -Path "c:\temp\rpsdata.json" -NodeId f0386465-ed03-4f60-aec4-c9745fce0f7d