locked
guid consistency between servers? RRS feed

  • Question


  • Hello - I was curious about Guid management between servers.  For example, CRM has default roles as part of its installation. Do these default roles always have the same Guids on all servers?  If I add a role to 1 server, export it and import it to another, should I expect that the imported role will have the exact same Guid?  I'm just wondering if plugin logic that queries by a particular role Guid will work consistently across servers?
    Saturday, July 20, 2013 5:19 AM

All replies

  • Hi,

    It looks like the GUIDS are consistent across servers. For example, the System Adminsitrator GUID is 886ABDD7-41D6-DF11-8537-000C2981699A across two servers.

    I hope this answers your question.

    • Proposed as answer by Roshan Mehta Saturday, July 20, 2013 5:56 AM
    Saturday, July 20, 2013 5:56 AM
  • My apologies, I take that back. I have checked this on two different servers and it appears they are NOT consistent. Below is the GUID for the System Administrator role.

    96B6FF19-F912-E111-9459-00155D04DC01
    33B8FFF1-9FAB-E211-B212-00155D04DC07

    The example I posted previously was for two systems where one was an exact backup of the other, hence why the GUIDs were identical.

    • Proposed as answer by Roshan Mehta Saturday, July 20, 2013 10:28 PM
    Saturday, July 20, 2013 10:28 PM
  • Hi Rosco - Thanks for the followup.  So if I have business logic in my plugin that needs to validate membership to a particular role then how should I manage that between servers?

    Is there some other role indicator that I should use besides Guid for the comparison?

    Or is special handling for server Guid syncronization a matter-of-fact necessity, no getting around it, in CRM?

    Monday, July 22, 2013 4:50 AM
  • Hi,

    In your plug-in you should consider retrieving Security Roles by their name rather than by the GUID. This will work as long as no one changes the name of a Security Role that has been exported from one system into another.

    I hope this helps.

    • Proposed as answer by Roshan Mehta Monday, July 22, 2013 7:55 AM
    Monday, July 22, 2013 7:55 AM