Here are some snips from my Docker logs that show the connection failures I'm geting.
sdavm05[419]$ sudo docker logs -f metabase
Warning: environ value jdk-11.0.8+10 for key :java-version has been overwritten with 11.0.8
09-02 17:33:04 INFO metabase.util :: Loading Metabase...
09-02 17:33:04 INFO metabase.util :: Maximum memory available to JVM: 15.7 GB
WARNING: not-empty already refers to: #'clojure.core/not-empty in namespace: metabase.mbql.schema, being replaced by: #'metabase.mbql.schema/not-empty
09-02 17:33:17 INFO util.encryption :: Saved credentials encryption is DISABLED for this Metabase instance.
For more information, see Redirecting…
09-02 17:33:23 WARN metabase.core :: WARNING: You have enabled namespace tracing, which could log sensitive information like db passwords.
09-02 17:33:23 INFO metabase.core :: Starting Metabase in STANDALONE mode
09-02 17:33:23 INFO metabase.server :: Launching Embedded Jetty Webserver with config:
{:port 3000, :host "0.0.0.0"}
09-02 17:33:24 INFO metabase.core :: Starting Metabase version v0.36.4 (196c1f6 release-0.36.x) ...
09-02 17:33:24 INFO metabase.core :: System info:
{"file.encoding" "UTF-8",
"java.runtime.name" "OpenJDK Runtime Environment",
"java.runtime.version" "11.0.8+10",
"java.vendor" "AdoptOpenJDK",
"java.vendor.url" "https://adoptopenjdk.net/",
"java.version" "11.0.8",
"java.vm.name" "OpenJDK 64-Bit Server VM",
"java.vm.version" "11.0.8+10",
"os.name" "Linux",
"os.version" "4.18.0-147.el8.x86_64",
"user.language" "en",
"user.timezone" "GMT"}
09-02 17:33:24 INFO metabase.plugins :: Loading plugins in /plugins...
09-02 17:33:37 INFO metabase.core :: Metabase Initialization COMPLETE
09-02 17:35:59 INFO middleware.misc :: Setting Metabase site URL to sdavm05.unx.sas.com:3000
09-02 17:35:59 INFO i18n.impl :: Reading available locales from locales.clj...
09-02 17:35:59 INFO middleware.exceptions :: Request canceled before finishing.
09-02 17:36:00 DEBUG middleware.log :: GET /api/user/current 401 3.8 ms (0 DB calls)
"Unauthenticated"
09-02 17:36:00 DEBUG middleware.log :: GET /api/session/properties 200 3.1 ms (0 DB calls) App DB connections: 0/10 Jetty threads: 7/50 (0 idle, 0 queued) (47 total active threads) Queries in flight: 0 (0 queued)
09-02 17:36:01 DEBUG middleware.log :: GET /api/session/properties 200 2.9 ms (0 DB calls) App DB connections: 0/10 Jetty threads: 6/50 (1 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:36:42 DEBUG middleware.log :: POST /api/util/password_check 200 1.8 ms (0 DB calls) App DB connections: 0/10 Jetty threads: 5/50 (1 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:37:07 DEBUG middleware.log :: POST /api/util/password_check 200 919.1 µs (0 DB calls) App DB connections: 0/10 Jetty threads: 5/50 (2 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:37:15 DEBUG middleware.log :: POST /api/util/password_check 200 1.0 ms (0 DB calls) App DB connections: 1/10 Jetty threads: 5/50 (2 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:37:57 INFO driver.impl :: Initializing driver :postgres...
09-02 17:38:02 ERROR driver.util :: Database connection error
java.util.concurrent.TimeoutException: Timed out after 5.0 s
In the Metabase setup screen, when I enter the connection values for my Postgres database, I always get this failure:
09-02 17:36:00 DEBUG middleware.log :: GET /api/session/properties 200 3.1 ms (0 DB calls) App DB connections: 0/10 Jetty threads: 7/50 (0 idle, 0 queued) (47 total active threads) Queries in flight: 0 (0 queued)
09-02 17:36:01 DEBUG middleware.log :: GET /api/session/properties 200 2.9 ms (0 DB calls) App DB connections: 0/10 Jetty threads: 6/50 (1 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:36:42 DEBUG middleware.log :: POST /api/util/password_check 200 1.8 ms (0 DB calls) App DB connections: 0/10 Jetty threads: 5/50 (1 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:37:07 DEBUG middleware.log :: POST /api/util/password_check 200 919.1 µs (0 DB calls) App DB connections: 0/10 Jetty threads: 5/50 (2 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:37:15 DEBUG middleware.log :: POST /api/util/password_check 200 1.0 ms (0 DB calls) App DB connections: 1/10 Jetty threads: 5/50 (2 idle, 0 queued) (48 total active threads) Queries in flight: 0 (0 queued)
09-02 17:37:57 INFO driver.impl :: Initializing driver :postgres...
09-02 17:38:02 ERROR driver.util :: Database connection error
java.util.concurrent.TimeoutException: Timed out after 5.0 s
I am able to connect to this database from the server that is running Metabase using Postgres PSQL.