About this task
The BVQ Server "and" the database should be moved,
wether whether or not it is because of a new Windows VM.
These are very profound changes which need to be made by the SVA/BVQ SEs.
A working VM backup is necessary.
Applies to
All Versions and Systems, further info
Procedure
Connect to the
...
Mongo shell
...
title | expand... |
---|
...
in order to connect, mongosh has to be installed as well, please see Install mongosh — MongoDB Shell
Code Block >mongosh -u bvq -p P@ssw0rd
Show DB´s
Code Block |
---|
> show |
...
dbs |
Expand | ||
---|---|---|
| ||
3. Exit the shell
Code Block |
---|
> show dbsexit |
4. Stop all the BVQ Services but "bvq-mongodb" and start the backup, the time to complete this task is depending on the DB size
Expand | title | expand...
---|
Code Block |
C:\Users\ dkarch.SVA>mongodump --host bvqsrv1.labwi.sva.de:27017bvq>mongodump --db bvq -- authenticationDatabase admin -u bvq -p P@ssw0rd - -gzipd bvq -j 8 --gzip --out ="C:\Temp\test-backup |
...
" |
Expand | ||
---|---|---|
| ||
5. Start & finish the installation of the same Version of BVQ on the new VM
and stop right after the MongoDB has installed6. Stop all BVQ services but "bvq-mongodb" on the new VM
Expand | ||
---|---|---|
|
make sure that the Mongo Service is running
...
title | expand... |
---|
restore the DB
Expand | ||
---|---|---|
| ||
| ||
8. During the BVQ-Installation, using default values, a "db" named "bvq" is created.
A restore of a mongodb has to be made, using a not existing db.
If you would like to use the db "bvq" again (code: mongorestore --authenticationDatabase admin -u bvq -p P@ssw0rd --db bvq --gzip -j 8 C:\bvq),
you have to drop the existing(just installed) bvq db.
Code Block |
---|
Connect to the mongo shell on the new VMC:\Users>mongo --authenticationDatabase admin -u bvq -p P@ssw0rd
show the db´s
> show dbs
admin 0.000GB
bvq 43.815GB
config 0.000GB
local 0.000GB
---------------------------------------------------------------------------
switch to the db, you would like to delete
> use bvq
switched to db bvq
---------------------------------------------------------------------------
delete db
> db.dropDatabase()
{ "ok" : 1 }
---------------------------------------------------------------------------
show the db´s
> show dbs
admin 0.000GB
config 0.000GB
local 0.000GB |
9. Restore the DB
Code Block |
---|
C:\bvq>mongorestore --authenticationDatabase admin -u bvq -p P@ssw0rd --gzip db bvq -j 8 --gzip "C:\Temp\test-backup\bvq" |
Expand |
---|
complete the installation wizard and connect to your BVQ
Escalation
...
| ||