Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

Commit 60e8f2c

Browse files
authored
Merge pull request #4738 from yoichinak/patch-8
Fix code block
2 parents 852e400 + 30333a9 commit 60e8f2c

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

docs/relational-databases/errors-events/mssqlserver-17207-database-engine-error.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "MSSQLSERVER_17204 | Microsoft Docs"
33
ms.custom: ""
4-
ms.date: 06/03/2020
4+
ms.date: 07/10/2020
55
ms.prod: sql
66
ms.reviewer: ""
77
ms.technology: supportability
@@ -97,7 +97,7 @@ The operating system error information printed in these error messages is the ro
9797
Impersonating: DomainName\UserName
9898
```
9999
100-
1. If you are getting ```The system cannot find the file specified``` OS error = 3:
100+
1. If you are getting `The system cannot find the file specified` OS error = 3:
101101
- Review the complete path from the error message.
102102
- Ensure the disk drive and the folder path is visible and accessible from Windows Explorer.
103103
- Review the Windows Event log to find out if any problems exist with this disk drive.
@@ -107,7 +107,7 @@ The operating system error information printed in these error messages is the ro
107107
- If the file that produced the error is a transaction log file, review the information under the sections "FOR ATTACH" and "FOR ATTACH_REBUILD_LOG" of the topic [CREATE DATABASE (Transact-SQL)](../../t-sql/statements/create-database-transact-sql.md) to understand how you can recreate the missing transaction log files.
108108
- Ensure that any disk or network location [like iSCSI drive] is available before [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] attempts to access the database files on these locations. If needed create the required dependencies in Cluster Administrator or Service Control Manager.
109109
110-
1. If you're getting the ```The process cannot access the file because it is being used by another process``` operating system error = 32:
110+
1. If you're getting the `The process cannot access the file because it is being used by another process` operating system error = 32:
111111
- Use a tool like [Process Explorer](https://docs.microsoft.com/sysinternals/downloads/process-explorer) or [Handle](https://docs.microsoft.com/sysinternals/downloads/handle) from Windows Sysinternals to find out if another process or service has acquired exclusive lock on this database file.
112112
- Stop that process from accessing [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] Database files. Common examples include anti-virus programs (see guidance for file exclusions in the following [KB article](https://support.microsoft.com/help/309422/choosing-antivirus-software-for-computers-that-run-sql-server)).
113113
- In a cluster environment, make sure that the sqlservr.exe process from the previous owning node has actually released the handles to the database files. Normally this doesn't occur, but misconfigurations of the cluster or I/O paths can lead to such issues.

docs/relational-databases/errors-events/mssqlserver-5120-database-engine-error.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "MSSQLSERVER_5228 | Microsoft Docs"
33
ms.custom: ""
4-
ms.date: "04/04/2017"
4+
ms.date: 07/10/2020
55
ms.prod: sql
66
ms.reviewer: ""
77
ms.technology: supportability
@@ -34,7 +34,7 @@ ms.author: mathoma
3434
Diagnose and correct the operating system error, then retry the operation. There are multiple states that can help Microsoft narrow down the area in the product where the area is occurring.
3535

3636
### Access is denied
37-
If you are getting the ```Access is Denied``` operating system error = 5, consider these methods:
37+
If you are getting the `Access is Denied` operating system error = 5, consider these methods:
3838
- Check the permissions that are set of the file by looking at the properties of the file in Windows Explorer. [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] uses Windows groups to provision Access Control on the various file resources. Make sure the appropriate group [with names like SQLServerMSSQLUser$ComputerName$MSSQLSERVER or SQLServerMSSQLUser$ComputerName$InstanceName] has the required permissions on the database file that is mentioned in the error message. Review [Configure File System Permissions for Database Engine Access](../../2014/database-engine/configure-windows/configure-file-system-permissions-for-database-engine-access.md) for more details. Ensure that the Windows group actually includes the [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] service startup account or the service SID.
3939
- Review the user account under which the [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] service is currently running. You can use the Windows Task Manager to get this information. Look for the "User Name" value for the executable "sqlservr.exe". Also if you recently changed the [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] service account, know that the supported way to do this operation is to use the [SQL Server Configuration Manager](../sql-server-configuration-manager.md) utility.
4040
- Depending on the type of operation (opening databases during server startup, attaching a database, database restore, and so on), the account that is used for impersonation and accessing the database file may vary. Review the topic [Securing Data and Log Files](https://docs.microsoft.com/previous-versions/sql/sql-server-2008-r2/ms189128(v=sql.105)?redirectedfrom=MSDN) to understand which operation sets what permission and to which accounts. Use a tool like Windows SysInternals [Process Monitor](https://docs.microsoft.com/sysinternals/downloads/procmon) to understand if the file access is happening under the security context of the [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] instance service startup account [or Service SID] or an impersonated account.
@@ -62,21 +62,21 @@ If you are getting the ```Access is Denied``` operating system error = 5, consid
6262
### Attaching files that reside on a network-attached storage
6363
If you cannot re-attach a database that resides on network-attached storage, a message like this may be logged in the Application log.
6464
65-
```Msg 5120, Level 16, State 101, Line 1 Unable to open the physical file "\\servername\sharename\filename.mdf". Operating system error 5: (Access is denied.).```
65+
`Msg 5120, Level 16, State 101, Line 1 Unable to open the physical file "\\servername\sharename\filename.mdf". Operating system error 5: (Access is denied.).`
6666
6767
This problem occurs because [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)] resets the file permissions when the database is detached. When you try to reattach the database, a failure occurs because of limited share permissions.
6868
6969
To resolve, follow these steps:
7070
1. Use the -T startup option to start [!INCLUDE[ssNoVersion](../../includes/ssnoversion-md.md)]. Use this startup option to turn on trace flag 1802 in [SQL Server Configuration Manager](../sql-server-configuration-manager.md) (see [Trace Flags](../../t-sql/database-console-commands/dbcc-traceon-transact-sql.md) for information on 1802). For more information about how to change the startup parameters, see [Database Engine Service Startup Options](../../database-engine/configure-windows/database-engine-service-startup-options.md).
7171
7272
2. Use the following command to detach the database.
73-
```tsql
73+
```sql
7474
exec sp_detach_db DatabaseName
7575
go
7676
```
7777

7878
3. Use the following command to reattach the database.
79-
```tsql
79+
```sql
8080
exec sp_attach_db DatabaseName, '\\Network-attached storage_Path\DatabaseMDFFile.mdf', '\\Network-attached storage_Path\DatabaseLDFFile.ldf'
8181
go
8282
```

0 commit comments

Comments
 (0)