We are having issues with the job “Team Foundation Server Periodic Identity Synchronization”.
Within the cycle duration not all Tfs groups are being synchronised. We have investigated the process and think we have a good understanding of how it all hangs together, but we cannot figure out why it is behaving as it is. Below I will firstly summarise our understanding of the process (obtained by testing on our test environment – trial and error) and then explain the issue we are having.
“Team Foundation Server Periodic Identity Synchronization” Job
The settings/details for this job can be found in 2 main SQL tables in the Tfs_Configuration database.
Table - tbl_RegistryItems
#\Service\Integration\Settings\ IdentitySyncCycleDuration\ 1.00:00:00
#\Service\Integration\Settings\ IdentitySyncCycleStart\ 04/27/2015 03:04:41
#\Service\Integration\Settings\ IdentitySyncFull\ False
Field - IdentitySyncFull
This can be True or False.
True a FULL synchronisation is actioned i.e. all Tfs Groups are synchronised.
False an incremental synchronisation occurs every time the job is run
Field - IdentitySyncCycleDuration
As it says, this is the cycle duration. The default is 1 day. Therefore every day the synchronisation process starts again from the beginning.
Table - tbl_jobschedule
This table shows how often each job is run. For “Team Foundation Server Periodic Identity Synchronization” the “Interval” field is set to 3600 which is 1 hour.
Therefore according to default settings the job runs incrementally every hour.
The Tfs groups which are synchronised each hour can be seen in the table tbl_group. Only active groups are synchronised and Tfs groups seem to be synchronised in SID order (for each Tfs group see the lastsync field).
Our issue is as follows
We have approx. 700 active tfs groups. Each day the process starts from the beginning and synchronises Tfs groups in SID order. Each hour a small number of Tfs groups are synchronised. Note only about 10-15 at a time. Therefore as the job only runs 24 times within the one day cycle duration, only about ½ our Tfs groups are getting synchronised. The other ½ are never getting synchronised. The only way to get all the Tfs groups synchronised would be to run a FULL sync.
I must emphasize that the job is running successfully each hour, with no errors. I can see this via the TFS Job Monitoring and also via Event Viewer.
We have a number of questions about the overall process.
- Why are all Tfs groups (and thus users) not being synchronised within the cycle duration?
- The number of Tfs groups synchronised varies each hour. What determines how many Tfs groups are synchronised each hour? The answer to this question may also answer question 1.
Any feedback/advice would be much appreciated.
Thanks
Thomas