部署Thingworx时无法连上Postgres数据库

weixin_42758005 2018-07-24 06:22:11
数据库连接配置:
"PostgresPersistenceProviderPackage": {
"ConnectionInformation": {
"acquireIncrement": 5,
"acquireRetryAttempts": 3,
"acquireRetryDelay": 10000,
"checkoutTimeout": 1000000,
"driverClass": "org.postgresql.Driver",
"fetchSize": 5000,
"idleConnectionTestPeriod": 60,
"initialPoolSize": 5,
"jdbcUrl": "jdbc:postgresql://localhost:5432/thingworx",
"maxConnectionAge": 0,
"maxIdleTime": 0,
"maxIdleTimeExcessConnections": 300,
"maxPoolSize": 100,
"maxStatements": 100,
"minPoolSize": 5,
"numHelperThreads": 8,
"password": "twadmin",
"testConnectionOnCheckout": false,
"unreturnedConnectionTimeout": 0,
"username": "twadmin"
},

日志:
2018-07-24 18:10:55.906+0800 [L: INFO] [O: c.t.s.ThingWorxBootstrapper] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] WebApp starting...
2018-07-24 18:10:55.906+0800 [L: WARN] [O: c.t.s.ThingWorxBootstrapper] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Please note. Default character is set to GBK. It should be [UTF-8]. Please use the VM argument [-Dfile.encoding=UTF-8] in your application server startup script
2018-07-24 18:10:56.301+0800 [L: INFO] [O: c.t.s.ThingWorxServer] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] HA mode not enabled. Initializing and starting in standalone mode.
2018-07-24 18:10:56.302+0800 [L: INFO] [O: c.t.s.ThingWorxPersistenceHandler] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Default Persistence Provider Name = ThingworxPersistenceProvider
2018-07-24 18:10:56.302+0800 [L: INFO] [O: c.t.s.ThingWorxPersistenceHandler] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Default Persistence Provider Package Name = PostgresPersistenceProviderPackage
2018-07-24 18:10:56.307+0800 [L: INFO] [O: c.t.p.p.PostgresDatasource] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Reading configuration from configTableCol
2018-07-24 18:10:56.435+0800 [L: INFO] [O: c.t.s.ThingWorxServer] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Managers...INITIALIZED
2018-07-24 18:10:56.437+0800 [L: INFO] [O: c.t.s.ThingWorxServer] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Database initialization started...
2018-07-24 18:11:26.740+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#4] com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@d553f34 -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (3). Last acquisition attempt exception:
2018-07-24 18:11:26.740+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#3] com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@45feb462 -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (3). Last acquisition attempt exception:
2018-07-24 18:11:26.742+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#4] Having failed to acquire a resource, com.mchange.v2.resourcepool.BasicResourcePool@68da485 is interrupting all Threads waiting on a resource to check out. Will try again in response to new client requests.
2018-07-24 18:11:26.742+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#3] Having failed to acquire a resource, com.mchange.v2.resourcepool.BasicResourcePool@68da485 is interrupting all Threads waiting on a resource to check out. Will try again in response to new client requests.
2018-07-24 18:11:26.743+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#0] com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@2171d6e7 -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (3). Last acquisition attempt exception:
2018-07-24 18:11:26.743+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#0] Having failed to acquire a resource, com.mchange.v2.resourcepool.BasicResourcePool@68da485 is interrupting all Threads waiting on a resource to check out. Will try again in response to new client requests.
2018-07-24 18:11:26.745+0800 [L: ERROR] [O: c.t.s.ThingWorxServer] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] [message: Connections could not be acquired from the underlying database!]
2018-07-24 18:11:26.747+0800 [L: INFO] [O: c.t.p.p.PersistenceProvider] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Connection ThingworxPersistenceProvider, type PostgresPersistenceProviderPackage stopped
2018-07-24 18:11:26.747+0800 [L: WARN] [O: c.t.p.p.PersistenceProvider] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] Could not find persistenceProviderPackage PostgresPersistenceProviderPackage and thus could not stop data processing
2018-07-24 18:11:26.749+0800 [L: ERROR] [O: c.t.s.ThingWorxBootstrapper] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] [message: Unable to initialize and start system: Connections could not be acquired from the underlying database!]
2018-07-24 18:11:26.749+0800 [L: ERROR] [O: c.t.s.ThingWorxBootstrapper] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] *** Web Application STATE is being set to ERROR! ***
2018-07-24 18:11:26.755+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#2] com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@130050d1 -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (3). Last acquisition attempt exception:
2018-07-24 18:11:26.756+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#2] Having failed to acquire a resource, com.mchange.v2.resourcepool.BasicResourcePool@68da485 is interrupting all Threads waiting on a resource to check out. Will try again in response to new client requests.
2018-07-24 18:11:26.775+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#5] com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@3708611a -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (3). Last acquisition attempt exception:
2018-07-24 18:11:26.775+0800 [L: WARN] [O: c.m.v.r.BasicResourcePool] [I: ] [U: SuperUser] [S: ] [T: C3P0PooledConnectionPoolManager[identityToken->1hge0yt9w1kjel0n10g7zey|4f0a12e6]-HelperThread-#5] Having failed to acquire a resource, com.mchange.v2.resourcepool.BasicResourcePool@68da485 is interrupting all Threads waiting on a resource to check out. Will try again in response to new client requests.
2018-07-24 18:12:05.964+0800 [L: ERROR] [O: c.t.s.a.AuthenticationFilter] [I: ] [U: ] [S: ] [T: http-nio-80-exec-32] Could not handle request
...全文
342 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
weixin_42758005 2018-07-28
  • 打赏
  • 举报
回复
在tomcat同级目录下创建一个ThingworxPlatform 文件夹,里面存放platform-settings.json 一个文件
weixin_42758005 2018-07-28
  • 打赏
  • 举报
回复
数据库连接名和端口都是正确的,因为数据脚本可以正常执行,但就是启动不了Thingworx服务。
24 18:11:26.745+0800 [L: ERROR] [O: c.t.s.ThingWorxServer] [I: ] [U: SuperUser] [S: ] [T: http-nio-80-exec-16] [message: Connections could not be acquired from the underlying database!]

10,606

社区成员

发帖
与我相关
我的任务
社区描述
Web 开发 其他
社区管理员
  • 其他
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧