I have a fresh install of Kentico 8.2. I'm trying to create a local dev instance of our staging site. I just want to get to where I can import the site package to my local instance. Currently, when I visit the /Admin route on my local instance, I get redirected to cmsinstall/install.aspx and see the following a database creation dialog. Every field is disabled and its trying to install into the database that was created and populated when I ran the .exe installer. So, with no other options available to me I click ahead.
When the Kentico instance inexplicably tries to create all new tables over the already existing ones, I get the inevitable error:
ERROR: An error occurred: [DataConnection.HandleError]:
Query:
CREATE TABLE [CMS_Resource] (
[ResourceID] [int] IDENTITY(1,1) NOT NULL,
[ResourceDisplayName] [nvarchar](100) NOT NULL,
[ResourceName] [nvarchar](100) NOT NULL,
[ResourceDescription] [nvarchar](max) NULL,
[ShowInDevelopment] [bit] NULL,
[ResourceURL] [nvarchar](1000) NULL,
[ResourceGUID] [uniqueidentifier] NOT NULL,
[ResourceLastModified] [datetime2](7) NOT NULL,
[ResourceIsInDevelopment] [bit] NULL,
[ResourceHasFiles] [bit] NULL,
[ResourceVersion] [nvarchar](200) NULL,
[ResourceAuthor] [nvarchar](200) NULL
)
ALTER TABLE [CMS_Resource]
ADD CONSTRAINT [PK_CMS_Resource] PRIMARY KEY NONCLUSTERED ([ResourceID])
ALTER TABLE [CMS_Resource]
ADD CONSTRAINT [DEFAULT_CMS_Resource_ResourceHasFiles] DEFAULT ((0)) FOR [ResourceHasFiles]
ALTER TABLE [CMS_Resource]
ADD CONSTRAINT [DEFAULT_CMS_Resource_ShowInDevelopment] DEFAULT ((0)) FOR [ShowInDevelopment]
CREATE CLUSTERED INDEX [IX_CMS_Resource_ResourceDisplayName] ON [CMS_Resource] ([ResourceDisplayName])
CREATE NONCLUSTERED INDEX [IX_CMS_Resource_ResourceName] ON [CMS_Resource] ([ResourceName])
Caused exception: There is already an object named 'CMS_Resource' in the database.
at CMS.DataEngine.AbstractDataConnection.HandleError(String queryText, Exception ex)
at CMS.DataEngine.AbstractDataConnection.ExecuteQuery(String queryText, QueryDataParameters queryParams, QueryTypeEnum queryType, Boolean requiresTransaction)
at CMS.DataEngine.SqlInstallationHelper.RunSQLQuery(String query, IDataConnection conn, String dbSchema)
at CMS.DataEngine.SqlInstallationHelper.RunSQLScript(String fileName, IDataConnection conn, String dbSchema)
Why on earth is it even trying to create a db when there's already a fully populated one its already pointed at? More importantly, how do I get it to stop?!
For context, my install options:
- Custom,
- Web App,
- Installed to a preexisting empty database on my local SQL Server 2012 instance
- connection string: "Data Source=localhost;Initial Catalog=Kentico;Integrated Security=True;User ID=;Password=;Connect Timeout=60"
- IIS site bound to wwwroot/Kentico/CMS
- Application pool Identity set to LocalSystem
- NT_AUTHORITY/SYSTEM is added to the db with full permissions.