Jump to content

SQLExpress with 4.0 failing - fix and question


Recommended Posts

I just installed 4.0 and everything works. Now I want to switch to SQL Express as the backend. Following the instructions here I edited the db.conf

http://www.plasticscm.com/infocenter/technical-articles/kb-how-to-configure-plastic-scm-with-sql-server.aspx

The original config for SQL CE:

<DbConfig>

<ProviderName>sqlserverce</ProviderName>

<ConnectionString>DataSource={0};Persist Security Info=False;Max Database Size=4090;Max Buffer Size = 4096;Password=;</ConnectionString>

<DatabaseSuffix></DatabaseSuffix>

</DbConfig>

Changed to a local SQL Express:

<DbConfig>

<ProviderName>sqlserver</ProviderName>

<ConnectionString>SERVER=localhost\SQLEXPRESS;trusted_connection=yes;DATABASE={0};</ConnectionString>

<DatabaseSuffix></DatabaseSuffix>

</DbConfig>

Restarted service and the database creation failed due to access denied (5). For my install, SQL Express launches by default in the built-in "Network Service" account. By default, Plastic is operating under the "Local System" account. Network Service doesn't have rights to \program files\PlasticSCM4\Server folder so the creation of the SQL Server files fails.

The solution is to either change the logon that the SQL Express service uses, or grant the "Network Service" account read/write rights to the PlasticSCM4\Server folder. This is due to Plastic creating it's databases in the program directory instead of the default data locations.

Is the data location configurable? Normally you would place the SQL files on alternate drives than the program.

Link to comment
Share on other sites

  • 1 month later...

The "DatabasePath" tags are really important. You have to specify a folder that has write privileges since the default location doesn't have such privileges. Even though I read this thread the solution was not clear to me, as I thought I had misconfigured my database connection string. The problem is really the path the repositories are saved to.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...