添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement . We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account 502 Bad Gateway..

i think it is postresql problem.
how can i access to thingsboard's database?

here is part of the error log.

2024-07-01 08:28:10,743 [sql-queue-1-ts-11-thread-1] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: 08001
2024-07-01 08:28:10,743 [sql-queue-1-ts-11-thread-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Connection is not available, request timed out after 30000ms.
2024-07-01 08:28:10,743 [sql-queue-0-ts-10-thread-1] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: 08001
2024-07-01 08:28:10,743 [sql-queue-1-ts-11-thread-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - Connection to localhost:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
2024-07-01 08:28:10,743 [sql-queue-0-ts-10-thread-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Connection is not available, request timed out after 30000ms.
2024-07-01 08:28:10,743 [sql-queue-0-ts-10-thread-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - Connection to localhost:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
2024-07-01 08:28:10,743 [sql-queue-2-ts-12-thread-1] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: 08001
2024-07-01 08:28:10,743 [sql-queue-2-ts-12-thread-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Connection is not available, request timed out after 30000ms.
2024-07-01 08:28:10,743 [sql-queue-2-ts-12-thread-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - Connection to localhost:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
2024-07-01 08:28:10,743 [sql-queue-1-ts-11-thread-1] ERROR o.t.s.dao.sql.TbSqlBlockingQueue - [TS] Failed to save 6 entities
org.springframework.transaction.CannotCreateTransactionException: Could not open JPA EntityManager for transaction; nested exception is org.hibernate.exception.JDBCConnectionException: Unable to acquire JDBC Connection
2024-07-01 08:28:10,743 [sql-queue-2-ts-12-thread-1] ERROR o.t.s.dao.sql.TbSqlBlockingQueue - [TS] Failed to save 6 entities
org.springframework.transaction.CannotCreateTransactionException: Could not open JPA EntityManager for transaction; nested exception is org.hibernate.exception.JDBCConnectionException: Unable to acquire JDBC Connection
2024-07-01 08:28:19,691 [JpaExecutorService-4-4] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,692 [JpaExecutorService-4-4] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,691 [JpaExecutorService-9-1] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,691 [JpaExecutorService-7-15] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,692 [JpaExecutorService-9-1] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,692 [JpaExecutorService-7-15] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,691 [JpaExecutorService-11-3] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,692 [JpaExecutorService-11-3] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,691 [JpaExecutorService-0-16] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,692 [JpaExecutorService-0-16] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,691 [JpaExecutorService-1-9] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,691 [JpaExecutorService-10-10] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,692 [JpaExecutorService-1-9] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,692 [JpaExecutorService-10-10] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 08:28:19,691 [JpaExecutorService-8-8] WARN  o.h.e.jdbc.spi.SqlExceptionHelper - SQL Error: 0, SQLState: null
2024-07-01 08:28:19,692 [JpaExecutorService-8-8] ERROR o.h.e.jdbc.spi.SqlExceptionHelper - HikariPool-1 - Interrupted during connection acquisition
2024-07-01 10:14:14,772 [main] ERROR o.s.o.j.LocalContainerEntityManagerFactoryBean - Failed to initialize JPA EntityManagerFactory: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]
2024-07-01 10:14:14,773 [main] WARN  o.s.b.w.s.c.AnnotationConfigServletWebServerApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.context.ApplicationContextException: Unable to start web server; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tomcatServletWebServerFactory' defined in class path resource [org/springframework/boot/autoconfigure/web/servlet/ServletWebServerFactoryConfiguration$EmbeddedTomcat.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory]: Factory method 'tomcatServletWebServerFactory' threw exception; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'httpTransportContext': Unsatisfied dependency expressed through field 'transportService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'defaultTransportService' defined in URL [jar:file:/usr/share/thingsboard/bin/thingsboard.jar!/BOOT-INF/lib/transport-api-3.4.4-SNAPSHOT.jar!/org/thingsboard/server/common/transport/service/DefaultTransportService.class]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'hashPartitionService' defined in URL [jar:file:/usr/share/thingsboard/bin/thingsboard.jar!/BOOT-INF/lib/queue-3.4.4-SNAPSHOT.jar!/org/thingsboard/server/queue/discovery/HashPartitionService.class]: Unsatisfied dependency expressed through constructor parameter 1; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'defaultTenantRoutingInfoService' defined in URL [jar:file:/usr/share/thingsboard/bin/thingsboard.jar!/BOOT-INF/classes!/org/thingsboard/server/service/queue/DefaultTenantRoutingInfoService.class]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'tenantServiceImpl': Unsatisfied dependency expressed through field 'tenantDao'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'jpaTenantDao': Unsatisfied dependency expressed through field 'tenantRepository'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tenantRepository' defined in org.thingsboard.server.dao.sql.tenant.TenantRepository defined in @EnableJpaRepositories declared on JpaDaoConfig: Cannot create inner bean '(inner bean)#6c42f2a1' of type [org.springframework.orm.jpa.SharedEntityManagerCreator] while setting bean property 'entityManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '(inner bean)#6c42f2a1': Cannot resolve reference to bean 'entityManagerFactory' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.class]: Invocation of init method failed; nested exception is org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]
2024-07-01 10:14:14,791 [main] INFO  o.s.b.a.l.ConditionEvaluationReportLoggingListener -