Introduction
This wiki page shows all the steps needed to synchronize an external Active Directory resource with a MySQL database.
Pre-Requisites
- MySQL JDBC driver
- Active Directory JNDI connector bundle (check latest version)
- Database Table connector bundle (check latest version)
Configuration steps
- Include MySQL JDBC driver into the JEE container classpath.
- Install Active Directory JNDI connector bundle.
- Install Database Table connector bundle.
- Configure Active Directory connector instance.
- Configure Active Directory external resource.
- Configure MySQL connector instance.
- Configure MySQL external resource.
- Create a synchronization task.
- Provide user template.
- Schedule the synchronization task.
- Check your configuration.
Configure external resources
Configure synchronization
Synchronization is performed by configuring and executing a synchronization task.
A synchronization task could be started manually or automatically by providing a schedule.
Please, consider that searching for users to be synchronized involves result pagination: if your Active Directory instance is not empty but provisioned with a lot of matching users you have to put into account some delay (sometimes, more than one synchronization request).
Create a synchronization task
- Click on tab Tasks.
- Click on subtab Synchronization Tasks.
- Click on Create new task button.
- Click on Profile tab and provide the following information (Fig. Sync Task).
- Resource Name: Active Directory demo
- Create new identities: checked
- Update matched identities: checked
- Delete matched identities: checked
- Click on Save button to save the task.
Be careful not to schedule the first execution of this task before defining a user template to be used during synchronization (if you need such feature, of course).
Please, take a look at task management for more details.
Provide a user template
Specify a user template to assign default attributes, resources, roles, to each synchronized user.
- Click on tab Tasks.
- Click on subtab Synchronization Tasks.
- Click on Edit link (corresponding to User template column) in order to configure a user template.
- Click on Resources tab (Fig. User template).
- Select MySQL resource in order to assign it automatically to each new user.
- Click on Save button to save changes.
Please, take a look at task management for more details.
Schedule the task
You can start the task manually or automatically by scheduling it.
In order to schedule a task the following steps are needed.
- Click on tab Tasks.
- Click on subtab Synchronization Tasks.
- Click on Edit link.
- Click on Schedule tab to schedule task executions (Fig. Sync Task Schedule).
- Schedule execution every minute (you can use 'Every 5 minutes' template and replace '5' with '1')
- Click on Save button to save the task.
Check your configuration
- Create new user.
- Create a new user on Active Directory.
- Wait for a minute and check user presence either on Syncope and MySQL.
- Update user.
- Update created user on Active Directory by modifying the firstname.
- Wait for a minute and check user update either on Syncope and MySQL.
- Delete user.
- Delete modified user on Active Directory.
- Wait for a minute and check user deletion either on Syncope and MySQL.