Reason: Server is in single user mode. Only one administrator can connect at this time.

-> I had to start SQL server in single user mode. I opened services.msc and then right clicked SQL Services and noted down the “Service name”,

-> I then started SQL Services in single user mode using below command from command prompt,

 net start MSSQL$IN2019 /m

-> It started fine, I tried connecting to the SQL server using SQLCMD and got below error,

Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : Login failed for user ”. Reason: Server is in single user mode. Only one administrator can connect at this time..

-> I tried connecting to SQL Server using SQL Server management Studio and got below same error,

TITLE: Connect to Server
Cannot connect to JBResearch\IN2019.

ADDITIONAL INFORMATION:
Login failed for user ”. Reason: Server is in single user mode. Only one administrator can connect at this time. (Microsoft SQL Server, Error: 18461)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft%20SQL%20Server&EvtSrc=MSSQLServer&EvtID=18461&LinkId=20476
BUTTONS:
OK

-> I stopped SQL services and also stopped all other SQL related services,

-> I then used below query to start the SQL server in single user mode that allows only SQLCMD to make connection,

Net Start MSSQL$IN2019 /m”SQLCMD”

-> It worked fine this time.

-> If you want to use SQL Server Management studio instead of SQLCMD, then you can use below command,

net start MSSQL$IN2019 -m"Microsoft SQL Server Management Studio - Query"

Thank You,
Vivek Janakiraman

Disclaimer:
The views expressed on this blog are mine alone and do not reflect the views of my company or anyone else. All postings on this blog are provided “AS IS” with no warranties, and confers no rights.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s