Reassigning policies
OpenStack administrators are able to reassign a policy to a new owner. This involves the possibility to migrate a policy from one cloud to another or between projects.
Warning:
Reassigning a policy only changes the database of the target NetBackup for OpenStack installation. Now that it is managed by a different NetBackup installation, the original source installation is not updated.
Use the following CLI command to reassign a policy:
nbosjm policy-reassign-policies
[--old_tenant_ids <old_tenant_id>]
[--new_tenant_id <new_tenant_id>]
[--policy_ids <policy-id>]
[--user_id <user_id>]
[--migrate_cloud {True,False}]
[--map_file <map_file>]
--old_tenant_ids <old_tenant_id> Specify old tenant ids from which policies need to reassign to new tenant. Specify multiple times to choose policies from multiple tenants.
--new_tenant_id <new_tenant_id> Specify new tenant id to which policies need to reassign from old tenant. Only one target tenant can be specified.
--policy_ids <policy-id> Specify policy ids which need to reassign to new tenant. If not provided then all the policies from old tenant will get reassigned to new tenant. Specifiy multiple times for multiple policies.
--user_id <user_id> Specify user id to which policies need to reassign from old tenant. only one target user can be specified.
--migrate_cloud {True,False} Set to True if you want to reassign policies from other clouds as well. Default if False
--map_file Provide file path(relative or absolute) including file name of reassign map file. Provide list of old policies mapped to new tenants. Format for this file is YAML.
A sample mapping file with explanations is shown below:
reassign_mappings:
- old_tenant_ids: [] #user can provide list of old_tenant_ids or
policy_ids
new_tenant_id: new_tenant_id
user_id: user_id
policy_ids: [] #user can provide list of old_tenant_ids or policy_ids
migrate_cloud: True/False #Set to True if want to reassign policies from
# other clouds as well. Default is False
- old_tenant_ids: [] #user can provide list of old_tenant_ids or
policy_ids
new_tenant_id: new_tenant_id
user_id: user_id
policy_ids: [] #user can provide list of old_tenant_ids or policy_ids
migrate_cloud: True/False #Set to True if want to reassign policies from
# other clouds as well. Default is False