The possible reason for this error “**Error loading role ‘role 1’**” is when the **Groups/Roles** returned by the LDAP server may not be present in the Denodo as a Role. In your case, the LDAP server has returned the role called “role 1”. Hence the “**role 1**” must be created on the **Administration -> Role Management** Section and granted necessary privileges to connect to it. For more information, please refer to the highlighted note portion from the [LDAP authentication process](https://community.denodo.com/docs/html/browse/7.0/vdp/administration/databases_users_and_access_rights_in_virtual_dataport/administration_of_databases_users_roles_and_their_access_rights/creating_databases#:~:text=If%20a%20role%20name%20obtained) section of the Virtual DataPort Administration Guide.
When the** Assign “allusers” role** option is selected then the Server will grant the privileges of the role “allusers” to all the users that log in successfully even if this role has not been assigned to the user in the LDAP server. That's why you were able to login when you have this option selected.
When you select the option “**use data source credentials to obtain roles**”, the LDAP server will query to obtain the role by using the credentials that you have configured for LDAP datasource. In this case, the password configured in LDAP datasource should match the password for the login user. Otherwise the role/group retrieval query fails and results in “**insufficient access to <> database**” error has occurred.
For more detailed information, I would suggest you to refer to the [Creating a database with LDAP authentication](https://community.denodo.com/docs/html/browse/7.0/vdp/administration/databases_users_and_access_rights_in_virtual_dataport/administration_of_databases_users_roles_and_their_access_rights/creating_databases#creating-a-database-with-ldap-authentication) section of the Virtual Dataport Administration Guide.
If still see the issues persist and If you are a user with valid support access then you can raise a support case in [Denodo Support Site](https://support.denodo.com/) so that our support team can help you.
Hope this helps!