Various problems may occur when running SQL Server 2012 in Hyper-V or VMWare environment

Article translations Article translations
Article ID: 2799534 - View products that this article applies to.
Expand all | Collapse all

Symptoms

Consider the following scenario:
  • You try to run Microsoft SQL Server 2012 in a Hyper-V or VMware environment that is running Windows Server 2012.
  • You select a non-default hard disk drive, a hard disk other than drive C: for example, for either the shared features and the instance root directory or the database file(s) are hosted on a non-OS drive and that drive is showing as a removable storage or removable disk in Windows Explorer.
  • SQL Server is configured to run under an account other than a local system account.
  • The Portable Device Enumerator Service (Wpdbusenum.dll) version is lower than 6.2.9200.16548 [GDR] / 6.2.9200.20652 [QFE].
  • Windows Security Policy defined for Object Access [either local policy or group policy] as shown in the following screenshots:

    Collapse this imageExpand this image
    2903666



    Collapse this imageExpand this image
    2903667

In this scenario, you may experience one of more of the following issues:

Issue 1: The installation process fails and you receive an error message

The installation process fails, and you receive an error message that resembles the following:

Attempted to perform an unauthorized operation

Additionally, you receive the following error messages in the Summary.txt and Detail.txt files that are found in the SQL Server setup log folder:

Summary.txt
An error occurred during the setup process of the feature

Detail.txt
Attempted to perform an unauthorized operation.
HResult : 0x84bb0001
FacilityCode : 1211 (4bb)
ErrorCode : 1 (0001)
Data:
WatsonData = MSSQLSERVER
DisableRetry = true
Inner exception type: System.UnauthorizedAccessException

Note This issue also occurs when you try to perform aslipstream installation of SQL Server 2012 Service Pack 1 (SP1).

Issue 2: One or more SQL Server 2012 databases do not come online when SQL Server starts

One or more of your SQL Server 2012 databases sometimes do not come online when SQL Server starts after the computer is restarted. This issue may be sporadic. For example, the database may not come online after several restarts, but the database does come online after another restart. However, the virtual machine does not come online after another restart.

Additionally, the status of the SQL Server service does not change when you restart the virtual machine. If the databases does not come online when the SQL Server is first started after the restart, the database will not come online no matter how many times the SQL Server service is restarted.
However, if the database does come online, this issue does not affect the databases coming online when you restart the SQL Server service.

When this issue occurs, one or more of the following error messages may be logged in the SQL Server error log:

Error: 17207, Severity: 16, State: 1
File activation failure. The physical file name "<x:\yourpath\databaselogfilename.ldf>" may be incorrect.

Error: 17207, Severity: 16, State: 1
File activation failure. The physical file name "<x:\yourpath\databasedatafilename.mdf>" may be incorrect.

Error: 17207, Severity: 16, State: 1
File activation failure. The physical file name "<x:\yourpath\databasedatafilename.ndf>" may be incorrect.

Error: 5120, Severity: 16, State: 5.
FileMgr::StartLogFiles: Operating system error 2(The system cannot find the file specified.) occurred while creating or opening file '<x:\yourpath\databasedatafilename.ldf>'. Diagnose and correct the operating system error, and retry the operation.

Error: 5120, Severity: 16, State: 5.
FileMgr::StartLogFiles: Operating system error 2(The system cannot find the file specified.) occurred while creating or opening file '<x:\yourpath\databasedatafilename.mdf>'. Diagnose and correct the operating system error, and retry the operation.

Error: 5120, Severity: 16, State: 5.
FileMgr::StartLogFiles: Operating system error 2(The system cannot find the file specified.) occurred while creating or opening file '<x:\yourpath\databasedatafilename.ndf>'. Diagnose and correct the operating system error, and retry the operation.

Also, the status of the database is Recovery Pending:

Collapse this imageExpand this image
2903682


An error message that resembles the following is logged in the Security Event log:

Log Name: Security
Source: Microsoft-Windows-Security-Auditing
Date: 10/2/2013 10:07:08 PM
Event ID: 4656
Task Category: Removable Storage
Level: Information
Keywords: Audit Failure
User: N/A
Computer: TX326234-1.lab326234.lab
Description:
A handle to an object was requested.

Subject:
Security ID: LAB326234\SQLSVC
Account Name: SQLSVC
Account Domain: LAB326234
Logon ID: 0x1B49BC

Object:
Object Server: Security
Object Type: File
Object Name: E:\DATA\Object_Access_test1.mdf
Handle ID: 0x0

Resource Attributes: -

Process Information:
Process ID: 0x704
Process Name: C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\Binn\sqlservr.exe

Access Request Information:
Transaction ID: {00000000-0000-0000-0000-000000000000}
Accesses: READ_CONTROL
WRITE_DAC
WRITE_OWNER
SYNCHRONIZE
ReadData (or ListDirectory)
WriteData (or AddFile)
AppendData (or AddSubdirectory or CreatePipeInstance)
ReadEA
WriteEA
ReadAttributes
WriteAttributes

Access Reasons: -
Access Mask: 0x1E019F
Privileges Used for Access Check: -
Restricted SID Count: 0



Resolution

To resolve this issue, follow these steps:
  1. Install the cumulative update that is described in the following article in the Microsoft Knowledge Base:
    2811670 Issues when the Audit object access policy is enabled on Removable Storage in Windows 8 or Windows Server 2012
  2. Restart the Portable Device Enumerator Service.
  3. Force an update of group policy. To do this, type the following at an administrative command prompt and then press Enter:

    gpupdate /force
  4. Restart the guest virtual machine two times for the change to take effect.

Workaround

To work around this issue, use one of the following methods:
  • Disable the HotAdd/HotPlug capability in VMware. For more information about how to do this, go to the following VMWare website:
    http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1012225
    Note Microsoft provides third-party contact information to help you find technical support. This contact information may change without notice. Microsoft does not guarantee the accuracy of this third-party contact information.
  • Change the user account that is running the SQL Server services to a local system account.

    Note We do not recommend that you change the user account that is running the SQL Server services to a local system account.
  • Disable auditing of object access.

    Note Typically, we do not recommend that you disable auditing of object access.

More information

The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, about the performance or reliability of these products.

References

For more information about the Gpupdate command, visit the following TechNet website:

http://technet.microsoft.com/en-us/library/hh852337.aspx

For more information about audit object access, visit the following TechNet website:

http://technet.microsoft.com/en-us/library/cc776774(v=ws.10).aspx

Properties

Article ID: 2799534 - Last Review: October 29, 2013 - Revision: 9.0
Applies to
  • Microsoft SQL Server 2012 Enterprise
  • Microsoft SQL Server 2012 Standard
  • Microsoft SQL Server 2012 Developer
  • Microsoft SQL Server 2012 Web
  • Microsoft SQL Server 2012 Express
Keywords: 
kbtshoot kbsurveynew kbexpertiseinter KB2799534

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com