First time user's experience with database configuration...
Installing Umbraco, so far, not so good...
tl;dr: I can't get the configuration working, what's the connection string for SQL Server with Integrated Security?
The third step in the installation process, Database configuration, is giving me some problems. First of all, the help text recommends the "quick-and-simple file-based database" that does not require any additional software to use. Except it does because it immediately confronts me with the fact that it's missing files, and links to a non-existing wiki page (http://our.umbraco.org/wiki/install-and-setup/using-sql-ce-4-with-juno).
Since I do have SQL Server Express 2008 with an empty database named Umbraco I decide to go for option 1, choose Microsoft SQL Server and then add the required details.
Now our database server is configured with mixed mode authentication, so I had already mapped the built-in Network Service account (that the IIS application pool is using) to the Umbraco database with the db_owner role. Unfortunately, integrated security is not an option, so I have to enter a SQL Server username and password.
That doesn't work: Database connection initialisation failed.
If I want to go back to change a detail I have to re-enter all data, which means I can't easily spot any mistakes I may have made while entering the data. Unfortunately I have no idea what the real error is, so all I can do is:
Try option 3... Now I have to enter a connection string, the example shows a MySQL configuration, so I now have to guess what the correct SQL Server configuration would look like. Try as I might, I can't get it working, and no help form the installer because all I get is Database connection initialisation failed even though I have indicated I'm an advanced user so you might as well show me the actual exception.
So to conclude my rant: I am lost in the wizard with no way to know what exact mistake I have made. For a first time user, even with advanced knowledge, this process could be improved by:
adding the actual connection errors
documenting the (more common?) SQL Server connection string example
linking to wiki pages that actually exist
allowing the Integrated Security option for SQL Server
remembering the options that the user entered when going one step back
I am well aware of the SQL Server connection string options, and have tried several:
A) None of the connection strings work and there is no way to see why not because the error message is too generic (see first post: Database connection initialisation failed)
B) Umbraco doesn't seem to be using standard SQL Server connection strings based on what I see in the installation wizard's example (which includes a property named datalayer that is not standard for either SQL Server or MySQL).
C) I am evaluating Umbraco for the first time and using the installation wizard so if editing the web.config is needed I don't really understand why the installation wizard was created. It sure looks pretty, but are you saying I should just skip the wizard because it doesn't work or because ...?
It was just a suggestion... datalayer is not standard, but the connection string variables after are.
Is the sql user account using the dbo schema?
The wizard is useful because it adds the tables to the database and sets up the initial admin user account within Umbraco (also let's you pick a starting theme for new users)
My process
Create a sql user and blank 'umbraco' database
I give the new sql user as db_owner of 'umbraco' database using the dbo schema
I run the setup wizard and point to the blank database and use the new user credentials.
Well then the question remains: if the datalayer property is not standard, then what is the value for SQL Server 2008 Express? I did a search on this site but I couldn't find it, where is this property documented? I tried the following connection strings, but no luck:
The user account is indeed mapped to db_owner, I even tried with the (temporarily enabled) sa account, but still the same error: Database connection initialisation failed.
"It always works"
Except when it doesn't... :-) Is there a log that I could check for the actual exception?
Yeah... tried that, about 10 different variations, doesn't work. Probably an issue with write permissions on the web.config file. The problem I see is that it should be trivial to add a check for that and then warn the user in step 3 that web.config is not writable. In fact, if I remember correctly in a previous version of Umbraco that I tried some months ago there was such a check in the beginning of the installation procedure.
If I start using Umbraco for real I would consider submitting a patch for something like that, it could really improve first time user's experience with Umbraco...
Hi. I just tried to install umbraco on my localhost, with sql server express, and had the same generic problem: Database connection initialisation failed
In the end I tried to login via sql server manager studio and discovered that the problem was "error 233", googled for it and found the solution (had to make the user also db owner and also in the Security tab of the Server properties allow mixed authentication (SQL Server and Windows authentication mode) and restart the sql server express service.
I think a suggestion for improvement would be to put in the installer a better error management, if possible show the error that comes from sql server so the user has an idea on what to correct. Searching in google for "umbraco Database connection initialisation failed" will just bring nothing useful...
Also another small suggestion for improvement, as michiel said, in the Step 3, in the option "I'm an advanced user, let me put in the connection string" I see an example "datalayer=MySQL;server=192.168.2.8;user id=user;password=***;database=umbraco". As Michiel said, it would be cool to have the "datalayer" option documented. There I see only the MySQL one. Or just please put other examples also for the most important DBs, like SQL Express 2008, SQL Server 2008.
It's a cool installer but I think many people got blocked there, also a work colleague of mine lost at least 1 hour to understand what's wrong...
Thansk for considering the error management, that would help quite a lot.
First time user's experience with database configuration...
Installing Umbraco, so far, not so good...
tl;dr: I can't get the configuration working, what's the connection string for SQL Server with Integrated Security?
The third step in the installation process, Database configuration, is giving me some problems. First of all, the help text recommends the "quick-and-simple file-based database" that does not require any additional software to use. Except it does because it immediately confronts me with the fact that it's missing files, and links to a non-existing wiki page (http://our.umbraco.org/wiki/install-and-setup/using-sql-ce-4-with-juno).
Since I do have SQL Server Express 2008 with an empty database named Umbraco I decide to go for option 1, choose Microsoft SQL Server and then add the required details.
Now our database server is configured with mixed mode authentication, so I had already mapped the built-in Network Service account (that the IIS application pool is using) to the Umbraco database with the db_owner role. Unfortunately, integrated security is not an option, so I have to enter a SQL Server username and password.
That doesn't work: Database connection initialisation failed.
If I want to go back to change a detail I have to re-enter all data, which means I can't easily spot any mistakes I may have made while entering the data. Unfortunately I have no idea what the real error is, so all I can do is:
Try option 3... Now I have to enter a connection string, the example shows a MySQL configuration, so I now have to guess what the correct SQL Server configuration would look like. Try as I might, I can't get it working, and no help form the installer because all I get is Database connection initialisation failed even though I have indicated I'm an advanced user so you might as well show me the actual exception.
So to conclude my rant: I am lost in the wizard with no way to know what exact mistake I have made. For a first time user, even with advanced knowledge, this process could be improved by:
Umbraco uses a standard sql server connection string.. modify it in the web.config to use integrated security
go here for reference : http://www.connectionstrings.com/sql-server-2008
Hi Daniel,
I am well aware of the SQL Server connection string options, and have tried several:
A) None of the connection strings work and there is no way to see why not because the error message is too generic (see first post: Database connection initialisation failed)
B) Umbraco doesn't seem to be using standard SQL Server connection strings based on what I see in the installation wizard's example (which includes a property named datalayer that is not standard for either SQL Server or MySQL).
C) I am evaluating Umbraco for the first time and using the installation wizard so if editing the web.config is needed I don't really understand why the installation wizard was created. It sure looks pretty, but are you saying I should just skip the wizard because it doesn't work or because ...?
It was just a suggestion... datalayer is not standard, but the connection string variables after are.
Is the sql user account using the dbo schema?
The wizard is useful because it adds the tables to the database and sets up the initial admin user account within Umbraco (also let's you pick a starting theme for new users)
My process
Always works.
Well then the question remains: if the datalayer property is not standard, then what is the value for SQL Server 2008 Express? I did a search on this site but I couldn't find it, where is this property documented? I tried the following connection strings, but no luck:
The user account is indeed mapped to db_owner, I even tried with the (temporarily enabled) sa account, but still the same error: Database connection initialisation failed.
"It always works"
Except when it doesn't... :-) Is there a log that I could check for the actual exception?
What version of Umbraco?
Should look something like this in the web.config
4.7.0
I'm still in the installation wizard, web.config contains this appSetting:
That's probably because I haven't finished the installation wizard yet, which is not possible until I can resolve this issue.
Should I report this as a bug in the installation wizard?
Not sure if it's a bug..
Why not just edit the web.config and finish the installation.. should be fine.
Okay!
But if there is a problem adding my entered data into the web.config the wizard should just display an error message saying so.
If that's not considered a bug, then the wizard is not really a "wizard", although it does look good :-)
I see how you'd think that...
Instead of entering it in the web.config.. add the connection string during the database step of the wizard.
Yeah... tried that, about 10 different variations, doesn't work. Probably an issue with write permissions on the web.config file. The problem I see is that it should be trivial to add a check for that and then warn the user in step 3 that web.config is not writable. In fact, if I remember correctly in a previous version of Umbraco that I tried some months ago there was such a check in the beginning of the installation procedure.
If I start using Umbraco for real I would consider submitting a patch for something like that, it could really improve first time user's experience with Umbraco...
Understood fully... give full permissions to Network Service account and rerun the installer.
Thanks for your help Daniel!
I'm assuming that worked.. Awesome!
Let us know your experience with Umbraco.
that worked for me as well :) - FINALLY it has been bugging my a** off as well.
Hi. I just tried to install umbraco on my localhost, with sql server express, and had the same generic problem: Database connection initialisation failed
In the end I tried to login via sql server manager studio and discovered that the problem was "error 233", googled for it and found the solution (had to make the user also db owner and also in the Security tab of the Server properties allow mixed authentication (SQL Server and Windows authentication mode) and restart the sql server express service.
I think a suggestion for improvement would be to put in the installer a better error management, if possible show the error that comes from sql server so the user has an idea on what to correct. Searching in google for "umbraco Database connection initialisation failed" will just bring nothing useful...
Also another small suggestion for improvement, as michiel said, in the Step 3, in the option "I'm an advanced user, let me put in the connection string" I see an example "datalayer=MySQL;server=192.168.2.8;user id=user;password=***;database=umbraco". As Michiel said, it would be cool to have the "datalayer" option documented. There I see only the MySQL one. Or just please put other examples also for the most important DBs, like SQL Express 2008, SQL Server 2008.
It's a cool installer but I think many people got blocked there, also a work colleague of mine lost at least 1 hour to understand what's wrong...
Thansk for considering the error management, that would help quite a lot.
Cheers and thanks for the great CMS.
firepol
EDIT: ok, added issue here: http://umbraco.codeplex.com/workitem/30306
is working on a reply...