Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Topic author was deleted

    Sep 05, 2016 @ 06:00

    Umbraco cannot start. A connection string is configured but the Umbraco cannot connect to the database.

    The error when I try to access my website...

    Please help me. I created my first website and I was hoping that I was done, until I received this error message after publishing my website via FTP.

    I feel very lost and not sure how to fix it. I did not tinker with the web.config file except for adding SendGrib appsetting information.

    <add name="umbracoDbDSN" connectionString="Data Source=|DataDirectory|\Umbraco.sdf;Flush Interval=1;" providerName="System.Data.SqlServerCe.4.0" />
    

    I can provide other information if you like....I did not tinker with the connection string, I allowed Umbraco to do it by itself...any help would be greatly appreciated.

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 06:13
    Nicholas Westby
    1

    Did you deploy the Umbraco.sdf file that's in the App_Data folder?

    By the way, that connection string implies you are using SQL Server CE. You really shouldn't use that type of database for a fully deployed site. Instead, you should use SQL Server Express. SQL Server CE doesn't scale well at all (I believe Umbraco supports SQL Server CE just so you can tinker with Umbraco without having a very complicated install).

  • Comment author was deleted

    Sep 05, 2016 @ 06:29

    enter image description here

    I found the file but I'm not sure what you mean by deploying it. But I did deploy it locally in visual studio and everything works well and the build has no errors

    I'm not sure how I got SQL Server CE set up, Umbraco did it for me upon installation. I will try to learn to switch to it later.

    I'm sorry that I don't know a lot of this stuff....

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 06:37
    Nicholas Westby
    1

    By deploying it, I meant copying it via FTP to your server.

    If you did deploy it (which I believe your screenshot indicates), you may also have to set permissions on the App_Data folder. No idea how to do that; assuming you're using something like GoDaddy, there's probably a panel to set permissions.

    Also, some web hosts are weird about the types of things they'll allow you to do with databases, so you may want to look at their website to see if they mention anything in particular regarding databases.

    FYI, migrating from a SQL Server CE database to a SQL Server Express database is non-trivial. For example, Umbraco structures the data differently depending on which database you are using.

    Also, if you are curious, if you install Umbraco by clicking "Install" (or whatever the button says) rather than "Customize", it'll automatically choose SQL Server CE. That is likely how you got SQL Server CE set up.

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 06:49
    Nicholas Westby
    0

    By the way, make sure your deploy process isn't excluding the App_Data folder, such as in this example: http://stackoverflow.com/a/25349042/2052963

  • Comment author was deleted

    Sep 05, 2016 @ 06:50

    enter image description here

    Hmm it seems like I shouldn't tinker in App_Data.

    So I think I will look around in the panel from my hosting provider (which is http://asphostportal.com/, was recommended by this community).

    If that doesn't work, I will try to research the contents of web.config...

    Yes! I actually chose a custom installation to install an empty backoffice, and it did in fact give me the option of SQL Server CE, I will try to install Express next time...

  • Comment author was deleted

    Sep 05, 2016 @ 07:17

    My hosting provider sent me this in the email message: enter image description here

    This means there is some manual work to be done in the control panel?

    Also, I just checked that it was unchecked by default: enter image description here

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 07:21
    Nicholas Westby
    1

    Those are all SQL Server, which you can't use since your database is SQL Server CE.

    If you want to recreate things from scratch, you could use SQL Server.

    For now, though, I would guess if you just copy over the Umbraco.sdf file you'll be up and running (albeit with a subpar type of database).

  • Comment author was deleted

    Sep 05, 2016 @ 07:26

    I want to just get up and running for now and see that my website works without issues. How should I copy the Umbraco.sdf file and where?

    Do I have to configure something in my panel regarding databases?

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 07:33
    Nicholas Westby
    1

    Do you have an FTP client or can you otherwise view the files on your web server somehow (e.g., by logging into the control panel)?

    Make sure the Umbraco.sdf is in the App_Data folder. Is it?

  • Comment author was deleted

    Sep 05, 2016 @ 07:45

    enter image description here

    enter image description here

    Uh oh. I don't see Umbraco.sdf inside the App_Data folder? I thought I pubished the entire web application, but it seemed to have skipped that part. What should I do?

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 07:56
    Nicholas Westby
    0

    Based on this screenshot (with an arrow I added):

    Excluded from Project

    I'd say your Umbraco.sdf hasn't been included in your web application. Looks like you are viewing all files in the Solution Explorer and the dotted line indicates the specified item isn't included in the project. If you right click on the file and select "Include in Project" and then do another publish, perhaps that will ensure it gets copied to your web server.

  • Comment author was deleted

    Sep 05, 2016 @ 08:04

    Okay I will see if it works. If it does, I think I will just leave it alone (maybe) since the site is a single page, very simple. I plan on making another website that will also implement Merchello (excited about this) and I will try to use SQL Server Express this time. I haven't used Merchello before, I'm excited about the possibilities.

  • Nicholas Westby 2054 posts 7104 karma points c-trib
    Sep 05, 2016 @ 08:31
    Nicholas Westby
    0

    Yeah, Merhcello looks neat. Thinking about using it for some upcoming projects myself. Rusty Swayne (either the main or one of the main Merchello developers) is super friendly. Here are a couple links you might be interested in for your Merchello journey:

    Good luck.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies