Login Failed: The username or password supplied is invalid. Exceptions in sgvault.log

If you are having a problem using Vault, post a message here.
Post Reply
enicolson
Posts: 10
Joined: Thu Apr 21, 2016 5:48 pm

Login Failed: The username or password supplied is invalid. Exceptions in sgvault.log

Post by enicolson » Mon Mar 07, 2022 8:40 am

Platform:
- Windows server 2016 standard, 10.0.14393
- SQL Server 2017

Everything was working fine since 2019.

This weekend I took a backup of the database through the Vault web UI and now all logins fail with
"The username or password supplied is invalid."

Checked c:\windows\temp\sgvault\sgvault.log

I see this message in the log
"Database 'sgmaster' is already open and can only have one user at a time."

What is the cause?

enicolson
Posts: 10
Joined: Thu Apr 21, 2016 5:48 pm

Re: Login Failed: The username or password supplied is invalid. Exceptions in sgvault.log

Post by enicolson » Mon Mar 07, 2022 8:59 am

I found another post about sgmaster being in single user mode.
I stopped the sgvault web site
I started SQL server management studio and opened the object expolorer
I noted sgmaster was in single user mode
I followed these instructions:
https://docs.microsoft.com/en-us/sql/re ... rver-ver15
[except that I set it to multi user]
- In Object Explorer, connect to an instance of the SQL Server Database Engine, and then expand that instance.
- Right-click the database to change, and then select Properties.
- In the Database Properties dialog box, select the Options page.
- From the Restrict Access option, select Single. [Here I changed it from single to multi]
- If other users are connected to the database, an Open Connections message will appear. To change the property and close all other connections, select Yes.

QUESTION: how did the sgmaster database get set to single user mode? Did the backup cause this? How can I avoid this problem in the future?

Tonya
Posts: 862
Joined: Thu Jan 20, 2005 1:47 pm
Location: SourceGear

Re: Login Failed: The username or password supplied is invalid. Exceptions in sgvault.log

Post by Tonya » Mon Mar 07, 2022 10:18 am

Hello,

Glad to hear that you were able to resolve the problem.

When the Vault backup is invoked it puts the database in single user made so that changes can't be made during the process. Typically the database is then changed out of single user mode when it's complete. Without knowing all the logistics in your environment, it's really hard to tell. What I recommend is to use SQL Server back up instead of the native backup in the Vault Server. This should eliminate the problem in the future. We recommend using SQL for backups regardless.

Tonya

Post Reply