Importing and exporting resource-based policies
You can export and import policies from the Ranger Admin UI for cluster resiliency (backups), during recovery operations, or when moving policies from test clusters to production clusters. You can export/import a specific subset of policies (such as those that pertain to specific resources or user/groups) or clone the entire repository (or multiple repositories) via Ranger Admin UI.
Interfaces
Service Manager Page | Reports Page | |
---|---|---|
Formats | JSON |
JSON Excel CSV |
Filtering Supported | No | Yes |
Specific Service Export | Yes | Via filtering |
Filtering
When exporting from the Reports page, you can apply filters before saving the file.
Export Formats
-
Excel
-
JSON
-
CSV
Note: CSV format is not supported for importing policies.
Required User Roles
The Ranger admin user can import and export only Resource & Tag based policies. The credentials for this user are set in Ranger Configs > Advanced ranger-env in the fields labeled admin_username (default: admin/admin).
The Ranger KMS keyadmin user can import and export only KMS policies. The default credentials for this user are keyadmin/keyadmin.
Limitations
-
MariaDB: 10.1.16+
-
MySQL: 5.6.x+
-
Oracle: 11gR2+
-
PostgreSQL: 8.4+
-
MS SQL: 2008 R2+
Partial import is not supported.