Migration Issue

C:\Users\WalkingTree>setx/ MB_DB_TYPE=postgres

SUCCESS: Specified value was saved.

C:\Users\WalkingTree>SETX / MB_DB_DBNAME=metabase

SUCCESS: Specified value was saved.

C:\Users\WalkingTree>SETX / MB_DB_PORT=5432

SUCCESS: Specified value was saved.

C:\Users\WalkingTree>SETX / MB_DB_USER=Maharshi Trivedi
ERROR: Invalid syntax. Default option is not allowed more than '2' time(s).
Type "SETX /?" for usage.

C:\Users\WalkingTree>SETX / MB_DB_USER= MaharshiTrivedi
ERROR: Invalid syntax. Default option is not allowed more than '2' time(s).
Type "SETX /?" for usage.

C:\Users\WalkingTree>SETX / MB_DB_USER=MaharshiTrivedi

SUCCESS: Specified value was saved.

C:\Users\WalkingTree>SETX / MB_DB_PASS=MTrivedi#1

SUCCESS: Specified value was saved.

C:\Users\WalkingTree>SETX / MB_DB_HOST=localhost

SUCCESS: Specified value was saved.

C:\Users\WalkingTree>java -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase.db
Warning: environ value C:\Program Files\Java\jdk-11.0.2 for key :java-home has been overwritten with C:\Program Files\OpenJDK\jdk-11.0.2
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-03-30 17:40:51,390 INFO metabase.util :: Maximum memory available to JVM: 3.9 GB
2022-03-30 17:41:08,608 INFO util.encryption :: Saved credentials encryption is DISABLED for this Metabase instance.
For more information, see https://metabase.com/docs/latest/operations-guide/encrypting-database-details-at-rest.html
2022-03-30 17:41:14,152 INFO driver.impl :: Registered abstract driver :sql
? Load driver :sql took 1.3 s
2022-03-30 17:41:14,175 INFO driver.impl :: Registered abstract driver :sql-jdbc (parents: [:sql])
Load driver :sql-jdbc took 1.3 s
2022-03-30 17:41:14,185 INFO driver.impl :: Registered driver :h2 (parents: [:sql-jdbc])
2022-03-30 17:41:14,226 INFO driver.impl :: Registered driver :mysql (parents: [:sql-jdbc])
2022-03-30 17:41:14,255 INFO driver.impl :: Registered driver :postgres (parents: [:sql-jdbc])
2022-03-30 17:41:20,529 INFO metabase.core ::
Metabase v1.42.2 (d6ff494 release-x.42.x)

Copyright ⌐ 2022 Metabase, Inc.

Metabase Enterprise Edition extensions are PRESENT.

Usage of Metabase Enterprise Edition features are subject to the Metabase Commercial License.See https://www.metabase.com/license/commercial/ for details.
2022-03-30 17:41:20,682 WARN db.env :: WARNING: Using Metabase with an H2 application database is not recommended for production deployments. For production deployments, we highly recommend using Postgres, MySQL, or MariaDB instead. If you decide to continue to use H2, please be sure to back up the database file regularly. For more information, see https://metabase.com/docs/latest/operations-guide/migrating-from-h2.html
2022-03-30 17:41:20,687 INFO cmd.copy :: Set up h2 source database and run migrations...
2022-03-30 17:41:20,693 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-30 17:41:21,358 INFO db.setup :: Successfully verified H2 1.4.197 (2018-03-18) application database connection.
2022-03-30 17:41:21,360 INFO db.setup :: Running Database Migrations...
2022-03-30 17:41:21,367 INFO db.setup :: Setting up Liquibase...
2022-03-30 17:41:21,456 INFO db.setup :: Liquibase is ready.
2022-03-30 17:41:21,457 INFO db.liquibase :: Checking if Database has unrun migrations...
2022-03-30 17:41:24,525 INFO db.setup :: Database Migrations Current ...
2022-03-30 17:41:24,526 INFO db.data-migrations :: Running all necessary data migrations, this may take a minute.
2022-03-30 17:41:24,549 INFO db.data-migrations :: Finished running data migrations.
Database setup took 3.9 s
2022-03-30 17:41:24,552 INFO cmd.copy :: [OK]
2022-03-30 17:41:24,556 INFO cmd.copy :: Set up h2 target database and run migrations...
2022-03-30 17:41:24,557 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-30 17:41:24,561 INFO db.setup :: Successfully verified H2 1.4.197 (2018-03-18) application database connection.
2022-03-30 17:41:24,562 INFO db.setup :: Running Database Migrations...
2022-03-30 17:41:24,565 INFO db.setup :: Setting up Liquibase...
2022-03-30 17:41:24,583 INFO db.setup :: Liquibase is ready.
2022-03-30 17:41:24,584 INFO db.liquibase :: Checking if Database has unrun migrations...
2022-03-30 17:41:25,500 INFO db.setup :: Database Migrations Current ...
Database setup took 944.6 ms
2022-03-30 17:41:25,503 INFO cmd.copy :: [OK]
2022-03-30 17:41:25,506 INFO cmd.copy :: Testing if target h2 database is already populated...
2022-03-30 17:41:25,510 ERROR cmd.copy :: [FAIL]

clojure.lang.ExceptionInfo: ERROR Testing if target h2 database is already populated... {}
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:33)
at metabase.cmd.copy$do_step.invokeStatic(copy.clj:29)
at metabase.cmd.copy$do_step.invoke(copy.clj:27)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610.invoke(copy.clj:274)
at metabase.cmd.copy$fn__81604$copy_BANG___81609.invoke(copy.clj:258)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invokeStatic(load_from_h2.clj:35)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invoke(load_from_h2.clj:25)
at clojure.lang.Var.invoke(Var.java:384)
at metabase.cmd$load_from_h2.invokeStatic(cmd.clj:45)
at metabase.cmd$load_from_h2.invoke(cmd.clj:39)
at clojure.lang.AFn.applyToHelper(AFn.java:154)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:662)
at metabase.cmd$run_cmd$fn__83258.invoke(cmd.clj:190)
at metabase.cmd$run_cmd.invokeStatic(cmd.clj:190)
at metabase.cmd$run_cmd.invoke(cmd.clj:186)
at clojure.lang.Var.invoke(Var.java:388)
at metabase.core$run_cmd.invokeStatic(core.clj:141)
at metabase.core$run_cmd.invoke(core.clj:139)
at metabase.core$_main.invokeStatic(core.clj:163)
at metabase.core$_main.doInvoke(core.clj:158)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at metabase.core.main(Unknown Source)
Caused by: clojure.lang.ExceptionInfo: Target DB is already populated! {}
at metabase.cmd.copy$assert_db_empty.invokeStatic(copy.clj:160)
at metabase.cmd.copy$assert_db_empty.invoke(copy.clj:153)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610$fn__81615.invoke(copy.clj:275)
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:30)
... 23 more
Command failed with exception: ERROR Testing if target h2 database is already populated...

C:\Users\WalkingTree>java -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase
Warning: environ value C:\Program Files\Java\jdk-11.0.2 for key :java-home has been overwritten with C:\Program Files\OpenJDK\jdk-11.0.2
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-03-30 17:41:49,820 INFO metabase.util :: Maximum memory available to JVM: 3.9 GB
2022-03-30 17:42:01,152 INFO util.encryption :: Saved credentials encryption is DISABLED for this Metabase instance.
For more information, see https://metabase.com/docs/latest/operations-guide/encrypting-database-details-at-rest.html
2022-03-30 17:42:04,016 INFO driver.impl :: Registered abstract driver :sql
? Load driver :sql took 578.4 ms
2022-03-30 17:42:04,025 INFO driver.impl :: Registered abstract driver :sql-jdbc (parents: [:sql])
Load driver :sql-jdbc took 591.1 ms
2022-03-30 17:42:04,030 INFO driver.impl :: Registered driver :h2 (parents: [:sql-jdbc])
2022-03-30 17:42:04,051 INFO driver.impl :: Registered driver :mysql (parents: [:sql-jdbc])
2022-03-30 17:42:04,064 INFO driver.impl :: Registered driver :postgres (parents: [:sql-jdbc])
2022-03-30 17:42:07,033 INFO metabase.core ::
Metabase v1.42.2 (d6ff494 release-x.42.x)

Copyright ⌐ 2022 Metabase, Inc.

Metabase Enterprise Edition extensions are PRESENT.

Usage of Metabase Enterprise Edition features are subject to the Metabase Commercial License.See https://www.metabase.com/license/commercial/ for details.
2022-03-30 17:42:07,120 WARN db.env :: WARNING: Using Metabase with an H2 application database is not recommended for production deployments. For production deployments, we highly recommend using Postgres, MySQL, or MariaDB instead. If you decide to continue to use H2, please be sure to back up the database file regularly. For more information, see https://metabase.com/docs/latest/operations-guide/migrating-from-h2.html
2022-03-30 17:42:07,122 INFO cmd.copy :: Set up h2 source database and run migrations...
2022-03-30 17:42:07,127 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-30 17:42:07,195 ERROR cmd.copy :: [FAIL]

clojure.lang.ExceptionInfo: ERROR Set up h2 source database and run migrations... {}
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:33)
at metabase.cmd.copy$do_step.invokeStatic(copy.clj:29)
at metabase.cmd.copy$do_step.invoke(copy.clj:27)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610.invoke(copy.clj:265)
at metabase.cmd.copy$fn__81604$copy_BANG___81609.invoke(copy.clj:258)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invokeStatic(load_from_h2.clj:35)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invoke(load_from_h2.clj:25)
at clojure.lang.Var.invoke(Var.java:384)
at metabase.cmd$load_from_h2.invokeStatic(cmd.clj:45)
at metabase.cmd$load_from_h2.invoke(cmd.clj:39)
at clojure.lang.AFn.applyToHelper(AFn.java:154)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:662)
at metabase.cmd$run_cmd$fn__83258.invoke(cmd.clj:190)
at metabase.cmd$run_cmd.invokeStatic(cmd.clj:190)
at metabase.cmd$run_cmd.invoke(cmd.clj:186)
at clojure.lang.Var.invoke(Var.java:388)
at metabase.core$run_cmd.invokeStatic(core.clj:141)
at metabase.core$run_cmd.invoke(core.clj:139)
at metabase.core$main.invokeStatic(core.clj:163)
at metabase.core$main.doInvoke(core.clj:158)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at metabase.core.main(Unknown Source)
Caused by: clojure.lang.ExceptionInfo: Unable to connect to Metabase h2 DB. {}
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042$fn__34043.invoke(setup.clj:102)
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042.invoke(setup.clj:100)
at metabase.db.setup$fn__34036$verify_db_connection__34041.invoke(setup.clj:94)
at metabase.db.setup$setup_db_BANG
$fn__34071$fn__34072.invoke(setup.clj:142)
at metabase.util$do_with_us_locale.invokeStatic(util.clj:692)
at metabase.util$do_with_us_locale.invoke(util.clj:678)
at metabase.db.setup$setup_db_BANG
$fn__34071.invoke(setup.clj:141)
at metabase.db.setup$setup_db_BANG_.invokeStatic(setup.clj:140)
at metabase.db.setup$setup_db_BANG_.invoke(setup.clj:136)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610$fn__81611.invoke(copy.clj:266)
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:30)
... 23 more
Caused by: org.h2.jdbc.JdbcSQLException: Database "C:/Users/WalkingTree/metabase" not found [90013-197]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
at org.h2.message.DbException.get(DbException.java:179)
at org.h2.message.DbException.get(DbException.java:155)
at org.h2.engine.Engine.openSession(Engine.java:64)
at org.h2.engine.Engine.openSession(Engine.java:179)
at org.h2.engine.Engine.createSessionAndValidate(Engine.java:157)
at org.h2.engine.Engine.createSession(Engine.java:140)
at org.h2.engine.Engine.createSession(Engine.java:28)
at org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.java:351)
at org.h2.jdbc.JdbcConnection.(JdbcConnection.java:124)
at org.h2.jdbc.JdbcConnection.(JdbcConnection.java:103)
at org.h2.Driver.connect(Driver.java:69)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:189)
at clojure.java.jdbc$get_driver_connection.invokeStatic(jdbc.clj:271)
at clojure.java.jdbc$get_driver_connection.invoke(jdbc.clj:250)
at clojure.java.jdbc$get_connection.invokeStatic(jdbc.clj:411)
at clojure.java.jdbc$get_connection.invoke(jdbc.clj:274)
at clojure.java.jdbc$db_query_with_resultset_STAR_.invokeStatic(jdbc.clj:1111)
at clojure.java.jdbc$db_query_with_resultset_STAR_.invoke(jdbc.clj:1093)
at clojure.java.jdbc$query.invokeStatic(jdbc.clj:1182)
at clojure.java.jdbc$query.invoke(jdbc.clj:1144)
at clojure.java.jdbc$query.invokeStatic(jdbc.clj:1160)
at clojure.java.jdbc$query.invoke(jdbc.clj:1144)
at metabase.driver.sql_jdbc.connection$can_connect_with_spec_QMARK_.invokeStatic(connection.clj:245)
at metabase.driver.sql_jdbc.connection$can_connect_with_spec_QMARK_.invoke(connection.clj:242)
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042$fn__34043.invoke(setup.clj:100)
... 33 more
Command failed with exception: ERROR Set up h2 source database and run migrations...

C:\Users\WalkingTree>java -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase.db
Warning: environ value C:\Program Files\Java\jdk-11.0.2 for key :java-home has been overwritten with C:\Program Files\OpenJDK\jdk-11.0.2
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-03-30 17:42:35,025 INFO metabase.util :: Maximum memory available to JVM: 3.9 GB
2022-03-30 17:42:46,732 INFO util.encryption :: Saved credentials encryption is DISABLED for this Metabase instance.
For more information, see https://metabase.com/docs/latest/operations-guide/encrypting-database-details-at-rest.html
2022-03-30 17:42:49,577 INFO driver.impl :: Registered abstract driver :sql
? Load driver :sql took 555.4 ms
2022-03-30 17:42:49,587 INFO driver.impl :: Registered abstract driver :sql-jdbc (parents: [:sql])
Load driver :sql-jdbc took 568.3 ms
2022-03-30 17:42:49,592 INFO driver.impl :: Registered driver :h2 (parents: [:sql-jdbc])
2022-03-30 17:42:49,612 INFO driver.impl :: Registered driver :mysql (parents: [:sql-jdbc])
2022-03-30 17:42:49,630 INFO driver.impl :: Registered driver :postgres (parents: [:sql-jdbc])
2022-03-30 17:42:53,394 INFO metabase.core ::
Metabase v1.42.2 (d6ff494 release-x.42.x)

Copyright ⌐ 2022 Metabase, Inc.

Metabase Enterprise Edition extensions are PRESENT.

Usage of Metabase Enterprise Edition features are subject to the Metabase Commercial License.See https://www.metabase.com/license/commercial/ for details.
2022-03-30 17:42:53,559 WARN db.env :: WARNING: Using Metabase with an H2 application database is not recommended for production deployments. For production deployments, we highly recommend using Postgres, MySQL, or MariaDB instead. If you decide to continue to use H2, please be sure to back up the database file regularly. For more information, see https://metabase.com/docs/latest/operations-guide/migrating-from-h2.html
2022-03-30 17:42:53,568 INFO cmd.copy :: Set up h2 source database and run migrations...
2022-03-30 17:42:53,573 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-30 17:42:54,279 INFO db.setup :: Successfully verified H2 1.4.197 (2018-03-18) application database connection.
2022-03-30 17:42:54,280 INFO db.setup :: Running Database Migrations...
2022-03-30 17:42:54,285 INFO db.setup :: Setting up Liquibase...
2022-03-30 17:42:54,369 INFO db.setup :: Liquibase is ready.
2022-03-30 17:42:54,370 INFO db.liquibase :: Checking if Database has unrun migrations...
2022-03-30 17:42:57,651 INFO db.setup :: Database Migrations Current ...
2022-03-30 17:42:57,652 INFO db.data-migrations :: Running all necessary data migrations, this may take a minute.
2022-03-30 17:42:57,677 INFO db.data-migrations :: Finished running data migrations.
Database setup took 4.1 s
2022-03-30 17:42:57,683 INFO cmd.copy :: [OK]
2022-03-30 17:42:57,685 INFO cmd.copy :: Set up h2 target database and run migrations...
2022-03-30 17:42:57,686 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-30 17:42:57,689 INFO db.setup :: Successfully verified H2 1.4.197 (2018-03-18) application database connection.
2022-03-30 17:42:57,692 INFO db.setup :: Running Database Migrations...
2022-03-30 17:42:57,696 INFO db.setup :: Setting up Liquibase...
2022-03-30 17:42:57,719 INFO db.setup :: Liquibase is ready.
2022-03-30 17:42:57,720 INFO db.liquibase :: Checking if Database has unrun migrations...
2022-03-30 17:42:58,676 INFO db.setup :: Database Migrations Current ...
Database setup took 990.9 ms
2022-03-30 17:42:58,680 INFO cmd.copy :: [OK]
2022-03-30 17:42:58,682 INFO cmd.copy :: Testing if target h2 database is already populated...
2022-03-30 17:42:58,686 ERROR cmd.copy :: [FAIL]

clojure.lang.ExceptionInfo: ERROR Testing if target h2 database is already populated... {}
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:33)
at metabase.cmd.copy$do_step.invokeStatic(copy.clj:29)
at metabase.cmd.copy$do_step.invoke(copy.clj:27)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610.invoke(copy.clj:274)
at metabase.cmd.copy$fn__81604$copy_BANG___81609.invoke(copy.clj:258)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invokeStatic(load_from_h2.clj:35)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invoke(load_from_h2.clj:25)
at clojure.lang.Var.invoke(Var.java:384)
at metabase.cmd$load_from_h2.invokeStatic(cmd.clj:45)
at metabase.cmd$load_from_h2.invoke(cmd.clj:39)
at clojure.lang.AFn.applyToHelper(AFn.java:154)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:662)
at metabase.cmd$run_cmd$fn__83258.invoke(cmd.clj:190)
at metabase.cmd$run_cmd.invokeStatic(cmd.clj:190)
at metabase.cmd$run_cmd.invoke(cmd.clj:186)
at clojure.lang.Var.invoke(Var.java:388)
at metabase.core$run_cmd.invokeStatic(core.clj:141)
at metabase.core$run_cmd.invoke(core.clj:139)
at metabase.core$_main.invokeStatic(core.clj:163)
at metabase.core$_main.doInvoke(core.clj:158)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at metabase.core.main(Unknown Source)
Caused by: clojure.lang.ExceptionInfo: Target DB is already populated! {}
at metabase.cmd.copy$assert_db_empty.invokeStatic(copy.clj:160)
at metabase.cmd.copy$assert_db_empty.invoke(copy.clj:153)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610$fn__81615.invoke(copy.clj:275)
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:30)
... 23 more
Command failed with exception: ERROR Testing if target h2 database is already populated...

I am trying to migrate my database from h2 to postgres.This is the error showing.Please help and check if command line functions are proper

Hi @Maharshi
Use the Java properties instead: https://www.metabase.com/docs/latest/operations-guide/environment-variables.html

java -DMB_DB_TYPE=postgres -DMB_DB_CONNECTION_URI="postgresql://localhost:5432/metabase?user=MaharshiTrivedi&password=MTrivedi#1" -jar metabase.jar load-from-h2 metabase.db

If you are an Enterprise/Pro customer, then please use the support email. Otherwise you should download the open source edition instead.

'pass' is not recognized as an internal or external command,
operable program or batch file.

@Maharshi Use password instead, and quotes around the string.

C:\Users\WalkingTree>java -DMB_DB_TYPE=postgres -DMB_DB_CONNECTION_URI=postgresql://localhost:5432/metabase?user=MaharshiTrivedi&password=MTrivedi#1 -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase.db
Usage: java [options] [args...]
(to execute a class)
or java [options] -jar [args...]
(to execute a jar file)
or java [options] -m [/] [args...]
java [options] --module [/] [args...]
(to execute the main class in a module)
or java [options] [args]
(to execute a single source-file program)

Arguments following the main class, source file, -jar ,
-m or --module / are passed as the arguments to
main class.

where options include:

-cp <class search path of directories and zip/jar files>
-classpath <class search path of directories and zip/jar files>
--class-path <class search path of directories and zip/jar files>
              A ; separated list of directories, JAR archives,
              and ZIP archives to search for class files.
-p <module path>
--module-path <module path>...
              A ; separated list of directories, each directory
              is a directory of modules.
--upgrade-module-path <module path>...
              A ; separated list of directories, each directory
              is a directory of modules that replace upgradeable
              modules in the runtime image
--add-modules <module name>[,<module name>...]
              root modules to resolve in addition to the initial module.
              <module name> can also be ALL-DEFAULT, ALL-SYSTEM,
              ALL-MODULE-PATH.
--list-modules
              list observable modules and exit
-d <module name>
--describe-module <module name>
              describe a module and exit
--dry-run     create VM and load main class but do not execute main method.
              The --dry-run option may be useful for validating the
              command-line options such as the module system configuration.
--validate-modules
              validate all modules and exit
              The --validate-modules option may be useful for finding
              conflicts and other errors with modules on the module path.
-D<name>=<value>
              set a system property
-verbose:[class|module|gc|jni]
              enable verbose output
-version      print product version to the error stream and exit
--version     print product version to the output stream and exit
-showversion  print product version to the error stream and continue
--show-version
              print product version to the output stream and continue
--show-module-resolution
              show module resolution output during startup
-? -h -help
              print this help message to the error stream
--help        print this help message to the output stream
-X            print help on extra options to the error stream
--help-extra  print help on extra options to the output stream
-ea[:<packagename>...|:<classname>]
-enableassertions[:<packagename>...|:<classname>]
              enable assertions with specified granularity
-da[:<packagename>...|:<classname>]
-disableassertions[:<packagename>...|:<classname>]
              disable assertions with specified granularity
-esa | -enablesystemassertions
              enable system assertions
-dsa | -disablesystemassertions
              disable system assertions
-agentlib:<libname>[=<options>]
              load native agent library <libname>, e.g. -agentlib:jdwp
              see also -agentlib:jdwp=help
-agentpath:<pathname>[=<options>]
              load native agent library by full pathname
-javaagent:<jarpath>[=<options>]
              load Java programming language agent, see java.lang.instrument
-splash:<imagepath>
              show splash screen with specified image
              HiDPI scaled images are automatically supported and used
              if available. The unscaled image filename, e.g. image.ext,
              should always be passed as the argument to the -splash option.
              The most appropriate scaled image provided will be picked up
              automatically.
              See the SplashScreen API documentation for more information
@argument files
              one or more argument files containing options
-disable-@files
              prevent further argument file expansion
--enable-preview
              allow classes to depend on preview features of this release

To specify an argument for a long option, you can use --= or
-- .

'password' is not recognized as an internal or external command,
operable program or batch file.

C:\Users\WalkingTree>

C:\Users\WalkingTree>java -DMB_DB_TYPE=postgres -DMB_DB_CONNECTION_URI=postgresql://localhost:5432/metabase?user=MaharshiTrivedi -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase.db
Warning: environ value C:\Program Files\Java\jdk-11.0.2 for key :java-home has been overwritten with C:\Program Files\OpenJDK\jdk-11.0.2
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-03-30 18:19:34,263 INFO metabase.util :: Maximum memory available to JVM: 3.9 GB
2022-03-30 18:19:45,557 INFO util.encryption :: Saved credentials encryption is DISABLED for this Metabase instance.
For more information, see https://metabase.com/docs/latest/operations-guide/encrypting-database-details-at-rest.html
2022-03-30 18:19:48,429 INFO driver.impl :: Registered abstract driver :sql
? Load driver :sql took 558.9 ms
2022-03-30 18:19:48,438 INFO driver.impl :: Registered abstract driver :sql-jdbc (parents: [:sql])
Load driver :sql-jdbc took 571.6 ms
2022-03-30 18:19:48,441 INFO driver.impl :: Registered driver :h2 (parents: [:sql-jdbc])
2022-03-30 18:19:48,463 INFO driver.impl :: Registered driver :mysql (parents: [:sql-jdbc])
2022-03-30 18:19:48,480 INFO driver.impl :: Registered driver :postgres (parents: [:sql-jdbc])
2022-03-30 18:19:51,697 INFO metabase.core ::
Metabase v1.42.2 (d6ff494 release-x.42.x)

Copyright ⌐ 2022 Metabase, Inc.

Metabase Enterprise Edition extensions are PRESENT.

Usage of Metabase Enterprise Edition features are subject to the Metabase Commercial License.See https://www.metabase.com/license/commercial/ for details.
2022-03-30 18:19:51,780 INFO cmd.copy :: Set up h2 source database and run migrations...
2022-03-30 18:19:51,783 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-30 18:19:52,143 INFO db.setup :: Successfully verified H2 1.4.197 (2018-03-18) application database connection.
2022-03-30 18:19:52,144 INFO db.setup :: Running Database Migrations...
2022-03-30 18:19:52,148 INFO db.setup :: Setting up Liquibase...
2022-03-30 18:19:52,200 INFO db.setup :: Liquibase is ready.
2022-03-30 18:19:52,201 INFO db.liquibase :: Checking if Database has unrun migrations...
2022-03-30 18:19:54,208 INFO db.setup :: Database Migrations Current ...
2022-03-30 18:19:54,209 INFO db.data-migrations :: Running all necessary data migrations, this may take a minute.
2022-03-30 18:19:54,224 INFO db.data-migrations :: Finished running data migrations.
Database setup took 2.4 s
2022-03-30 18:19:54,226 INFO cmd.copy :: [OK]
2022-03-30 18:19:54,228 INFO cmd.copy :: Set up postgres target database and run migrations...
2022-03-30 18:19:54,229 INFO db.setup :: Verifying postgres Database Connection ...
2022-03-30 18:19:56,300 ERROR cmd.copy :: [FAIL]

clojure.lang.ExceptionInfo: ERROR Set up postgres target database and run migrations... {}
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:33)
at metabase.cmd.copy$do_step.invokeStatic(copy.clj:29)
at metabase.cmd.copy$do_step.invoke(copy.clj:27)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610.invoke(copy.clj:270)
at metabase.cmd.copy$fn__81604$copy_BANG___81609.invoke(copy.clj:258)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invokeStatic(load_from_h2.clj:35)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invoke(load_from_h2.clj:25)
at clojure.lang.Var.invoke(Var.java:384)
at metabase.cmd$load_from_h2.invokeStatic(cmd.clj:45)
at metabase.cmd$load_from_h2.invoke(cmd.clj:39)
at clojure.lang.AFn.applyToHelper(AFn.java:154)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:662)
at metabase.cmd$run_cmd$fn__83258.invoke(cmd.clj:190)
at metabase.cmd$run_cmd.invokeStatic(cmd.clj:190)
at metabase.cmd$run_cmd.invoke(cmd.clj:186)
at clojure.lang.Var.invoke(Var.java:388)
at metabase.core$run_cmd.invokeStatic(core.clj:141)
at metabase.core$run_cmd.invoke(core.clj:139)
at metabase.core$main.invokeStatic(core.clj:163)
at metabase.core$main.doInvoke(core.clj:158)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at metabase.core.main(Unknown Source)
Caused by: clojure.lang.ExceptionInfo: Unable to connect to Metabase postgres DB. {}
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042$fn__34043.invoke(setup.clj:102)
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042.invoke(setup.clj:100)
at metabase.db.setup$fn__34036$verify_db_connection__34041.invoke(setup.clj:94)
at metabase.db.setup$setup_db_BANG
$fn__34071$fn__34072.invoke(setup.clj:142)
at metabase.util$do_with_us_locale.invokeStatic(util.clj:692)
at metabase.util$do_with_us_locale.invoke(util.clj:678)
at metabase.db.setup$setup_db_BANG
$fn__34071.invoke(setup.clj:141)
at metabase.db.setup$setup_db_BANG_.invokeStatic(setup.clj:140)
at metabase.db.setup$setup_db_BANG_.invoke(setup.clj:136)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610$fn__81613.invoke(copy.clj:272)
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:30)
... 23 more
Caused by: org.postgresql.util.PSQLException: Connection to localhost:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:303)
at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:51)
at org.postgresql.jdbc.PgConnection.(PgConnection.java:223)
at org.postgresql.Driver.makeConnection(Driver.java:465)
at org.postgresql.Driver.connect(Driver.java:264)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:189)
at clojure.java.jdbc$get_driver_connection.invokeStatic(jdbc.clj:271)
at clojure.java.jdbc$get_driver_connection.invoke(jdbc.clj:250)
at clojure.java.jdbc$get_connection.invokeStatic(jdbc.clj:411)
at clojure.java.jdbc$get_connection.invoke(jdbc.clj:274)
at clojure.java.jdbc$db_query_with_resultset_STAR_.invokeStatic(jdbc.clj:1111)
at clojure.java.jdbc$db_query_with_resultset_STAR_.invoke(jdbc.clj:1093)
at clojure.java.jdbc$query.invokeStatic(jdbc.clj:1182)
at clojure.java.jdbc$query.invoke(jdbc.clj:1144)
at clojure.java.jdbc$query.invokeStatic(jdbc.clj:1160)
at clojure.java.jdbc$query.invoke(jdbc.clj:1144)
at metabase.driver.sql_jdbc.connection$can_connect_with_spec_QMARK_.invokeStatic(connection.clj:245)
at metabase.driver.sql_jdbc.connection$can_connect_with_spec_QMARK_.invoke(connection.clj:242)
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042$fn__34043.invoke(setup.clj:100)
... 33 more
Caused by: java.net.ConnectException: Connection refused: connect
at java.base/java.net.PlainSocketImpl.waitForConnect(Native Method)
at java.base/java.net.PlainSocketImpl.socketConnect(PlainSocketImpl.java:107)
at java.base/java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:399)
at java.base/java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:242)
at java.base/java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:224)
at java.base/java.net.SocksSocketImpl.connect(SocksSocketImpl.java:403)
at java.base/java.net.Socket.connect(Socket.java:591)
at org.postgresql.core.PGStream.createSocket(PGStream.java:231)
at org.postgresql.core.PGStream.(PGStream.java:95)
at org.postgresql.core.v3.ConnectionFactoryImpl.tryConnect(ConnectionFactoryImpl.java:98)
at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:213)
... 52 more
Command failed with exception: ERROR Set up postgres target database and run migrations...

When I tried to run without password

@Maharshi Are you an Enterprise or Pro customer?

Yes I have enterprise edition but only for 2 days

@Maharshi Okay, then use support@metabase.com

It errors with Connection to localhost:5432 refused, so make sure that Postgres is available on the host and port you have chosen.

I am running postgres in docker file and the command in command prompt is :
docker run --rm -d --name postgres -p 5434:5433 -e POSTGRES_USER=Maharshi -e POSTGRES_PASSWORD=MTrivedi#1 --network metanet postgres:12

Still I am getting the same error as mentioned above.Please help

@Maharshi You are running Postgres with --rm, which means the container will be deleted, when it is stopped or restarted. You will lose all your data, since you are not placing it outside of the container.
And you are telling it to be on a separate network --network metanet

C:\Users\WalkingTree>docker run --name postgres -p 5434:5433 -e POSTGRES_USER=Maharshi -e POSTGRES_PASSWORD=MTrivedi#1 postgres:12
The files belonging to this database system will be owned by user "postgres".
This user must also own the server process.

The database cluster will be initialized with locale "en_US.utf8".
The default database encoding has accordingly been set to "UTF8".
The default text search configuration will be set to "english".

Data page checksums are disabled.

fixing permissions on existing directory /var/lib/postgresql/data ... ok
creating subdirectories ... ok
selecting dynamic shared memory implementation ... posix
selecting default max_connections ... 100
selecting default shared_buffers ... 128MB
selecting default time zone ... Etc/UTC
creating configuration files ... ok
running bootstrap script ... ok
performing post-bootstrap initialization ... ok
syncing data to disk ... ok

Success. You can now start the database server using:

pg_ctl -D /var/lib/postgresql/data -l logfile start

initdb: warning: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the option -A, or
--auth-local and --auth-host, the next time you run initdb.
waiting for server to start....2022-03-31 08:23:48.555 UTC [49] LOG: starting PostgreSQL 12.10 (Debian 12.10-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
2022-03-31 08:23:48.556 UTC [49] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2022-03-31 08:23:48.568 UTC [50] LOG: database system was shut down at 2022-03-31 08:23:48 UTC
2022-03-31 08:23:48.571 UTC [49] LOG: database system is ready to accept connections
done
server started
CREATE DATABASE

/usr/local/bin/docker-entrypoint.sh: ignoring /docker-entrypoint-initdb.d/*

2022-03-31 08:23:48.800 UTC [49] LOG: received fast shutdown request
waiting for server to shut down....2022-03-31 08:23:48.802 UTC [49] LOG: aborting any active transactions
2022-03-31 08:23:48.803 UTC [49] LOG: background worker "logical replication launcher" (PID 56) exited with exit code 12022-03-31 08:23:48.803 UTC [51] LOG: shutting down
2022-03-31 08:23:48.815 UTC [49] LOG: database system is shut down
done
server stopped

PostgreSQL init process complete; ready for start up.

2022-03-31 08:23:48.918 UTC [1] LOG: starting PostgreSQL 12.10 (Debian 12.10-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
2022-03-31 08:23:48.918 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432
2022-03-31 08:23:48.918 UTC [1] LOG: listening on IPv6 address "::", port 5432
2022-03-31 08:23:48.923 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2022-03-31 08:23:48.939 UTC [77] LOG: database system was shut down at 2022-03-31 08:23:48 UTC
2022-03-31 08:23:48.942 UTC [1] LOG: database system is ready to accept connections

Still when I am giving command java -DMB_DB_TYPE=postgres -DMB_DB_CONNECTION_URI="jdbc:postgresql://localhost:5434/metabase?user=Maharshi&password=MTrivedi#1" -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase.db It is throwing errors as: Command failed with exception: ERROR Set up postgres target database and run migrations...

@Maharshi I need the log for the Metabase migration, not the Postgres startup log.
The default Postgres port is 5432, but you are mapping host 5434 to container 5433.
Try this:

docker run -d --name postgres -p 5432:5432 -e POSTGRES_USER=Maharshi -e POSTGRES_PASSWORD=MTrivedi#1 postgres:12
java -DMB_DB_TYPE=postgres -DMB_DB_CONNECTION_URI="jdbc:postgresql://localhost:5432/metabase?user=Maharshi&password=MTrivedi#1" -jar metabase.jar load-from-h2 metabase.db

C:\Users\WalkingTree>docker run -d --name postgres -p 5432:5432 -e POSTGRES_USER=Maharshi -e POSTGRES_PASSWORD=MTrivedi#1 postgres:12
7bc967e202851a9ea0faef6323e2f9521b4cbbf715b3e99a39af1fbc287a38ce

C:\Users\WalkingTree>java -DMB_DB_TYPE=postgres -DMB_DB_CONNECTION_URI="jdbc:postgresql://localhost:5432/metabase?user=Maharshi&password=MTrivedi#1" -jar C:\Users\WalkingTree\metabase.jar load-from-h2 C:\Users\WalkingTree\metabase.db
Warning: environ value C:\Program Files\Java\jdk-11.0.2 for key :java-home has been overwritten with C:\Program Files\OpenJDK\jdk-11.0.2
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-03-31 14:15:07,030 INFO metabase.util :: Maximum memory available to JVM: 3.9 GB
2022-03-31 14:15:18,041 INFO util.encryption :: Saved credentials encryption is DISABLED for this Metabase instance.
For more information, see https://metabase.com/docs/latest/operations-guide/encrypting-database-details-at-rest.html
2022-03-31 14:15:20,997 INFO driver.impl :: Registered abstract driver :sql
? Load driver :sql took 588.7 ms
2022-03-31 14:15:20,997 INFO driver.impl :: Registered abstract driver :sql-jdbc (parents: [:sql])
Load driver :sql-jdbc took 599.9 ms
2022-03-31 14:15:21,013 INFO driver.impl :: Registered driver :h2 (parents: [:sql-jdbc])
2022-03-31 14:15:21,013 INFO driver.impl :: Registered driver :mysql (parents: [:sql-jdbc])
2022-03-31 14:15:21,029 INFO driver.impl :: Registered driver :postgres (parents: [:sql-jdbc])
2022-03-31 14:15:23,801 INFO metabase.core ::
Metabase v1.42.2 (d6ff494 release-x.42.x)

Copyright ⌐ 2022 Metabase, Inc.

Metabase Enterprise Edition extensions are PRESENT.

Usage of Metabase Enterprise Edition features are subject to the Metabase Commercial License.See https://www.metabase.com/license/commercial/ for details.
2022-03-31 14:15:23,833 INFO cmd.copy :: Set up h2 source database and run migrations...
2022-03-31 14:15:23,849 INFO db.setup :: Verifying h2 Database Connection ...
2022-03-31 14:15:24,197 INFO db.setup :: Successfully verified H2 1.4.197 (2018-03-18) application database connection.
2022-03-31 14:15:24,197 INFO db.setup :: Running Database Migrations...
2022-03-31 14:15:24,201 INFO db.setup :: Setting up Liquibase...
2022-03-31 14:15:24,246 INFO db.setup :: Liquibase is ready.
2022-03-31 14:15:24,246 INFO db.liquibase :: Checking if Database has unrun migrations...
2022-03-31 14:15:26,317 INFO db.setup :: Database Migrations Current ...
2022-03-31 14:15:26,317 INFO db.data-migrations :: Running all necessary data migrations, this may take a minute.
2022-03-31 14:15:26,331 INFO db.data-migrations :: Finished running data migrations.
Database setup took 2.5 s
2022-03-31 14:15:26,331 INFO cmd.copy :: [OK]
2022-03-31 14:15:26,331 INFO cmd.copy :: Set up postgres target database and run migrations...
2022-03-31 14:15:26,331 INFO db.setup :: Verifying postgres Database Connection ...
2022-03-31 14:15:26,390 ERROR cmd.copy :: [FAIL]

clojure.lang.ExceptionInfo: ERROR Set up postgres target database and run migrations... {}
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:33)
at metabase.cmd.copy$do_step.invokeStatic(copy.clj:29)
at metabase.cmd.copy$do_step.invoke(copy.clj:27)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610.invoke(copy.clj:270)
at metabase.cmd.copy$fn__81604$copy_BANG___81609.invoke(copy.clj:258)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invokeStatic(load_from_h2.clj:35)
at metabase.cmd.load_from_h2$load_from_h2_BANG_.invoke(load_from_h2.clj:25)
at clojure.lang.Var.invoke(Var.java:384)
at metabase.cmd$load_from_h2.invokeStatic(cmd.clj:45)
at metabase.cmd$load_from_h2.invoke(cmd.clj:39)
at clojure.lang.AFn.applyToHelper(AFn.java:154)
at clojure.lang.AFn.applyTo(AFn.java:144)
at clojure.core$apply.invokeStatic(core.clj:667)
at clojure.core$apply.invoke(core.clj:662)
at metabase.cmd$run_cmd$fn__83258.invoke(cmd.clj:190)
at metabase.cmd$run_cmd.invokeStatic(cmd.clj:190)
at metabase.cmd$run_cmd.invoke(cmd.clj:186)
at clojure.lang.Var.invoke(Var.java:388)
at metabase.core$run_cmd.invokeStatic(core.clj:141)
at metabase.core$run_cmd.invoke(core.clj:139)
at metabase.core$main.invokeStatic(core.clj:163)
at metabase.core$main.doInvoke(core.clj:158)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at metabase.core.main(Unknown Source)
Caused by: clojure.lang.ExceptionInfo: Unable to connect to Metabase postgres DB. {}
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042$fn__34043.invoke(setup.clj:102)
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042.invoke(setup.clj:100)
at metabase.db.setup$fn__34036$verify_db_connection__34041.invoke(setup.clj:94)
at metabase.db.setup$setup_db_BANG
$fn__34071$fn__34072.invoke(setup.clj:142)
at metabase.util$do_with_us_locale.invokeStatic(util.clj:692)
at metabase.util$do_with_us_locale.invoke(util.clj:678)
at metabase.db.setup$setup_db_BANG
$fn__34071.invoke(setup.clj:141)
at metabase.db.setup$setup_db_BANG_.invokeStatic(setup.clj:140)
at metabase.db.setup$setup_db_BANG_.invoke(setup.clj:136)
at metabase.cmd.copy$fn__81604$copy_BANG___81609$fn__81610$fn__81613.invoke(copy.clj:272)
at metabase.cmd.copy$do_step$fn__81443.invoke(copy.clj:30)
... 23 more
Caused by: org.postgresql.util.PSQLException: FATAL: database "metabase" does not exist
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2552)
at org.postgresql.core.v3.QueryExecutorImpl.readStartupMessages(QueryExecutorImpl.java:2664)
at org.postgresql.core.v3.QueryExecutorImpl.(QueryExecutorImpl.java:147)
at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:273)
at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:51)
at org.postgresql.jdbc.PgConnection.(PgConnection.java:223)
at org.postgresql.Driver.makeConnection(Driver.java:465)
at org.postgresql.Driver.connect(Driver.java:264)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677)
at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:189)
at clojure.java.jdbc$get_driver_connection.invokeStatic(jdbc.clj:271)
at clojure.java.jdbc$get_driver_connection.invoke(jdbc.clj:250)
at clojure.java.jdbc$get_connection.invokeStatic(jdbc.clj:411)
at clojure.java.jdbc$get_connection.invoke(jdbc.clj:274)
at clojure.java.jdbc$db_query_with_resultset_STAR_.invokeStatic(jdbc.clj:1111)
at clojure.java.jdbc$db_query_with_resultset_STAR_.invoke(jdbc.clj:1093)
at clojure.java.jdbc$query.invokeStatic(jdbc.clj:1182)
at clojure.java.jdbc$query.invoke(jdbc.clj:1144)
at clojure.java.jdbc$query.invokeStatic(jdbc.clj:1160)
at clojure.java.jdbc$query.invoke(jdbc.clj:1144)
at metabase.driver.sql_jdbc.connection$can_connect_with_spec_QMARK_.invokeStatic(connection.clj:245)
at metabase.driver.sql_jdbc.connection$can_connect_with_spec_QMARK_.invoke(connection.clj:242)
at metabase.db.setup$fn__34036$verify_db_connection__34041$fn__34042$fn__34043.invoke(setup.clj:100)
... 33 more
Command failed with exception: ERROR Set up postgres target database and run migrations...

@Maharshi You need to create the database: FATAL: database "metabase" does not exist

docker run -d --name postgres -p 5432:5432 -e POSTGRES_USER=Maharshi -e POSTGRES_PASSWORD=MTrivedi#1 -e POSTGRES_DB=metabase postgres:12

Thank You Very Much :innocent:

Helped a lot!!!!!!!!!!!!!!!!!!