Upgrade from 2005 express to 2008 r2 express - provisionsystemaccounts.sql error

Hi,

Ive been upgrading several of my clients and ran into this problem for one of them.

When doing the upgrade I got..

Looking at the error logs indicated..

2015-03-21 11:54:07.58 spid7s      Database 'master' is upgrading script 'provisionsystemaccounts.sql' from level 0 to level 2.

2015-03-21 11:54:07.59 spid7s      ----------------------------------------

2015-03-21 11:54:07.59 spid7s      Starting provisionsystemaccounts.sql ...

2015-03-21 11:54:07.59 spid7s      ----------------------------------------

2015-03-21 11:54:08.02 spid7s      Error: 15151, Severity: 16, State: 1.

2015-03-21 11:54:08.02 spid7s      Cannot find the user 'FILESERVER01\SQLServer2005MSFTEUser$FILESERVER02$ORSQLEXP', because it does not exist or you do not have permission.

2015-03-21 11:54:08.03 spid7s      Error: 912, Severity: 21, State: 2.

2015-03-21 11:54:08.03 spid7s      Script level upgrade for database 'master' failed because upgrade step 'provisionsystemaccounts.sql' encountered error 15151, state 1, severity 16. This is a serious error condition which might interfere with regular operation and the database will be taken offline. If the error happened during upgrade of the 'master' database, it will prevent the entire SQL Server instance from starting. Examine the previous errorlog entries for errors, take the appropriate corrective actions and re-start the database so that the script upgrade steps run to completion.

2015-03-21 11:54:08.03 spid7s      Error: 3417, Severity: 21, State: 3.

2015-03-21 11:54:08.03 spid7s      Cannot recover the master database. SQL Server is unable to run. Restore master from a full backup, repair it, or rebuild it. For more information about how to rebuild the master database, see SQL Server Books Online.

2015-03-21 11:54:08.03 spid7s      SQL Trace was stopped due to server shutdown. Trace ID = '1'. This is an informational message only; no user action is required.Running the Repair from the Installation centre  brings up the same error.

I noticed that the instance appears to be upgraded but basically the service wont run. I can start it but it just stops again.

So I found this which seems the same as my problem..

https://ilkirk.wordpress.com/2011/03/07/in-place-sql-upgrade-error-2005-to-2008/

Even though I can start the SQL Services using point 1 from the link above I cant connect to sql using DAC.

The sqlcmd wont work and trying to connect through SSMS.

> SQLCMD E A. Ive also tried >SQLCMD FILESERVER1\ORSQLEXP E A and get the same results

HResult 0xFFFFFFFF, Level 16, State 1

SQL Server Network Interfaces: An error occurred while obtaining the dedicated administrator connection (DAC) port.

Make sure that SQL Browser is running, or check the error log for the port number [xFFFFFFFF].

When I try to connect to DAC via SSMS I get ..

So I seem to currently have 2 problems, one using sqlcmd/DAC and the other with provisionsystemaccounts.sql.

The sqlbrowser is running but from 90 (not sure if that matters) and I have removed (following online research) the 80 and 90 binn settings from the PATH just leaving 100 but this hasnt changed the errors.

Ive tried enabling DAC using this advice below but it hasnt made any difference. The service keeps stopping and no SQLCMD action.

http://www.mssqltips.com/sqlservertip/2538/enabling-dedicated-administrator-connection-in-sql-server-2008-express-edition/

So after trying numerous options I currently stumped.

March 21st, 2015 11:49am


2015-03-21 11:54:08.02 spid7s      Cannot find the user 'FILESERVER01\SQLServer2005MSFTEUser$FILESERVER02$ORSQLEXP', because it does not exist or you do not have permission.


Did you try connecting as 

SQLCMD -S FILESERVER02\ORSQLEXP -E -A

SQLCMD -S .\ORSQLEXP -E -A

SQLCMD -S .\SQLExpress -E -A

  • Edited by dave_gona 14 hours 33 minutes ago
Free Windows Admin Tool Kit Click here and download it now
March 21st, 2015 1:04pm

Hi,

There are lot of errors in errorlog and most dangerous I can see is

Script level upgrade for database 'master' failed because upgrade step 'provisionsystemaccounts.sql' encountered error 15151, state 1, severity 16.

Now as you already did you have to login into server

net start mssqlserver /f /T3608

After this rebuild Master database using below link. Rebuilding master database rebuilds all system databases

https://msdn.microsoft.com/en-us/library/dd207003.aspx?

http://www.codeproject.com/Tips/537811/Rebuilding-Master-Database-in-SQL-Server

March 21st, 2015 1:36pm

An update to this. I can now DAC via sqlcmd.

Following the advice on
[url]https://ilkirk.wordpress.com/2011/03/07/in-place-sql-upgrade-error-2005-to-2008/[/url]

I'm at point 3
3.Issue a create login command to create the user / group youre missing, followed by the all important GO

and I'm a bit unclear on what to do. The user according to the error log is 'FILESERVER01\SQLServer2005MSFTEUser$FILESERVER02$ORSQLEXP'

and I tried
>sp_addsrvrolemember 'FILESERVER01\SQLServer2005MSFTEUser$FILESERVER02$ORSQLEXP', 'sysadmin'
>go

adding this seemed to work without error but running the repair from the installation centre bought up the exact same error as before.

So, bearing in mind using the advice from the above link
Have I added the user to the correct group?
If not how do I do that?

In the advice he also mentions..
Now why did this happen?  Well, in my situation it seems to be related to the fact that I upgraded the default instance first which also upgraded the Full Text Engine.  That, in turn, removed the Full Text Engine user group from the local groups.  In particular, I was missing <ServerName>\SQLServer2005MSFTEUser$<ServerName>$MSSQLSERVER.  Note the fact that it mentions the default instance, not the named instance!

The SQLServer2005MSFTEUser login refers to a local Windows group that is used for controlling access to the Full Text Engine.  I suspect that when I upgraded the default instance, the installer removed the group from Windows, but not necessarily from the named instance of SQL.  Once I recreated the group, granted my service account access to mirror the other similar groups, and added that login back into SQL via the DAC, everything went fine from there.

thanks,

Free Windows Admin Tool Kit Click here and download it now
March 22nd, 2015 3:24am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics