New installation fails to start up on Mac

I had been dabbling with the self-hosted solution of Bitwarden. Let me start by saying that it is a great offering.

Today I tried to do the trial installation on my Mac and all things went smoothly, until when I tried to execute the command to “updatedb”. The command failed with the error below:

Unhandled Exception: System.Data.SqlClient.SqlException: Login failed for user ‘sa’.
at Bit.Setup.Program.MigrateDatabase(Int32 attempt) in /Users/kyle/Projects/bitwarden/core/util/Setup/Program.cs:line 285
at Bit.Setup.Program.Main(String[] args) in /Users/kyle/Projects/bitwarden/core/util/Setup/Program.cs:line 57

And trying to register a user also fails after this.

Hope to find a solution for this.

Thanks/Regards

Did you by chance run the installer any time prior and start over? Macos uses a docker volume for the database which could have been leftover from a previous install attempt. It would have a different password to access it.

1 Like

You are correct. I did try an installation before and had to redo it again. Can you please help me reconfigure it or point me to any documentation I can use to move ahead.

Many thanks.

You need to remove the old docker volume for the database. I would just re-install everything.

./bitwarden.sh stop
rm -rf bwdata
docker volume rm docker_mssql_data
./bitwarden.sh updateself
./bitwarden.sh install
1 Like

Thank you. This worked beautifully. I am now able to get the registration done to create a new user.
I will start my testing now :slight_smile:

Thanks for the great help.

1 Like