+1-888-365-2779
Try Now
More in this section

Forums / Deployment / The specified role "Administrators" already exists error while upgrading to SF4.1

The specified role "Administrators" already exists error while upgrading to SF4.1

10 posts, 0 answered
  1. martani
    martani avatar
    27 posts
    Registered:
    24 Jan 2011
    21 Apr 2011
    Link to this post
    Hi, I am trying to upgrade from SF 4.0 to SF4.1 and I am getting the following error

    The specified role "Administrators" already exists.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

    Exception Details: System.Configuration.Provider.ProviderException: The specified role "Administrators" already exists.

    Source Error: 

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace: 

    [ProviderException: The specified role "Administrators" already exists.]
       Telerik.Sitefinity.Security.Data.OpenAccessRoleProvider.CreateRole(Guid id, String roleName) +603
       Telerik.Sitefinity.Web.UI.Backend.AdministratorPane.EnsureRole(RoleDataProvider roles, RoleInfo role) +521
       Telerik.Sitefinity.Web.UI.Backend.AdministratorPane.DoWork() +85
       Telerik.Sitefinity.Web.UI.Backend.StartupWizard.wizard_FinishButtonClick(Object sender, InternalWizardNavigationEventArgs e) +242
       Telerik.Sitefinity.Web.UI.Backend.InternalWizard.OnFinishButtonClick(InternalWizardNavigationEventArgs e) +171
       Telerik.Sitefinity.Web.UI.Backend.InternalWizard.OnBubbleEvent(Object source, EventArgs e) +773
       System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +52
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3691

    I specify the database that was used by SF4.0, and I cannot get over this problem.

    The development version works well, just when I upgrade to the live server I get this error.
  2. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    08 Dec 2016
    22 Apr 2011
    Link to this post
    Hi martani,

    I looked over your issue and the problem appears to be in the database you attached where the role administrator is already created so it may be caused by some mistake in the upgrade procedure. Please take a look at documentation fotr upgrading Sitefinity 4.0 to 4.1 and this just to make sure. Make sure you attach the database and configuration files where the profile information is kept and then perform the upgrade procedure. Please feel free to notify me if the problems persists.

    Greetings,
    Stanislav Velikov
    the Telerik team

  3. martani
    martani avatar
    27 posts
    Registered:
    24 Jan 2011
    22 Apr 2011
    Link to this post
    Thank you for your answer.

    While I upgrade on my developer machine, Sitefinity doesn't create any Web.config backup (stage 5) so I'm not sure if this is causing the issue. But the upgrade is well functioning on my developer machine anyways. The problem happens once I upload the files to the server.

    "Make sure you attach the database and configuration files where the profile information is kept", can you explain more? it is said in the documentation "Deploy the upgraded website without the configuration files" (stage 9)

    Thank you.
  4. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    08 Dec 2016
    26 Apr 2011
    Link to this post
    Hi martani,

    Thank you for contacting me again. I will try to be more clear and helpful to avoid any misunderstandings.
    On your development machine you create a backup of your database and remove the configuration files of your project ( App_Data/Sitefinity/Configuration ) and perform upgrade. Then you move your project to the server where you already have Sitefinity prepared and perform the merge described at step 6 in the documentation and upgrade the project. The existing confuguration files in Sitefinity on the server will be added and the database will be upgraded too. Notify me if you experience any more problems.

    Greetings,
    Stanislav Velikov
    the Telerik team

  5. Chris
    Chris avatar
    9 posts
    Registered:
    11 Aug 2010
    19 May 2011
    Link to this post
    I am having the exact same issue as this.  I followed the instructions and I am getting this error

    The specified role "Administrators" already exists.

    I am trying to figure out why the sitefinity upgrade is trying to create all of security roles again in the database when they already exist.  I followed the instructions exactly however my upgrade also didnt create a backup of the web config so I created a new project and used that one.  Is there a flag somewhere in the webconfig to tell the upgrade to skip the creation of the security roles in the database?
  6. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    08 Dec 2016
    23 May 2011
    Link to this post
    Hi Chris,

    Sitefinity doesn`t touch your already created security roles during the upgrade. The upgrade adds new tables where needed to support the new functionality. When you deploy an upgraded website to the production environment you should merge it with the already existing files of the production site. The merge procedure is causing your problem.

    Best wishes,
    Stanislav Velikov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  7. Richa
    Richa avatar
    69 posts
    Registered:
    04 Jun 2009
    07 Jun 2011
    Link to this post
    Hello martini and Chris

    Did you happen to resolve this issue? Am facing the same problem while upgrade!

    -Thanks
    Richa Gupta
  8. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    08 Dec 2016
    07 Jun 2011
    Link to this post
    Hi Richa,

    Do you experience this at your development machine or when deploying on the server? Please note the documentation was updated since then.

    Best wishes,
    Stanislav Velikov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  9. Richa
    Richa avatar
    69 posts
    Registered:
    04 Jun 2009
    07 Jun 2011
    Link to this post
    I got it to work, thanks.
    Had a copy of code and db on my local machine:

    What I did which resulted in the error:
    1. Added the existing solution to Project Manager on my local machine.
    2. Upgraded using Project manager on my local machine.
    3. Deployed to server without Configuration folder.
    4. Restarted the website, so it obviously asked for db, new admin etc. and that is when the error occurred.

    What I did which resulted in successful upgrade:
    1. Added the existing solution to Project Manager on my local machine.
    2. Upgraded using Project manager on my local machine.
    3. Browse the website using Project manager and everything works and you have the project in the new version. Duplicate everything on the server.
  10. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    08 Dec 2016
    07 Jun 2011
    Link to this post
    Hi Richa,

    I am happy to hear you have resolved the issue. Thank you for sharing your experience with the community.

    Kind regards,
    Stanislav Velikov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
10 posts, 0 answered