nextcloud / vm

💻☁📦 The Nextcloud VM (virtual machine appliance), Home/SME Server and scripts for RPi (4). Community developed and maintained.
https://download.nextcloudvm.com
GNU General Public License v3.0
1.31k stars 657 forks source link

./bitwarden.sh updatedb failed #2353

Closed Mellowlynx closed 2 years ago

Mellowlynx commented 2 years ago

Steps To Reproduce

After problems yesterday, this morning I started over again. But again run intro a problem. When installing Bitwarden the database migrating database part fails.

(not a fatal error, (you can rerun that part later if needed) but the script just stops so no SSL and no vhost.)

Expected Result

That the script after the install and before updating and migrating requests the SSL and makes the vhost and then continue.

Actual Result

While migrating the error makes the script quit and the main install scripts continues to install fail2ban. (Bitwarden and fail2ban are the only two addons I selected)

Screenshots, Videos, or Pastebins

Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Bitwarden is up and running!
===================================================

visit https://<domain>
to update, run `./bitwarden.sh updateself` and then `./bitwarden.sh update`

Waiting for the DB to come online...
 _     _ _                         _
| |__ (_) |___      ____ _ _ __ __| | ___ _ __
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.25.0, build unknown

2022.5.1: Pulling from bitwarden/setup
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Migrating database.
Unhandled exception. System.Data.SqlClient.SqlException (0x80131904): A severe error occurred on the current command.  The results, if any, should be discarded.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
   at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite, String method)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite, String methodName)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at Bit.Migrator.DbMigrator.MigrateMsSqlDatabase(Boolean enableLogging, CancellationToken cancellationToken) in /home/runner/work/server/server/util/Migrator/DbMigrator.cs:line 50
   at Bit.Setup.Program.MigrateDatabase(Int32 attempt) in /home/runner/work/server/server/util/Setup/Program.cs:line 199
   at Bit.Setup.Program.Update() in /home/runner/work/server/server/util/Setup/Program.cs:line 161
   at Bit.Setup.Program.Main(String[] args) in /home/runner/work/server/server/util/Setup/Program.cs:line 59
ClientConnectionId:948d977c-281b-40b1-8a8f-97611fb733ef
Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!
sudo -u bitwarden ./bitwarden.sh updatedb failed
Posting notification to users that are admins, this might take a while...
Posting 'Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!' to: ncadmin
Downloading the Fail2ban Menu...

Additional Context

For now I switch to the Bitwarden hosted vault until this can be fixed.

Build Version

21.0.9

Environment

By downloading the VM

Environment Details

Hyper-V is running on a Fujitsu Primergy RX200 S8 With Windows server 2019 VM has 12 GB ram

Mellowlynx commented 2 years ago

Second try to install trough the main_menu after the rest of the install did finish and removing all docker stuff. Different error sadly :(

Migrating database.
Unhandled exception. System.Data.SqlClient.SqlException (0x80131904): A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: TCP Provider, error: 35 - An internal exception was caught)
 ---> System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
 ---> System.Net.Sockets.SocketException (104): Connection reset by peer
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   --- End of inner exception stack trace ---
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Data.SqlClient.SNI.SNIPacket.ReadFromStream(Stream stream)
   at System.Data.SqlClient.SNI.SNITCPHandle.Receive(SNIPacket& packet, Int32 timeoutInMilliseconds)
   at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, Boolean applyTransientFaultHandling, String accessToken)
   at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
   at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
   at System.Data.SqlClient.SqlConnection.Open()
   at Bit.Migrator.DbMigrator.MigrateMsSqlDatabase(Boolean enableLogging, CancellationToken cancellationToken) in /home/runner/work/server/server/util/Migrator/DbMigrator.cs:line 49
   at Bit.Setup.Program.MigrateDatabase(Int32 attempt) in /home/runner/work/server/server/util/Setup/Program.cs:line 199
   at Bit.Setup.Program.Update() in /home/runner/work/server/server/util/Setup/Program.cs:line 161
   at Bit.Setup.Program.Main(String[] args) in /home/runner/work/server/server/util/Setup/Program.cs:line 59
ClientConnectionId:0e47a126-2915-49ca-89b6-9198fa642e5a
Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!
sudo -u bitwarden ./bitwarden.sh updatedb failed
Mellowlynx commented 2 years ago

Can you update the script to allow a self-singed ssl when installing? That might fix it -> https://github.com/dotnet/SqlClient/issues/1479 And remove it when the install is done and next step is about to start

enoch85 commented 2 years ago

Thanks for your detailed report! 🙏🏻

Sorry, we only support vaild TLS (which is automatically setup during the installation), and as long as you follow the instructions it will work. I will try for myself on a test domain later tonight.

Mellowlynx commented 2 years ago

Thanks for your reply, what I read (and understand) from the post I linked, the database migration might fail due to a ssl/tls (handshake) error and disconnecting after that. Please let me know if you need more info or want to look at my system. Would love to have this fixed and be able to run it on my server again.

I have a backup, is there a easy way to switch the domain and TLS without reinstalling? Nexcloud is pretty easy, Bitwarden not so match :(

enoch85 commented 2 years ago

Ok, so I investigated a bit. What does this output say?

sudo docker logs bitwarden-mssql

enoch85 commented 2 years ago

This is not an issue, just made a successful installation here with latest master.

My guess is that you don't have enough RAM. the command above will probably tell.

My full installation output:

root@test:~# bash /var/scripts/menu.sh 
Running the main menu script...
Testing if network is OK...
Checking connection...
Downloading the Additional Apps Menu...
Downloading the Bitwarden Menu...
Downloading the Bitwarden script...
Checking if Bitwarden is already installed...
4
RAM for Bitwarden OK! (3.83 GB)
CPU for Bitwarden OK! (2)
Specifying a certain user for Bitwarden: bitwarden...
Creating the Bitwarden service...
 _     _ _                         _            
| |__ (_) |___      ____ _ _ __ __| | ___ _ __  
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \ 
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.29.2, build unknown

(!) Enter the domain name for your Bitwarden instance (ex. bitwarden.example.com): test3.danielhansson.nu

(!) Do you want to use Let's Encrypt to generate a free SSL certificate? (y/n): n

(!) Enter the database name for your Bitwarden instance (ex. vault): bwvault

2022.5.1: Pulling from bitwarden/setup
c1ad9731b2c7: Pull complete 
169ba0027942: Pull complete 
c4c86b92f556: Pull complete 
e76245086e24: Pull complete 
0bf07af7e5b6: Pull complete 
8d77db74e951: Pull complete 
3af49795dae7: Pull complete 
0fb82e569369: Pull complete 
39210f04d35c: Pull complete 
4b4677bf6dce: Pull complete 
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Downloaded newer image for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

(!) Enter your installation id (get at https://bitwarden.com/host): 0452a6f6-70f9-41f9-88fe-aeba015610b1

(!) Enter your installation key: qMuO2loUQ0aF5jyKyryv

(!) Do you have a SSL certificate to use? (y/n): n

(!) Do you want to generate a self-signed SSL certificate? (y/n): n

Generating key for IdentityServer.
Generating a RSA private key
..........................................................................................................................................................................................................++++
............................................................................................................................................................................++++
writing new private key to 'identity.key'
-----

!!!!!!!!!! WARNING !!!!!!!!!!
You are not using a SSL certificate. Bitwarden requires HTTPS to operate. 
You must front your installation with a HTTPS proxy or the web vault (and 
other Bitwarden apps) will not work properly.

Building nginx config.
Building docker environment files.
Building docker environment override files.
Building FIDO U2F app id.
Building docker-compose.yml.

Installation complete

If you need to make additional configuration changes, you can modify
the settings in `./bwdata/config.yml` and then run:
`./bitwarden.sh rebuild` or `./bitwarden.sh update`

Next steps, run:
`./bitwarden.sh start`

 _     _ _                         _            
| |__ (_) |___      ____ _ _ __ __| | ___ _ __  
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \ 
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.29.2, build unknown

Building docker environment files.
Building docker environment override files.
Building nginx config.
Building FIDO U2F app id.
Building docker-compose.yml.

Starting Bitwarden for the first time, please be patient...
 _     _ _                         _            
| |__ (_) |___      ____ _ _ __ __| | ___ _ __  
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \ 
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.29.2, build unknown

Pulling mssql         ... done
Pulling web           ... done
Pulling attachments   ... done
Pulling api           ... done
Pulling identity      ... done
Pulling sso           ... done
Pulling admin         ... done
Pulling icons         ... done
Pulling notifications ... done
Pulling events        ... done
Pulling nginx         ... done
Creating directory /home/bitwarden/bwdata/core
Creating directory /home/bitwarden/bwdata/core/attachments
Creating directory /home/bitwarden/bwdata/logs
Creating directory /home/bitwarden/bwdata/logs/admin
Creating directory /home/bitwarden/bwdata/logs/api
Creating directory /home/bitwarden/bwdata/logs/events
Creating directory /home/bitwarden/bwdata/logs/icons
Creating directory /home/bitwarden/bwdata/logs/identity
Creating directory /home/bitwarden/bwdata/logs/mssql
Creating directory /home/bitwarden/bwdata/logs/nginx
Creating directory /home/bitwarden/bwdata/logs/notifications
Creating directory /home/bitwarden/bwdata/logs/sso
Creating directory /home/bitwarden/bwdata/logs/portal
Creating directory /home/bitwarden/bwdata/mssql/backups
Creating directory /home/bitwarden/bwdata/mssql/data
Creating network "docker_default" with the default driver
Creating network "docker_public" with the default driver
Creating volume "docker_mssql_data" with default driver
Creating bitwarden-notifications ... done
Creating bitwarden-identity      ... done
Creating bitwarden-api           ... done
Creating bitwarden-icons         ... done
Creating bitwarden-web           ... done
Creating bitwarden-attachments   ... done
Creating bitwarden-events        ... done
Creating bitwarden-mssql         ... done
Creating bitwarden-sso           ... done
Creating bitwarden-admin         ... done
Creating bitwarden-nginx         ... done
2022.5.1: Pulling from bitwarden/setup
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Bitwarden is up and running!
===================================================

visit https://test3.danielhansson.nu
to update, run `./bitwarden.sh updateself` and then `./bitwarden.sh update`

Waiting for the DB to come online...
 _     _ _                         _            
| |__ (_) |___      ____ _ _ __ __| | ___ _ __  
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \ 
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.29.2, build unknown

2022.5.1: Pulling from bitwarden/setup
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Migrating database.
Migration successful.
Database update complete
Checking if test3.danielhansson.nu exists and is reachable...
Doing a DNS lookup for test3.danielhansson.nu...
Server:     9.9.9.9
Address:    9.9.9.9#53

Non-authoritative answer:
test3.danielhansson.nu  canonical name = test.danielhansson.nu.
Name:   test.danielhansson.nu
Address: 90.231.57.129

DNS seems correct when checking with nslookup!
DNS seems correct when checking with dig!
Checking if port 80 is open...
Port 80 is open on 90.231.57.129!
Checking if port 443 is open...
Port 443 is open on 90.231.57.129!
Module proxy already enabled
Considering dependency proxy for proxy_wstunnel:
Module proxy already enabled
Enabling module proxy_wstunnel.
To activate the new configuration, you need to run:
  systemctl restart apache2
Considering dependency proxy for proxy_http:
Module proxy already enabled
Enabling module proxy_http.
To activate the new configuration, you need to run:
  systemctl restart apache2
Considering dependency setenvif for ssl:
Module setenvif already enabled
Considering dependency mime for ssl:
Module mime already enabled
Considering dependency socache_shmcb for ssl:
Module socache_shmcb already enabled
Module ssl already enabled
Module headers already enabled
Enabling module remoteip.
To activate the new configuration, you need to run:
  systemctl restart apache2
/etc/apache2/sites-available/test3.danielhansson.nu.conf was successfully created.
Site 000-default already disabled
Trying to generate certs and validate them with standalone method.
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Requesting a certificate for test3.danielhansson.nu

Successfully received certificate.
Certificate is saved at: /etc/letsencrypt/live/test3.danielhansson.nu/fullchain.pem
Key is saved at:         /etc/letsencrypt/live/test3.danielhansson.nu/privkey.pem
This certificate expires on 2022-09-18.
These files will be updated when the certificate renews.
Certbot has set up a scheduled task to automatically renew this certificate in the background.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
If you like Certbot, please consider supporting our work by:
 * Donating to ISRG / Let's Encrypt:   https://letsencrypt.org/donate
 * Donating to EFF:                    https://eff.org/donate-le
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Generating DH parameters, 2048 bit long safe prime
.................................................+...................................................................................................+.........................................................................................+...............................................................................................................................................................................................................................................................................................+..+...............................+...........+..................................................................................................................................+...................................................+..............................................................................+..................................................................................................................................................................................................................................................................................+..................................................................................................................................................................................................................................................+.....+.........+.....................................................+.................................+.+..........................................+................+.............................................................................................................................................................................................................................................................+.......................................................................................+..................................................................................+................................................+.......................+.....................+..................+.+...............................................................................................................................................................................................................+.....................................................................................................+............................+..........................................................................+............................................................................................................................+..............................+..........+......................................................................+.................................................................................................................................................................................................................+..................................................................................................................................................................................+.......................................+.............................................................+...................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................+........................................................+..........................................................................+.......................................................................................+........................................................................................+.....................................................................................................................+.........................................................+...............................................................................................................................................+............+.................................................................+....................................................................................................................................................................................+............................................................................................................................................................................................................................................+..............................................................................................................................................................................+.............................................................+................................................................................................+.............................................+.................................................................................................................................................................................+...........................................................................................................................+..................+........................................+........................................................................................+..................................................................................................................+........................................................................................+......................+........................................................+..................+.....+.............................................................+...................................................................................................................................................................................................................................................................................................................................+.......................................+............................................................................................................................................................................................................................................................................................................+........................................................................................................................................+..........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................+...................................................................................+.............................................................................................................................................................................................................................+..........................+..................................................................................................................................................................................................................................................................................................+.............................................................................+...................................................................................................................................+.....................................................................................................................................................................................................................................................................................................................................................................................................................................+................................................................................................................................................................................................................................................................................................................................................................................................................+.........................+............................................................................................................................................................................................................................................................................+........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................+..........................................................................................................................................................................................................................................+......................................................................................................................................................................................................................................................................................................................................................................................+..+....................................+..........................................................................................................................................................................................................................................................................+.+.........................................................................................................................................................................................................................................................................................................+...+................................................+.....................................................................................................+...........................................................................................................................................................................................................................................................................+.....................................................................................................................................................................................................+...................................................+.......................................................................................................................+..............................................................................................................................................+...........................................................+...................................................................+...............................................................................................................................................................................................................................................................+..................+.+...................................................................................+.................................................................................................................................................................................+...............................................................................................................................................................+..........................................................................................................................................................................................................................................................................................................................................................+.................................................................................................................................................................................................................+.........................................................................................................................................................................................................................................................................................+........................................................................................................................................................................................................................+..........................+..........................................................................................+...................+............................................................+........................................................................................................................+..........+...................................................................................................+................................................+.................................................................................................++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*++*
Certs are generated!
Enabling site test3.danielhansson.nu.
To activate the new configuration, you need to run:
  systemctl reload apache2
Total reclaimed space: 0B
Deleted Images:
untagged: bitwarden/setup:2022.5.1
untagged: bitwarden/setup@sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
deleted: sha256:a9bff2e5f5bd0a5562010b26fb0ca4f4f14ff06bbca26a57e0ae20ab9ce75bc9
deleted: sha256:c6a6cc7e7e8e63dc453f2e81299d212216e685fb64c5adabdbb36d1b2c0257a4
deleted: sha256:bbb6ec1a1dab6c91fa22372675b093c62d751b5e183991da3aed2d02f03ddd9d
deleted: sha256:cdc7b26f97c0f00c976bab78fa538e312c5c999ad22960c81132d03f686cfbac
deleted: sha256:e60003e9fdb85931320051338f8985b8307aa7a9afd1a7e449965458c470187b
deleted: sha256:f7ff3f3b7479ab874367d5bc4634b35f918d97df7c7777b0c94b4cad7d54a434

Total reclaimed space: 62.87MB
Total reclaimed space: 0B
Posting notification to users that are admins, this might take a while...
Posting 'Watchtower removed' to: admin
Adding cronjob for Docker weekly prune...
Docker automatic prune job added.
Mellowlynx commented 2 years ago

I removed everything bitwarden related last night, so rerunning the install now. But a part of the problem might (also) be that I use a older version of the hyper-v files. Ordered on: July 6, 2021 Can I download a newer version? Data is already save, so I'm fine with a fresh start. I will post the requested result soon.

And RAM should not be the problem, VM has 11.42 GB of it available. image

Mellowlynx commented 2 years ago

My result:

root@cloud:/var/www/nextcloud# main_menu
Running the main menu script...
Testing if network is OK...
Checking connection...
Downloading the Additional Apps Menu...
Downloading the Bitwarden Menu...
Downloading the Bitwarden script...
Checking if Bitwarden is already installed...
0
13
RAM for Bitwarden OK! (11.42 GB)
CPU for Bitwarden OK! (2)
Specifying a certain user for Bitwarden: bitwarden...
Creating the Bitwarden service...
 _     _ _                         _
| |__ (_) |___      ____ _ _ __ __| | ___ _ __
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.25.0, build unknown

(!) Enter the domain name for your Bitwarden instance (ex. bitwarden.example.com): bitwarden.<domain.tld>

(!) Do you want to use Let's Encrypt to generate a free SSL certificate? (y/n): n

(!) Enter the database name for your Bitwarden instance (ex. vault): vault

2022.5.1: Pulling from bitwarden/setup
c1ad9731b2c7: Pull complete
169ba0027942: Pull complete
c4c86b92f556: Pull complete
e76245086e24: Pull complete
0bf07af7e5b6: Pull complete
8d77db74e951: Pull complete
3af49795dae7: Pull complete
0fb82e569369: Pull complete
39210f04d35c: Pull complete
4b4677bf6dce: Pull complete
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Downloaded newer image for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

(!) Enter your installation id (get at https://bitwarden.com/host): c749a618-e096-4598-8df1-aeba015b52bc

(!) Enter your installation key: IY1gKKMpmstFtDZPhSAa

(!) Do you have a SSL certificate to use? (y/n): n

(!) Do you want to generate a self-signed SSL certificate? (y/n): n

Generating key for IdentityServer.
Generating a RSA private key
..............++++
..............................................++++
writing new private key to 'identity.key'
-----

!!!!!!!!!! WARNING !!!!!!!!!!
You are not using a SSL certificate. Bitwarden requires HTTPS to operate.
You must front your installation with a HTTPS proxy or the web vault (and
other Bitwarden apps) will not work properly.

Building nginx config.
Building docker environment files.
Building docker environment override files.
Building FIDO U2F app id.
Building docker-compose.yml.

Installation complete

If you need to make additional configuration changes, you can modify
the settings in `./bwdata/config.yml` and then run:
`./bitwarden.sh rebuild` or `./bitwarden.sh update`

Next steps, run:
`./bitwarden.sh start`

 _     _ _                         _
| |__ (_) |___      ____ _ _ __ __| | ___ _ __
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.25.0, build unknown

Building docker environment files.
Building docker environment override files.
Building nginx config.
Building FIDO U2F app id.
Building docker-compose.yml.

Starting Bitwarden for the first time, please be patient...
 _     _ _                         _
| |__ (_) |___      ____ _ _ __ __| | ___ _ __
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.25.0, build unknown

Pulling mssql         ... done
Pulling web           ... done
Pulling attachments   ... done
Pulling api           ... done
Pulling identity      ... done
Pulling sso           ... done
Pulling admin         ... done
Pulling icons         ... done
Pulling notifications ... done
Pulling events        ... done
Pulling nginx         ... done
Creating directory /home/bitwarden/bwdata/core
Creating directory /home/bitwarden/bwdata/core/attachments
Creating directory /home/bitwarden/bwdata/logs
Creating directory /home/bitwarden/bwdata/logs/admin
Creating directory /home/bitwarden/bwdata/logs/api
Creating directory /home/bitwarden/bwdata/logs/events
Creating directory /home/bitwarden/bwdata/logs/icons
Creating directory /home/bitwarden/bwdata/logs/identity
Creating directory /home/bitwarden/bwdata/logs/mssql
Creating directory /home/bitwarden/bwdata/logs/nginx
Creating directory /home/bitwarden/bwdata/logs/notifications
Creating directory /home/bitwarden/bwdata/logs/sso
Creating directory /home/bitwarden/bwdata/logs/portal
Creating directory /home/bitwarden/bwdata/mssql/backups
Creating directory /home/bitwarden/bwdata/mssql/data
Creating network "docker_default" with the default driver
Creating network "docker_public" with the default driver
Creating volume "docker_mssql_data" with default driver
Creating bitwarden-web           ... done
Creating bitwarden-identity      ... done
Creating bitwarden-notifications ... done
Creating bitwarden-icons         ... done
Creating bitwarden-events        ... done
Creating bitwarden-mssql         ... done
Creating bitwarden-api           ... done
Creating bitwarden-sso           ... done
Creating bitwarden-attachments   ... done
Creating bitwarden-admin         ... done
Creating bitwarden-nginx         ... done
2022.5.1: Pulling from bitwarden/setup
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Bitwarden is up and running!
===================================================

visit https://bitwarden.<domain>
to update, run `./bitwarden.sh updateself` and then `./bitwarden.sh update`

Waiting for the DB to come online...
 _     _ _                         _
| |__ (_) |___      ____ _ _ __ __| | ___ _ __
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.25.0, build unknown

2022.5.1: Pulling from bitwarden/setup
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Migrating database.
Unhandled exception. System.Data.SqlClient.SqlException (0x80131904): A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: TCP Provider, error: 35 - An internal exception was caught)
 ---> System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
 ---> System.Net.Sockets.SocketException (104): Connection reset by peer
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   --- End of inner exception stack trace ---
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Data.SqlClient.SNI.SNIPacket.ReadFromStream(Stream stream)
   at System.Data.SqlClient.SNI.SNITCPHandle.Receive(SNIPacket& packet, Int32 timeoutInMilliseconds)
   at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, Boolean applyTransientFaultHandling, String accessToken)
   at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
   at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
   at System.Data.SqlClient.SqlConnection.Open()
   at Bit.Migrator.DbMigrator.MigrateMsSqlDatabase(Boolean enableLogging, CancellationToken cancellationToken) in /home/runner/work/server/server/util/Migrator/DbMigrator.cs:line 49
   at Bit.Setup.Program.MigrateDatabase(Int32 attempt) in /home/runner/work/server/server/util/Setup/Program.cs:line 199
   at Bit.Setup.Program.Update() in /home/runner/work/server/server/util/Setup/Program.cs:line 161
   at Bit.Setup.Program.Main(String[] args) in /home/runner/work/server/server/util/Setup/Program.cs:line 59
ClientConnectionId:846be78f-1f35-4364-b898-b2aa4f62ce02
Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!
sudo -u bitwarden ./bitwarden.sh updatedb failed
Posting notification to users that are admins, this might take a while...
Posting 'Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!' to: user
Mellowlynx commented 2 years ago
root@cloud:/var/www/nextcloud# sudo docker logs bitwarden-mssql
2022-06-20 21:17:44.66 Server      The licensing PID was successfully processed. The new edition is [Express Edition].
2022-06-20 21:17:45.22 Server      Setup step is copying system data file 'C:\templatedata\master.mdf' to '/var/opt/mssql/data/master.mdf'.
2022-06-20 21:17:45.64 Server      Did not find an existing master data file /var/opt/mssql/data/master.mdf, copying the missing default master and other system database files. If you have moved the database location, but not moved the database files, startup may fail. To repair: shutdown SQL Server, move the master database to configured location, and restart.
2022-06-20 21:17:45.66 Server      Setup step is copying system data file 'C:\templatedata\mastlog.ldf' to '/var/opt/mssql/data/mastlog.ldf'.
2022-06-20 21:17:45.84 Server      Setup step is copying system data file 'C:\templatedata\model.mdf' to '/var/opt/mssql/data/model.mdf'.
2022-06-20 21:17:46.03 Server      Setup step is copying system data file 'C:\templatedata\modellog.ldf' to '/var/opt/mssql/data/modellog.ldf'.
2022-06-20 21:17:46.23 Server      Setup step is copying system data file 'C:\templatedata\msdbdata.mdf' to '/var/opt/mssql/data/msdbdata.mdf'.
2022-06-20 21:17:46.48 Server      Setup step is copying system data file 'C:\templatedata\msdblog.ldf' to '/var/opt/mssql/data/msdblog.ldf'.
2022-06-20 21:17:49.33 Server      Microsoft SQL Server 2017 (RTM-CU18) (KB4527377) - 14.0.3257.3 (X64)
        Nov 16 2019 01:14:50
        Copyright (C) 2017 Microsoft Corporation
        Express Edition (64-bit) on Linux (Ubuntu 16.04.6 LTS)
2022-06-20 21:17:49.36 Server      UTC adjustment: 0:00
2022-06-20 21:17:49.36 Server      (c) Microsoft Corporation.
2022-06-20 21:17:49.37 Server      All rights reserved.
2022-06-20 21:17:49.38 Server      Server process ID is 32.
2022-06-20 21:17:49.39 Server      Logging SQL Server messages in file '/var/opt/mssql/log/errorlog'.
2022-06-20 21:17:49.40 Server      Registry startup parameters:
         -d /var/opt/mssql/data/master.mdf
         -l /var/opt/mssql/data/mastlog.ldf
         -e /var/opt/mssql/log/errorlog
2022-06-20 21:17:49.44 Server      SQL Server detected 2 sockets with 1 cores per socket and 1 logical processors per socket, 2 total logical processors; using 1 logical processors based on SQL Server licensing. This is an informational message; no user action is required.
2022-06-20 21:17:49.48 Server      SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required.
2022-06-20 21:17:49.49 Server      Detected 9353 MB of RAM. This is an informational message; no user action is required.
2022-06-20 21:17:49.51 Server      Using conventional memory in the memory manager.
2022-06-20 21:17:51.05 Server      Buffer pool extension is already disabled. No action is necessary.
2022-06-20 21:17:51.96 Server      InitializeExternalUserGroupSid failed. Implied authentication will be disabled.
2022-06-20 21:17:51.97 Server      Implied authentication manager initialization failed. Implied authentication will be disabled.
2022-06-20 21:17:52.01 Server      Successfully initialized the TLS configuration. Allowed TLS protocol versions are ['1.0 1.1 1.2']. Allowed TLS ciphers are ['ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA:ECDHE-ECDSA-AES128-SHA:AES256-GCM-SHA384:AES128-GCM-SHA256:AES256-SHA256:AES128-SHA256:AES256-SHA:AES128-SHA:!DHE-RSA-AES256-GCM-SHA384:!DHE-RSA-AES128-GCM-SHA256:!DHE-RSA-AES256-SHA:!DHE-RSA-AES128-SHA'].
2022-06-20 21:17:52.28 Server      Node configuration: node 0: CPU mask: 0x0000000000000001:0 Active CPU mask: 0x0000000000000001:0. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required.
2022-06-20 21:17:52.29 Server      The maximum number of dedicated administrator connections for this instance is '1'
2022-06-20 21:17:52.35 Server      Using dynamic lock allocation.  Initial allocation of 2500 Lock blocks and 5000 Lock Owner blocks per node.  This is an informational message only.  No user action is required.
2022-06-20 21:17:52.38 Server      In-Memory OLTP initialized on lowend machine.
2022-06-20 21:17:52.59 Server      Database Instant File Initialization: enabled. For security and performance considerations see the topic 'Database Instant File Initialization' in SQL Server Books Online. This is an informational message only. No user action is required.
ForceFlush is enabled for this instance.
2022-06-20 21:17:52.64 Server      Query Store settings initialized with enabled = 1,
2022-06-20 21:17:52.66 spid6s      Starting up database 'master'.
2022-06-20 21:17:52.68 Server      Software Usage Metrics is disabled.
ForceFlush feature is enabled for log durability.
2022-06-20 21:17:54.32 spid6s      The tail of the log for database master is being rewritten to match the new sector size of 4096 bytes.  3072 bytes at offset 418816 in file /var/opt/mssql/data/mastlog.ldf will be written.
2022-06-20 21:17:56.04 spid6s      Converting database 'master' from version 862 to the current version 869.
2022-06-20 21:17:56.06 spid6s      Database 'master' running the upgrade step from version 862 to version 863.
2022-06-20 21:17:57.60 spid6s      Database 'master' running the upgrade step from version 863 to version 864.
2022-06-20 21:18:01.44 spid6s      Database 'master' running the upgrade step from version 864 to version 865.
2022-06-20 21:18:02.74 spid6s      Database 'master' running the upgrade step from version 865 to version 866.
2022-06-20 21:18:03.34 spid6s      Database 'master' running the upgrade step from version 866 to version 867.
2022-06-20 21:18:03.75 spid6s      Database 'master' running the upgrade step from version 867 to version 868.
2022-06-20 21:18:04.18 spid6s      Database 'master' running the upgrade step from version 868 to version 869.
DBSTARTUP (master, 1): FCBHeaderReadTime took 163 ms
DBSTARTUP (master, 1): FileMgrPreRecoveryTime took 225 ms
DBSTARTUP (master, 1): RedoRecTime took 291 ms
DBSTARTUP (master, 1): PhysicalRecoveryTime took 328 ms
DBSTARTUP (master, 1): PhysicalCompletionTime took 444 ms
DBSTARTUP (master, 1): RecoveryCompletionTime took 191 ms
DBSTARTUP (master, 1): UpgradeTime took 10982 ms
DBSTARTUP (master, 1): StartupInDatabaseTime took 11270 ms
DBSTARTUP (master, 1): RemapSysfiles1Time took 213 ms
2022-06-20 21:18:07.79 spid6s      SQL Server Audit is starting the audits. This is an informational message. No user action is required.
2022-06-20 21:18:07.81 spid6s      SQL Server Audit has started the audits. This is an informational message. No user action is required.
2022-06-20 21:18:08.39 spid6s      SQL Trace ID 1 was started by login "sa".
2022-06-20 21:18:08.72 spid6s      Server name is '6249fdd3f80f'. This is an informational message only. No user action is required.
2022-06-20 21:18:08.74 spid22s     Always On: The availability replica manager is starting. This is an informational message only. No user action is required.
2022-06-20 21:18:08.76 spid22s     Always On: The availability replica manager is waiting for the instance of SQL Server to allow client connections. This is an informational message only. No user action is required.
2022-06-20 21:18:08.77 spid9s      Starting up database 'mssqlsystemresource'.
2022-06-20 21:18:08.78 spid6s      Starting up database 'msdb'.
2022-06-20 21:18:08.80 spid9s      The resource database build version is 14.00.3257. This is an informational message only. No user action is required.
2022-06-20 21:18:08.84 spid9s      Starting up database 'model'.
2022-06-20 21:18:09.21 spid19s     Password policy update was successful.
2022-06-20 21:18:11.44 spid6s      The tail of the log for database msdb is being rewritten to match the new sector size of 4096 bytes.  512 bytes at offset 306688 in file /var/opt/mssql/data/MSDBLog.ldf will be written.
2022-06-20 21:18:12.04 spid9s      The tail of the log for database model is being rewritten to match the new sector size of 4096 bytes.  2048 bytes at offset 75776 in file /var/opt/mssql/data/modellog.ldf will be written.
2022-06-20 21:18:13.03 spid6s      Recovery completed for database msdb (database ID 4) in 2 second(s) (analysis 112 ms, redo 0 ms, undo 207 ms.) This is an informational message only. No user action is required.
2022-06-20 21:18:13.17 spid9s      Recovery completed for database model (database ID 3) in 2 second(s) (analysis 55 ms, redo 0 ms, undo 169 ms.) This is an informational message only. No user action is required.
2022-06-20 21:18:14.11 spid19s     A self-generated certificate was successfully loaded for encryption.
2022-06-20 21:18:14.16 spid6s      Converting database 'msdb' from version 862 to the current version 869.
2022-06-20 21:18:14.16 spid6s      Database 'msdb' running the upgrade step from version 862 to version 863.
2022-06-20 21:18:14.17 spid19s     Server is listening on [ 'any' <ipv6> 1433].
2022-06-20 21:18:14.22 spid9s      Converting database 'model' from version 862 to the current version 869.
2022-06-20 21:18:14.23 spid9s      Database 'model' running the upgrade step from version 862 to version 863.
2022-06-20 21:18:14.23 spid19s     Server is listening on [ 'any' <ipv4> 1433].
2022-06-20 21:18:14.41 spid19s     Dedicated administrator connection support was not started because it is disabled on this edition of SQL Server. If you want to use a dedicated administrator connection, restart SQL Server using the trace flag 7806. This is an informational message only. No user action is required.
2022-06-20 21:18:14.41 Logon       Error: 17187, Severity: 16, State: 1.
2022-06-20 21:18:14.41 Logon       SQL Server is not ready to accept new client connections. Wait a few minutes before trying again. If you have access to the error log, look for the informational message that indicates that SQL Server is ready before trying to connect again.  [CLIENT: 172.18.0.5]
2022-06-20 21:18:14.45 Logon       Error: 17187, Severity: 16, State: 1.
2022-06-20 21:18:14.45 Logon       SQL Server is not ready to accept new client connections. Wait a few minutes before trying again. If you have access to the error log, look for the informational message that indicates that SQL Server is ready before trying to connect again.  [CLIENT: 172.18.0.4]
2022-06-20 21:18:14.51 spid19s     SQL Server is now ready for client connections. This is an informational message; no user action is required.
2022-06-20 21:18:21.50 spid6s      Database 'msdb' running the upgrade step from version 863 to version 864.
2022-06-20 21:18:21.52 spid9s      Database 'model' running the upgrade step from version 863 to version 864.
2022-06-20 21:18:22.47 spid9s      Database 'model' running the upgrade step from version 864 to version 865.
2022-06-20 21:18:22.59 spid6s      Database 'msdb' running the upgrade step from version 864 to version 865.
2022-06-20 21:18:23.07 spid9s      Database 'model' running the upgrade step from version 865 to version 866.
2022-06-20 21:18:23.48 spid6s      Database 'msdb' running the upgrade step from version 865 to version 866.
2022-06-20 21:18:23.87 spid9s      Database 'model' running the upgrade step from version 866 to version 867.
2022-06-20 21:18:24.31 spid6s      Database 'msdb' running the upgrade step from version 866 to version 867.
2022-06-20 21:18:24.59 spid9s      Database 'model' running the upgrade step from version 867 to version 868.
2022-06-20 21:18:25.20 spid6s      Database 'msdb' running the upgrade step from version 867 to version 868.
2022-06-20 21:18:25.64 spid9s      Database 'model' running the upgrade step from version 868 to version 869.
2022-06-20 21:18:25.76 spid6s      Database 'msdb' running the upgrade step from version 868 to version 869.
DBSTARTUP (model, 3): FCBOpenTime took 208 ms
DBSTARTUP (model, 3): FCBHeaderReadTime took 1964 ms
DBSTARTUP (model, 3): FileMgrPreRecoveryTime took 2118 ms
DBSTARTUP (model, 3): MasterFilesScanTime took 118 ms
DBSTARTUP (model, 3): LogMgrPreRecoveryTime took 683 ms
DBSTARTUP (model, 3): PhysicalCompletionTime took 954 ms
DBSTARTUP (model, 3): RecoveryCompletionTime took 592 ms
DBSTARTUP (model, 3): UpgradeTime took 12154 ms
DBSTARTUP (model, 3): StartupInDatabaseTime took 12541 ms
DBSTARTUP (model, 3): RemapSysfiles1Time took 384 ms
2022-06-20 21:18:27.41 spid9s      Polybase feature disabled.
2022-06-20 21:18:27.42 spid9s      Clearing tempdb database.
2022-06-20 21:18:35.14 spid9s      Starting up database 'tempdb'.
2022-06-20 21:18:36.48 spid22s     The Service Broker endpoint is in disabled or stopped state.
2022-06-20 21:18:36.50 spid22s     The Database Mirroring endpoint is in disabled or stopped state.
2022-06-20 21:18:36.76 spid22s     Service Broker manager has started.
2022-06-20 21:18:38.40 spid51      Starting up database 'vault'.
2022-06-20 21:18:38.73 spid51      Parallel redo is started for database 'vault' with worker pool size [1].
DBSTARTUP (msdb, 4): FCBOpenTime took 143 ms
DBSTARTUP (msdb, 4): FCBHeaderReadTime took 202 ms
DBSTARTUP (msdb, 4): FileMgrPreRecoveryTime took 2091 ms
DBSTARTUP (msdb, 4): MasterFilesScanTime took 115 ms
DBSTARTUP (msdb, 4): AnalysisRecTime took 112 ms
DBSTARTUP (msdb, 4): PhysicalRecoveryTime took 113 ms
DBSTARTUP (msdb, 4): PhysicalCompletionTime took 1373 ms
DBSTARTUP (msdb, 4): RecoveryCompletionTime took 638 ms
DBSTARTUP (msdb, 4): UpgradeTime took 12223 ms
DBSTARTUP (msdb, 4): StartupInDatabaseTime took 23493 ms
DBSTARTUP (msdb, 4): RemapSysfiles1Time took 1116 ms
2022-06-20 21:18:39.52 spid51      Parallel redo is shutdown for database 'vault' with worker pool size [1].
2022-06-20 21:18:41.22 spid6s      Recovery is complete. This is an informational message only. No user action is required.
2022-06-20 21:18:41.23 spid51      Setting database option AUTO_CLOSE to OFF for database 'vault'.
2022-06-20 21:18:41.57 spid16s     The default language (LCID 0) has been set for engine and full-text services.
enoch85 commented 2 years ago

Try to imstall it again from the menu.sh, but first uninstall it according to the instructions.

If you want a new VM, please buy another one. 👍🏼

Mellowlynx commented 2 years ago

Got the first can't login error again:

Waiting for the DB to come online...
 _     _ _                         _
| |__ (_) |___      ____ _ _ __ __| | ___ _ __
| '_ \| | __\ \ /\ / / _` | '__/ _` |/ _ \ '_ \
| |_) | | |_ \ V  V / (_| | | | (_| |  __/ | | |
|_.__/|_|\__| \_/\_/ \__,_|_|  \__,_|\___|_| |_|

Open source password management solutions
Copyright 2015-2022, 8bit Solutions LLC
https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.1
Docker version 20.10.17, build 100c701
docker-compose version 1.25.0, build unknown

2022.5.1: Pulling from bitwarden/setup
Digest: sha256:ccd20b2a38908c64775adfa1626668519b6aa9e78f20f4836ec3c2a2480d8bde
Status: Image is up to date for bitwarden/setup:2022.5.1
docker.io/bitwarden/setup:2022.5.1

Migrating database.
Unhandled exception. System.Data.SqlClient.SqlException (0x80131904): Login failed for user 'sa'.
   at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, Boolean applyTransientFaultHandling, String accessToken)
   at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
   at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
   at System.Data.SqlClient.SqlConnection.Open()
   at Bit.Migrator.DbMigrator.MigrateMsSqlDatabase(Boolean enableLogging, CancellationToken cancellationToken) in /home/runner/work/server/server/util/Migrator/DbMigrator.cs:line 49
   at Bit.Setup.Program.MigrateDatabase(Int32 attempt) in /home/runner/work/server/server/util/Setup/Program.cs:line 199
   at Bit.Setup.Program.Update() in /home/runner/work/server/server/util/Setup/Program.cs:line 161
   at Bit.Setup.Program.Main(String[] args) in /home/runner/work/server/server/util/Setup/Program.cs:line 59
ClientConnectionId:492f74d2-c58e-42db-99b1-45634a34a6b0
Error Number:18456,State:1,Class:14
Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!
sudo -u bitwarden ./bitwarden.sh updatedb failed
Posting notification to users that are admins, this might take a while...
Mellowlynx commented 2 years ago

Not going to buy to just get a newer version, within a year of purchase.

enoch85 commented 2 years ago

within a year of purchase.

Much has happened in a year! We released Ubuntu 22.04, PHP 8.1 and PostgreSQL 14. It might be worth checking out. ;)

Mellowlynx commented 2 years ago

That is true, did not think about that. Just got it and running the first boot setup now. Did not think about it before, but will it be able to update to version 25?

Mellowlynx commented 2 years ago

Still getting a error with the new files :(

Waiting for the DB to come online...


| | () | _ _ | | __ | '_ | | \ \ /\ / / _| '__/ _ |/ \ ' \ | |) | | | \ V V / (| | | | (| | / | | | |_./||_| _/_/ _,|| _,|\|| ||

Open source password management solutions Copyright 2015-2022, 8bit Solutions LLC https://bitwarden.com, https://github.com/bitwarden

===================================================

bitwarden.sh version 2022.5.2 Docker version 20.10.17, build 100c701 docker-compose version 1.29.2, build unknown

2022.5.2: Pulling from bitwarden/setup Digest: sha256:fc63bf509c518d15fe136641b19b4e605d0e267aae1999a1d92b42ba7d37c2a5 Status: Image is up to date for bitwarden/setup:2022.5.2 docker.io/bitwarden/setup:2022.5.2

Migrating database.
Unhandled exception. System.Data.SqlClient.SqlException (0x80131904): A severe error occurred on the current command.  The results, if any, should be discarded.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
   at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite, String method)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite, String methodName)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at Bit.Migrator.DbMigrator.MigrateMsSqlDatabase(Boolean enableLogging, CancellationToken cancellationToken) in /home/runner/work/server/server/util/Migrator/DbMigrator.cs:line 50
   at Bit.Setup.Program.MigrateDatabase(Int32 attempt) in /home/runner/work/server/server/util/Setup/Program.cs:line 199
   at Bit.Setup.Program.Update() in /home/runner/work/server/server/util/Setup/Program.cs:line 161
   at Bit.Setup.Program.Main(String[] args) in /home/runner/work/server/server/util/Setup/Program.cs:line 59
ClientConnectionId:001ba600-1844-4c97-a6f1-7e72a0130ee6
Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!
sudo -u bitwarden ./bitwarden.sh updatedb failed
Posting notification to users that are admins, this might take a while...
Posting 'Sorry but something went wrong. Please report this issue to https://github.com/nextcloud/vm/issues and include the output of the error message. Thank you!' 
enoch85 commented 2 years ago

That is true, did not think about that. Just got it and running the first boot setup now. Did not think about it before, but will it be able to update to version 25?

Yes, you will be able to upgrade to 25. :)

Regarding Bitwarden, that's super odd. I don't have an answer as I can't reproduce it myself. :(

Mellowlynx commented 2 years ago

Reimported the full hyper-v and still a error, (The timeout period elapsed while attempting to consume the pre-login handshake acknowledgement.) Your probably are working on a version 25 file? Can I get a link when it's done to try that? (Order #18848)

enoch85 commented 2 years ago

If you mean Nextcloud 25 the VM will follow the versioning, so when 25 is out, the VM will be released shortly after.

You will also be able to upgrade to 25 once it's out, no need to get a new VM for that.

Mellowlynx commented 2 years ago

My bad, thought that I read in a notification that v 25 was out. But I tried running the dbupdate alone after it fails and than it works... Is there a way to download the bitwarden installation script so I can add a longer wait time?

Mellowlynx commented 2 years ago

YAY, I paused the script and continued it 20 seconds later and the installation finished!! Looks like de DB was not ready yet. Have to wait a view days to be able to get a new certificate for nextcloud, but all should be good.

enoch85 commented 2 years ago

Ok, thanks for the info! We will prolong the timeout in future versions.