How to: Fix the error prompt to re-deploy Custom Role on Versa Director.


*This KB is for demonstration purpose

*Tested on release 22.1.x



  • The error may arise due to an inconsistency in PostgreSQL database where a stale entry for that custom role exists, while it's not an active Role on UI


Step 1: Verify that the Role does not exist on UI under Parent/Tenant ORG


From VD GUI:

  • In the Director View, Administration > Director User Management
  • Verify the custom role does not exist under Provider > Custom User Roles 
  • Verify the custom role does not exist under Organization > Custom User Roles 


#Note- In case the Role exists on UI, re-deploy that role to fix


Step 2: Check if stale entry exists in Database


From VD Shell:

  • :~$ sudo su postgres (it will prompt for password)
  • admin$ psql
  • postgres=# \c vnms
  • vnms=# SELECT * FROM faulty_rbac_roles;


For instance, stale entry Custom-Role-1 and custom-role exists in DB while the same is not present on UI


Step 3: Delete the faulty Role from the database


  • vnms=# DELETE FROM faulty_rbac_roles where role_name='Custom-Role-1';



Step 4: Verify on UI





##################################################

In case any further query, please reach out to Versa TAC