Server fails to remain started

Sienna Lloyd4 years ago

I'm running the Traccar 4.12 Docker image in Kubernetes with this config (sanitized for security):

<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE properties SYSTEM 'http://java.sun.com/dtd/properties.dtd'>
<properties>
  <entry key='database.driver'>org.postgresql.Driver</entry>
  <entry key='database.url'>jdbc:postgresql://<host>:5432/traccar</entry>
  <entry key='database.user'>username</entry>
  <entry key='database.password'>password</entry>
  <entry key='logger.console'>true</entry>
  <entry key='logger.level'>all</entry>
</properties>

The server is just stopping, with no noticeable reason for failure. I've checked firewalls, network paths, credentials, etc. I cannot figure out a reason the server would just stop as everything else is fine. Thoughts?

$ kubectl logs -f hurricane-server-traccar-0
2021-06-14 21:35:21 DEBUG: Driver class org.postgresql.Driver found in Thread context class loader sun.misc.Launcher$AppClassLoader@33909752
2021-06-14 21:35:21 DEBUG: HikariPool-1 - configuration:
2021-06-14 21:35:21 DEBUG: allowPoolSuspension................................false
2021-06-14 21:35:21 DEBUG: autoCommit................................true
2021-06-14 21:35:21 DEBUG: catalog................................none
2021-06-14 21:35:21 DEBUG: connectionInitSql................................"SELECT 1"
2021-06-14 21:35:21 DEBUG: connectionTestQuery................................none
2021-06-14 21:35:21 DEBUG: connectionTimeout................................30000
2021-06-14 21:35:21 DEBUG: dataSource................................none
2021-06-14 21:35:21 DEBUG: dataSourceClassName................................none
2021-06-14 21:35:21 DEBUG: dataSourceJNDI................................none
2021-06-14 21:35:21 DEBUG: dataSourceProperties................................{password=<masked>}
2021-06-14 21:35:21 DEBUG: driverClassName................................"org.postgresql.Driver"
2021-06-14 21:35:21 DEBUG: exceptionOverrideClassName................................none
2021-06-14 21:35:21 DEBUG: healthCheckProperties................................{}
2021-06-14 21:35:21 DEBUG: healthCheckRegistry................................none
2021-06-14 21:35:21 DEBUG: idleTimeout................................600000
2021-06-14 21:35:21 DEBUG: initializationFailTimeout................................1
2021-06-14 21:35:21 DEBUG: isolateInternalQueries................................false
2021-06-14 21:35:21 DEBUG: jdbcUrl................................jdbc:postgresql://<host>:5432/traccar
2021-06-14 21:35:21 DEBUG: keepaliveTime................................0
2021-06-14 21:35:21 DEBUG: leakDetectionThreshold................................0
2021-06-14 21:35:21 DEBUG: maxLifetime................................1800000
2021-06-14 21:35:21 DEBUG: maximumPoolSize................................10
2021-06-14 21:35:21 DEBUG: metricRegistry................................none
2021-06-14 21:35:21 DEBUG: metricsTrackerFactory................................none
2021-06-14 21:35:21 DEBUG: minimumIdle................................10
2021-06-14 21:35:21 DEBUG: password................................<masked>
2021-06-14 21:35:21 DEBUG: poolName................................"HikariPool-1"
2021-06-14 21:35:21 DEBUG: readOnly................................false
2021-06-14 21:35:21 DEBUG: registerMbeans................................false
2021-06-14 21:35:21 DEBUG: scheduledExecutor................................none
2021-06-14 21:35:21 DEBUG: schema................................none
2021-06-14 21:35:21 DEBUG: threadFactory................................internal
2021-06-14 21:35:21 DEBUG: transactionIsolation................................default
2021-06-14 21:35:21 DEBUG: username................................"<username>@<host>"
2021-06-14 21:35:21 DEBUG: validationTimeout................................5000
2021-06-14 21:35:21  INFO: HikariPool-1 - Starting...
2021-06-14 21:35:21 DEBUG: Loading driver configuration via classloader {0}
2021-06-14 21:35:21 DEBUG: Connecting with URL: {0}
2021-06-14 21:35:21 DEBUG: PostgreSQL JDBC Driver 42.2.18
2021-06-14 21:35:21 DEBUG:   setDefaultFetchSize = {0}
2021-06-14 21:35:21 DEBUG:   setPrepareThreshold = {0}
2021-06-14 21:35:21 DEBUG: Trying to establish a protocol version 3 connection to {0}
2021-06-14 21:35:21 TRACE: Creating new Encoding {0} with fastASCIINumbers {1}
2021-06-14 21:35:21 TRACE: Creating new Encoding {0} with fastASCIINumbers {1}
2021-06-14 21:35:21 TRACE: Creating new Encoding {0} with fastASCIINumbers {1}
2021-06-14 21:35:21 DEBUG: Receive Buffer Size is {0}
2021-06-14 21:35:21 DEBUG: Send Buffer Size is {0}
2021-06-14 21:35:21 TRACE:  FE=> SSLRequest
...
2021-06-14 21:35:23 TRACE:  <=BE ParseComplete [{0}]
2021-06-14 21:35:23 TRACE:  <=BE BindComplete [{0}]
2021-06-14 21:35:23 TRACE:  <=BE RowDescription({0})
2021-06-14 21:35:23 TRACE:         {0}
2021-06-14 21:35:23 TRACE:  <=BE DataRow(len={0})
2021-06-14 21:35:23 TRACE:  <=BE CommandStatus({0})
2021-06-14 21:35:23 TRACE:  <=BE ReadyForQuery({0})
2021-06-14 21:35:23 DEBUG: HikariPool-1 - Added connection org.postgresql.jdbc.PgConnection@4a386502
2021-06-14 21:35:23 DEBUG: HikariPool-1 - After adding stats (total=10, active=0, idle=10, waiting=0)
2021-06-14 21:35:51 DEBUG: HikariPool-1 - Pool stats (total=10, active=0, idle=10, waiting=0)
2021-06-14 21:35:51 DEBUG: HikariPool-1 - Fill pool skipped, pool is at sufficient level.
2021-06-14 21:36:21 DEBUG: HikariPool-1 - Pool stats (total=10, active=0, idle=10, waiting=0)
2021-06-14 21:36:21 DEBUG: HikariPool-1 - Fill pool skipped, pool is at sufficient level.
2021-06-14 21:36:36  INFO: Shutting down server...
Anton Tananaev4 years ago

Is there a reason you enabled all log levels? It actually makes it impossible to compare to what it should actually look like, so I don't think it's very useful.

Sienna Lloyd4 years ago

I have them all enabled for debugging, I'm going to be turning the off after I find the problem. This is a net-new deployment, so there's not a "normal" log stream yet. I can't find any errors with my config or causes that would make the server shutdown. It usually shuts down about 25-35 seconds after it boots, but I can't figure out why. I thought it was the database connection but I've resolved all those errors.