Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Bitwarden installation Create Account button does not function. #2584

Closed
1 task done
Tracked by #2480
ajkelsey opened this issue Jan 16, 2023 · 30 comments
Closed
1 task done
Tracked by #2480

New Bitwarden installation Create Account button does not function. #2584

ajkelsey opened this issue Jan 16, 2023 · 30 comments
Labels
bug bw-unified-deploy An Issue related to Bitwarden unified deployment

Comments

@ajkelsey
Copy link

Steps To Reproduce

  1. Install Bitwarden Unified from cli using docker-compose.
  2. Navigate to Bitwarden in web browser.
  3. Click create account.
  4. Enter required information and click Create Account button

Expected Result

Advancement to the next page was expected.

Actual Result

Nothing. Remained at account creation page with no changes.

Screenshots or Videos

No response

Additional Context

No response

Githash Version

Above URL returned bad gateway.

Environment Details

  • Unbuntu 22.04.1 running inside a TrueNAS Scale VM
  • Docker version 20.10.22, build 3a2c30b
  • AMD Ryzen 5, 6 cores, 12 threads, 2 GiB RAM allocated to VM

Database Image

mariadb:10

Issue-Link

#2480

Issue Tracking Info

  • I understand that work is tracked outside of Github. A PR will be linked to this issue should one be opened to address it, but Bitwarden doesn't use fields like "assigned", "milestone", or "project" to track progress.
@ajkelsey ajkelsey added bug bw-unified-deploy An Issue related to Bitwarden unified deployment labels Jan 16, 2023
@ajkelsey
Copy link
Author

ajkelsey commented Jan 16, 2023

It appears some processes were aborted.

Log file from Bitwarden container:

2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/admin.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/api.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/events.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/icons.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/identity.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/nginx.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/notifications.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/scim.ini" during parsing
2023-01-16 00:10:09,395 INFO Included extra file "/etc/supervisor.d/sso.ini" during parsing
2023-01-16 00:10:09,402 INFO RPC interface 'supervisor' initialized
2023-01-16 00:10:09,402 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2023-01-16 00:10:09,403 INFO supervisord started with pid 51
2023-01-16 00:10:10,406 INFO spawned: 'identity' with pid 52
2023-01-16 00:10:10,409 INFO spawned: 'admin' with pid 53
2023-01-16 00:10:10,411 INFO spawned: 'api' with pid 54
2023-01-16 00:10:10,415 INFO spawned: 'icons' with pid 55
2023-01-16 00:10:10,418 INFO spawned: 'nginx' with pid 56
2023-01-16 00:10:10,422 INFO spawned: 'notifications' with pid 57
2023-01-16 00:10:10,807 INFO exited: api (terminated by SIGABRT (core dumped); not expected)
2023-01-16 00:10:10,823 INFO exited: admin (terminated by SIGABRT (core dumped); not expected)
2023-01-16 00:10:10,838 INFO exited: notifications (terminated by SIGABRT (core dumped); not expected)
2023-01-16 00:10:10,866 INFO exited: identity (terminated by SIGABRT (core dumped); not expected)
2023-01-16 00:10:10,867 INFO exited: icons (terminated by SIGABRT (core dumped); not expected)

@ajkelsey
Copy link
Author

I did learn a bit more from the logs from those processes. The error for admin, api, and icons happened in Program.cs on the line that says "Host". For identity, it was in Startup.cs on line 36, "var globalSettings = services.AddGlobalSettingsServices(Configuration, Environment);".

@WiDri
Copy link

WiDri commented Jan 17, 2023

Hello,
I have the same issue. When i press the create account after the first installation, nothing happens. In the dev console i see the following error:
TypeError: Cannot read properties of null (reading 'importKey')
at useClass. (webCryptoFunction.service.ts:35:38)
at Generator.next ()
at main.5173e8c3f382cb691e42.js:54:589096
at new t (zone.js:1351:25)
at ia (main.5173e8c3f382cb691e42.js:54:588841)
at useClass.pbkdf2 (main.5173e8c3f382cb691e42.js:54:677498)
at _o. (crypto.service.ts:420:46)
at Generator.next ()
at main.5173e8c3f382cb691e42.js:54:499699
at new t (zone.js:1351:25)
write @ consoleLog.service.ts:51

@ajkelsey
Copy link
Author

Do you have the same reports in your logs as I do?

@WiDri
Copy link

WiDri commented Jan 17, 2023

No, i don't really see errors in my logs. Just nothing happens when pressing the button. It also does not produce a message in the logs.

2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/admin.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/api.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/events.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/icons.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/identity.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/nginx.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/notifications.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/scim.ini" during parsing
2023-01-17 13:36:16,615 INFO Included extra file "/etc/supervisor.d/sso.ini" during parsing
2023-01-17 13:36:16,618 INFO RPC interface 'supervisor' initialized
2023-01-17 13:36:16,619 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2023-01-17 13:36:16,619 INFO supervisord started with pid 47
2023-01-17 13:36:17,623 INFO spawned: 'identity' with pid 48
2023-01-17 13:36:17,627 INFO spawned: 'admin' with pid 49
2023-01-17 13:36:17,630 INFO spawned: 'api' with pid 50
2023-01-17 13:36:17,632 INFO spawned: 'icons' with pid 51
2023-01-17 13:36:17,635 INFO spawned: 'nginx' with pid 52
2023-01-17 13:36:17,637 INFO spawned: 'notifications' with pid 53
2023-01-17 13:36:33,487 INFO success: identity entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
2023-01-17 13:36:33,487 INFO success: admin entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
2023-01-17 13:36:33,487 INFO success: api entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
2023-01-17 13:36:33,487 INFO success: icons entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
2023-01-17 13:36:33,487 INFO success: nginx entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
2023-01-17 13:36:33,488 INFO success: notifications entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)

@WiDri
Copy link

WiDri commented Jan 17, 2023

Hi, i swithed to SSL based on this topic: dani-garcia/vaultwarden#153 now the create account is working for me.

Hope this helps for you.

@ajkelsey
Copy link
Author

I can't seem to get the SSL version to work. I made keys and put them in /etc/bitwarden. I set the env variables concerning SSL. I'm not sure what's going on here.

@justindbaur
Copy link
Member

Hi @ajkelsey can you post the full error message you are getting from /var/log/bitwarden/api.log and /var/log/bitwarden/identity.log.

@ajkelsey
Copy link
Author

api.log

--- End of inner exception stack trace ---
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindInstance(Type type, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.GetPropertyValue(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindProperty(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindNonScalar(IConfiguration configuration, Object instance, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindInstance(Type type, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.GetPropertyValue(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindProperty(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindNonScalar(IConfiguration configuration, Object instance, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindInstance(Type type, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.Bind(IConfiguration configuration, Object instance, Action`1 configureOptions)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.Bind(IConfiguration configuration, Object instance)
   at Bit.SharedWeb.Utilities.ServiceCollectionExtensions.AddGlobalSettingsServices(IServiceCollection services, IConfiguration configuration, IWebHostEnvironment environment) in /source/src/SharedWeb/Utilities/ServiceCollectionExtensions.cs:line 458
   at Bit.Api.Startup.ConfigureServices(IServiceCollection services) in /source/src/Api/Startup.cs:line 40
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.InvokeCore(Object instance, IServiceCollection services)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass9_0.<Invoke>g__Startup|0(IServiceCollection serviceCollection)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.Invoke(Object instance, IServiceCollection services)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass8_0.<Build>b__0(IServiceCollection services)
   at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.UseStartup(Type startupType, HostBuilderContext context, IServiceCollection services, Object instance)
   at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass13_0.<UseStartup>b__0(HostBuilderContext context, IServiceCollection services)
   at Microsoft.Extensions.Hosting.HostBuilder.CreateServiceProvider()
   at Microsoft.Extensions.Hosting.HostBuilder.Build()
   at Bit.Api.Program.Main(String[] args) in /source/src/Api/Program.cs:line 11
Unhandled exception. System.InvalidOperationException: Failed to convert configuration value at 'GlobalSettings:Installation:Id' to type 'System.Guid'.
 ---> System.FormatException: Unrecognized Guid format.
   at System.Guid.GuidResult.SetFailure(Boolean overflow, String failureMessageID)
   at System.Guid.TryParseGuid(ReadOnlySpan`1 guidString, GuidResult& result)
   at System.Guid..ctor(String g)
   at System.ComponentModel.GuidConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value)
   at System.ComponentModel.TypeConverter.ConvertFromInvariantString(String text)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.TryConvertValue(Type type, String value, String path, Object& result, Exception& error)
   --- End of inner exception stack trace ---

identity.log

 --- End of inner exception stack trace ---
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindInstance(Type type, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.GetPropertyValue(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindProperty(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindNonScalar(IConfiguration configuration, Object instance, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindInstance(Type type, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.GetPropertyValue(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindProperty(PropertyInfo property, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindNonScalar(IConfiguration configuration, Object instance, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.BindInstance(Type type, Object instance, IConfiguration config, BinderOptions options)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.Bind(IConfiguration configuration, Object instance, Action`1 configureOptions)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.Bind(IConfiguration configuration, Object instance)
   at Bit.SharedWeb.Utilities.ServiceCollectionExtensions.AddGlobalSettingsServices(IServiceCollection services, IConfiguration configuration, IWebHostEnvironment environment) in /source/src/SharedWeb/Utilities/ServiceCollectionExtensions.cs:line 458
   at Bit.Identity.Startup.ConfigureServices(IServiceCollection services) in /source/src/Identity/Startup.cs:line 36
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.InvokeCore(Object instance, IServiceCollection services)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass9_0.<Invoke>g__Startup|0(IServiceCollection serviceCollection)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.Invoke(Object instance, IServiceCollection services)
   at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass8_0.<Build>b__0(IServiceCollection services)
   at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.UseStartup(Type startupType, HostBuilderContext context, IServiceCollection services, Object instance)
   at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass13_0.<UseStartup>b__0(HostBuilderContext context, IServiceCollection services)
   at Microsoft.Extensions.Hosting.HostBuilder.CreateServiceProvider()
   at Microsoft.Extensions.Hosting.HostBuilder.Build()
   at Bit.Identity.Program.Main(String[] args) in /source/src/Identity/Program.cs:line 10
Unhandled exception. System.InvalidOperationException: Failed to convert configuration value at 'GlobalSettings:Installation:Id' to type 'System.Guid'.
 ---> System.FormatException: Unrecognized Guid format.
   at System.Guid.GuidResult.SetFailure(Boolean overflow, String failureMessageID)
   at System.Guid.TryParseGuid(ReadOnlySpan`1 guidString, GuidResult& result)
   at System.Guid..ctor(String g)
   at System.ComponentModel.GuidConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value)
   at System.ComponentModel.TypeConverter.ConvertFromInvariantString(String text)
   at Microsoft.Extensions.Configuration.ConfigurationBinder.TryConvertValue(Type type, String value, String path, Object& result, Exception& error)
   --- End of inner exception stack trace ---

@justindbaur
Copy link
Member

@ajkelsey Have you supplied a BW_INSTALLATION_ID and BW_INSTALLATION_KEY like defined here: https://bitwarden.com/help/install-and-deploy-unified-beta/#specify-environment-variables

@ajkelsey
Copy link
Author

Yes, I have those in settings.env.

@justindbaur
Copy link
Member

@ajkelsey Can you check the format of BW_INSTALLATION_ID maybe you accidentally pasted an extra character, the error you are getting is it failing to part that value to a valid Guid.

@ajkelsey
Copy link
Author

ajkelsey commented Jan 18, 2023

@justindbaur I used the copy feature on the website. Is there a way to bring up the same ID and KEY again so I can compare?

And to make sure I didn't paste the two in the wrong place. The ID has the dashes and the KEY does not?

I have 36 characters in the ID (including dashes, 32 without), and 20 in the KEY.

@justindbaur
Copy link
Member

@ajkelsey There is not an easy way to do that but you can always go to bitwarden.com/host and request a new one. You'll just have to export your license again with that new installation key.

But it's not even saying that it's the wrong installation id or key it's just failing to coerce the string there to a valid C# Guid. A guid should look like this b3aeadaf-f9ac-4a18-a2c5-c76521e86ad7 a set of 8-4-4-12 characters with only A through F and 1-9. You can test your guid but using it as the string in this snippet of code and seeing if it runs.

@ajkelsey
Copy link
Author

@justindbaur I ran it through the code snippet and it worked just fine. I think I'll try a new getting a new ID and KEY.

@ajkelsey
Copy link
Author

I attempted with a new id and key, no luck. Could it be my certificate?

@justindbaur
Copy link
Member

Are you using the docker run or docker compose method to start it up?

@ajkelsey
Copy link
Author

docker compose

@b3y0ndd34th
Copy link

b3y0ndd34th commented Jan 24, 2023

I have come across the same issue while running on Ubuntu 20.04 as well. I am running in a HyperV machine.

I used the ./bitwarden.sh install method and then rebuilt after editing the env file.

Now I start it using ./bitwarden.sh start

But I have also tried using the docker compose method with the same outcome. As well as docker run.

@b3y0ndd34th
Copy link

b3y0ndd34th commented Jan 25, 2023

dani-garcia/vaultwarden#153 (comment)

Apparently this is due to an error in how web browsers are handling some of the APIs, but this is by design. you can either, use an insecure browser to create the accounts, as that seems to be the only time these API are called. See next comment about using localhost to bypass.

However that information about the API only being called at creation is incorrect now. Considering that article is from 2018 I am not surprised. I have not been able to log into the server using an unsecure connection, unless it is on the host machine itself.

Alternatively and more preferably, Enable SSL. I have not had luck with this so far, but instructions can be found here:
https://github.com/dani-garcia/vaultwarden/wiki/Enabling-HTTPS

If you get REALLY Desperate... On Chrome, open chrome://flags and search for the flag "Insecure origins treated as secure". Add the insecure context domains you want to test on and relaunch the browser. Works for me.

The same can be accomplished in Edge by typing EDGE://FLAGS into the url bar and searching the same way as you do with Chrome.

I haven't figured out the right combination for FireFox yet.

@b3y0ndd34th
Copy link

Previously people were using Edge or Firefox to get around this, but they have baked in some of the changes from chrome with the Cryptographic API blocks on unsecure pages.

I fought with Internet Explorer, but it had issues loading the login landing page from the very beginning.

One more tid bit of information.... you can also bypass this error by using the machine that bitwarden is installed on by using a local host connection. localhost is considered a secure origin https://www.chromium.org/Home/chromium-security/prefer-secure-origins-for-powerful-new-features

“Secure origins” are origins that match at least one of the following (scheme, host, port) patterns:

(https, *, *)

(wss, *, *)

(*, localhost, *)

(*, 127/8, *)

(*, ::1/128, *)

(file, *, —)

(chrome-extension, *, —)

So you should be able to use Web Cryptographi Api on http://localhost using the machine that bitwarden is installed on in order to create accounts as well.

@kspearrin
Copy link
Member

Are you using SSL? Are you getting errors in the browser console?

Bitwarden requires HTTPS, either from a provided cert or fronting the container with a proxy that has HTTPS. This should like what would happen without HTTPS.

@haraldinho2000
Copy link

haraldinho2000 commented Jan 26, 2023

I can't seem to get the SSL version to work. I made keys and put them in /etc/bitwarden. I set the env variables concerning SSL. I'm not sure what's going on here.

Did you chain host certificate, intermediate certificate and your CA certificate in the ssl.crt (and in this order)?

I have three files in my ./bitwarden directory ssl.crt, ssl.key and ca.crt, and the ssl.crt contains the three above mentioned certs in one file, right below each other.

Excerpt from my settings.env file pertaining to SSL

BW_PORT_HTTP=4080
BW_PORT_HTTPS=4443

BW_ENABLE_SSL=true
BW_ENABLE_SSL_CA=true

@ajkelsey
Copy link
Author

@haraldinho2000
I am using a self-signed certificate. The bitwarden docs didn't require chaining. I did import the cert into windows as directed.

@kspearrin
I'm trying to use SSL, but I am not having luck. I receive a connection refused error when attempting to connect.

@ajkelsey
Copy link
Author

Ok. This is what I have done. I uninstalled all of the Unified containers and images. I reinstalled with a new self-signed certificate and made some minor changes to the config. In settings.env, I made my domain name the ip address of the machine, and re-configured the cert and key path.

docker compose up and it started installing. However, the admin process kept getting terminated. This is different than what I have posted above where several were getting terminated.

bitwarden-bitwarden-1  | 2023-01-28 23:50:51,793 INFO supervisord started with pid 48
bitwarden-bitwarden-1  | 2023-01-28 23:50:52,796 INFO spawned: 'identity' with pid 49
bitwarden-bitwarden-1  | 2023-01-28 23:50:52,797 INFO spawned: 'admin' with pid 50
bitwarden-bitwarden-1  | 2023-01-28 23:50:52,799 INFO spawned: 'api' with pid 51
bitwarden-bitwarden-1  | 2023-01-28 23:50:52,800 INFO spawned: 'icons' with pid 52
bitwarden-bitwarden-1  | 2023-01-28 23:50:52,801 INFO spawned: 'nginx' with pid 53
bitwarden-bitwarden-1  | 2023-01-28 23:50:52,803 INFO spawned: 'notifications' with pid 54
bitwarden-bitwarden-1  | 2023-01-28 23:51:08,461 INFO success: identity entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
bitwarden-bitwarden-1  | 2023-01-28 23:51:08,461 INFO success: admin entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
bitwarden-bitwarden-1  | 2023-01-28 23:51:08,462 INFO success: api entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
bitwarden-bitwarden-1  | 2023-01-28 23:51:08,462 INFO success: icons entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
bitwarden-bitwarden-1  | 2023-01-28 23:51:08,462 INFO success: nginx entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
bitwarden-bitwarden-1  | 2023-01-28 23:51:08,462 INFO success: notifications entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
bitwarden-bitwarden-1  | 2023-01-28 23:51:15,084 INFO exited: admin (terminated by SIGSEGV (core dumped); not expected)
bitwarden-bitwarden-1  | 2023-01-28 23:51:16,088 INFO spawned: 'admin' with pid 210
bitwarden-bitwarden-1  | 2023-01-28 23:51:31,110 INFO success: admin entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)

@kspearrin
Copy link
Member

Looks like the admin service is failing. Check out the logs in /etc/bitwarden/logs/admin.log and see why.

@ajkelsey
Copy link
Author

It looks like it cannot connect to the database. I tried changing BW_DB_SERVER to the ip address with no success.

2023-01-29 20:55:00.274 +00:00 [INF] Starting job DeleteSendsJob at "2023-01-29T20:55:00.2713229Z".
2023-01-29 20:55:00.494 +00:00 [ERR] Error performing DeleteSendsJob.
MySqlConnector.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts.
   at MySqlConnector.Core.ServerSession.ConnectAsync(ConnectionSettings cs, MySqlConnection connection, Int32 startTickCount, ILoadBalancer loadBalancer, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ServerSession.cs:line 433
   at MySqlConnector.Core.ConnectionPool.ConnectSessionAsync(MySqlConnection connection, String logMessage, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 363
   at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 94
   at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 124
   at MySqlConnector.MySqlConnection.CreateSessionAsync(ConnectionPool pool, Int32 startTickCount, Nullable`1 ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/MySqlConnection.cs:line 915
   at MySqlConnector.MySqlConnection.OpenAsync(Nullable`1 ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/MySqlConnection.cs:line 406
   at MySqlConnector.MySqlConnection.Open() in /_/src/MySqlConnector/MySqlConnection.cs:line 369
   at Microsoft.EntityFrameworkCore.ServerVersion.AutoDetect(String connectionString)
   at Bit.Infrastructure.EntityFramework.EntityFrameworkServiceCollectionExtensions.<>c__DisplayClass0_0.<AddEFRepositories>b__0(DbContextOptionsBuilder options) in /source/src/Infrastructure.EntityFramework/EntityFrameworkServiceCollectionExtensions.cs:line 31
   at Microsoft.Extensions.DependencyInjection.EntityFrameworkServiceCollectionExtensions.<>c__DisplayClass1_0`2.<AddDbContext>b__0(IServiceProvider p, DbContextOptionsBuilder b)
   at Microsoft.Extensions.DependencyInjection.EntityFrameworkServiceCollectionExtensions.CreateDbContextOptions[TContext](IServiceProvider applicationServiceProvider, Action`2 optionsAction)
   at Microsoft.Extensions.DependencyInjection.EntityFrameworkServiceCollectionExtensions.<>c__DisplayClass17_0`1.<AddCoreServices>b__0(IServiceProvider p)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitCache(ServiceCallSite callSite, RuntimeResolverContext context, ServiceProviderEngineScope serviceProviderEngine, RuntimeResolverLock lockType)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitScopeCache(ServiceCallSite callSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitCache(ServiceCallSite callSite, RuntimeResolverContext context, ServiceProviderEngineScope serviceProviderEngine, RuntimeResolverLock lockType)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitScopeCache(ServiceCallSite callSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.DynamicServiceProviderEngine.<>c__DisplayClass2_0.<RealizeService>b__0(ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(Type serviceType, ServiceProviderEngineScope serviceProviderEngineScope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)
   at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)
   at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider)
   at Bit.Infrastructure.EntityFramework.Repositories.BaseEntityFrameworkRepository.GetDatabaseContext(IServiceScope serviceScope) in /source/src/Infrastructure.EntityFramework/Repositories/BaseEntityFrameworkRepository.cs:line 31
   at Bit.Infrastructure.EntityFramework.Repositories.SendRepository.GetManyByDeletionDateAsync(DateTime deletionDateBefore) in /source/src/Infrastructure.EntityFramework/Repositories/SendRepository.cs:line 36
   at Bit.Admin.Jobs.DeleteSendsJob.ExecuteJobAsync(IJobExecutionContext context) in /source/src/Admin/Jobs/DeleteSendsJob.cs:line 26
   at Bit.Core.Jobs.BaseJob.Execute(IJobExecutionContext context) in /source/src/Core/Jobs/BaseJob.cs:line 19
2023-01-29 20:55:00.498 +00:00 [INF] Finished job DeleteSendsJob at "2023-01-29T20:55:00.4982816Z".
2023-01-29 20:55:16.113 +00:00 [INF] Migrating database.

@ajkelsey
Copy link
Author

ajkelsey commented Jan 29, 2023

I got it working!

I set BW_DB_SERVER=db to match the settings.env example provided.

@Cognitheurge
Copy link

Is this still a known issue when using a reverse proxy like Traefik to provide SSL?

@JvdMaat
Copy link

JvdMaat commented Jan 3, 2025

Hi, i swithed to SSL based on this topic: dani-garcia/vaultwarden#153 now the create account is working for me.

Hope this helps for you.

This helped me. I could not get the "Create Account" button to do anything over HTTP.
I added this to my swag nginx reverse proxy, and now it's working like a charm.
(Just had it running over HTTP direct to avoid any proxy issues. Turns out HTTPS is mandatory for bitwarden)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug bw-unified-deploy An Issue related to Bitwarden unified deployment
Projects
None yet
Development

No branches or pull requests

8 participants