Microsoft Knowledge Base Article
This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved.
Terms
of Use |
Trademarks
Article ID: 918693 - Last Review: March 16, 2007 - Revision: 1.3
Error message when you install SQL Server Express Edition Service Pack 1 or SQL Server 2005 Express Edition with Advanced Services: "SQL Server Setup did not have the administrator permissions required to rename a file"
Bug #: 430698 (SQLBUDT)
When you install Microsoft SQL Server 2005 Express Edition
Service Pack 1 (SP1) or SQL Server 2005 Express Edition with Advanced Services
on an instance of SQL Server 2005 Express Edition, you receive an error message
that resembles the following:
SQL Server Setup did not
have the administrator permissions required to rename a file: c:\Program
Files\Microsoft SQL Server\MSSQL.1\MSSQL\Template
Data\mssqlsystemresource1.ldf. To continue, verify that the file exists, and
either grant administrator permissions to the account currently running Setup
or log in with an administrator account. Then run SQL Server Setup
again.
This problem occurs because a user instance is running when
you install SQL Server 2005 Express Edition SP1 or SQL Server 2005 Express
Edition with Advanced Services.
When the Setup program tries to rename
the Mssqlsystemresource1.mdf file to Mssqlsystemresource.mdf, the rename
attempt fails. This behavior occurs because the user instance is using the
original copy of the Mssqlsystemresource.mdf file.
Note Even if you stop the parent instance of SQL Server Express
Edition, you still experience this problem because the user instance is a
separate instance of SQL Server Express Edition and is still
running.
To work around this problem, follow these steps:
- Start the Sqlcmd utility (Sqlcmd.exe) at a command prompt,
and then connect to the parent instance of SQL Server Express
Edition.
- Disable user instances by using the following statement:
EXEC sp_configure ‘user instances enabled’,0
GO
RECONFIGURE
GO
- Determine the pipe name of any active user instances by
running the following statement:
SELECT owning_prinicipal_name, instance_pipe_name FROM sys.dm_os_child_instances WHERE heart_beat = ‘alive’
GO
- Connect to each listed user instance, and then shut each
user instance down by using the following statement:
sqlcmd -S np:<Pipe>
GO
SHUTDOWN WITH NOWAIT;
GO
Note <Pipe> represents the name of the
named pipe that you determine in step 3. - Reinstall SQL Server 2005 Express Edition SP1 or SQL Server
2005 Express Edition with Advanced Services.
- Connect to the parent instance of SQL Server Express
Edition by using the Sqlcmd utility.
- Re-enable the user instances by using the following
statement:
EXEC sp_configure ‘user instances enabled’,1
GO
RECONFIGURE
GO
Microsoft
has confirmed that this is a problem in the Microsoft products that are listed
in the "Applies to" section.
For more information about user instances in SQL Server
Express, visit the following Microsoft Developer Network (MSDN) Web site:
For more information about the SHUTDOWN statement, visit the
following MSDN Web site:
For more information about the
sys.dm_os_child_instances view, visit the following MSDN Web site:
APPLIES TO
- Microsoft SQL Server 2005 Express Edition
- Microsoft SQL Server 2005 Express Edition with Advanced Services
| kbsql2005setup kbsql2005express kbexpertiseadvanced kbtshoot kbprb KB918693 |
Community Feedback System
Very often, it takes hours to solve a problem. Very often, you've looked high
and low, and have tried a lot of solutions. When you finally found it, chances
are, it was because someone else helped you. Here's your chance to give back.
Use our community feedback tool to let others know what worked for you and what
didn't.
Please also understand that the community feedback system is not warranted to be
correct, it's simply a system that we've built to let people try and help each
other. If something in a feedback response doesn't make sense to you, or you're
not comfortable making changes that the feedback talks about (like registry
edits), please consult a professional.
Thank you for using kbAlertz.com Feedback System.
-- Scott Cate