开始使用Puppet Learning VM后,我第一次尝试安装puppet。我的问题是我无法让PuppetDB作为服务启动,而且我找不到足以表明任何问题的错误消息。 (session_token
)
然而,当我运行Shutting down due to JVM shutdown hook.
时,PuppetDB似乎没有关闭就开始了,但是在puppetdb foreground
之后没有进一步的输出。
任何人都可以提出问题所在吗?有没有其他地方我可以寻找可能使事情更清楚的日志?
是否超时,因为最终输出PuppetDB finished starting, disabling maintenance mode
不是预期的?
我已通过检查http://localhost:8080/pdb/dashboard/index.html确认PuppetDB finished starting, disabling maintenance mode
确实有效。
要将puppetdb作为服务启动,我会运行puppetdb foreground
或service puppetdb start
。
puppet resource service puppetdb ensure=running
journalctl
# puppet resource service puppetdb ensure=running
Error: Could not start Service[puppetdb]: Execution of '/usr/bin/systemctl start puppetdb' returned 1: Job for puppetdb.service failed. See 'systemctl status puppetdb.service' and 'journalctl -xn' for details.
Error: /Service[puppetdb]/ensure: change from stopped to running failed: Could not start Service[puppetdb]: Execution of '/usr/bin/systemctl start puppetdb' returned 1: Job for puppetdb.service failed. See 'systemctl status puppetdb.service' and 'journalctl -xn' for details.
/var/log/puppetlabs/puppetdb/puppetdb.log
Nov 25 21:58:36 hostname systemd[1]: Unit puppetdb.service entered failed state.
Nov 25 21:58:36 hostname systemd[1]: Failed to start puppetdb Service.
Nov 25 21:58:35 hostname systemd[1]: puppetdb.service operation timed out. Stopping.
Nov 25 21:58:01 hostname CROND[15785]: (root) CMD (/usr/local/rtm/bin/rtm 32 > /dev/null 2> /dev/null)
Nov 25 21:58:01 hostname systemd[1]: Started Session c1982 of user root.
Nov 25 21:58:01 hostname systemd[1]: Starting Session c1982 of user root.
Nov 25 21:57:01 hostname CROND[15496]: (root) CMD (/usr/local/rtm/bin/rtm 32 > /dev/null 2> /dev/null)
Nov 25 21:57:01 hostname systemd[1]: Started Session c1981 of user root.
Nov 25 21:57:01 hostname systemd[1]: Starting Session c1981 of user root.
Nov 25 21:56:01 hostname CROND[15207]: (root) CMD (/usr/local/rtm/bin/rtm 32 > /dev/null 2> /dev/null)
Nov 25 21:56:01 hostname systemd[1]: Started Session c1980 of user root.
Nov 25 21:56:01 hostname systemd[1]: Starting Session c1980 of user root.
Nov 25 21:55:35 hostname systemd[1]: Starting puppetdb Service...
这是我运行2015-11-25 21:55:52,831 INFO [o.e.j.u.log] Logging initialized @16842ms
2015-11-25 21:55:55,301 INFO [p.t.s.w.jetty9-service] Initializing web server(s).
2015-11-25 21:55:55,334 INFO [p.p.pdb-routing] Starting PuppetDB, entering maintenance mode
2015-11-25 21:55:55,369 INFO [p.t.s.n.nrepl-service] nREPL service disabled, not starting
2015-11-25 21:55:55,370 INFO [p.t.s.w.jetty9-service] Starting web server(s).
2015-11-25 21:55:55,480 INFO [p.t.s.w.jetty9-core] Starting web server.
2015-11-25 21:55:55,483 INFO [o.e.j.s.Server] jetty-9.2.z-SNAPSHOT
2015-11-25 21:55:55,511 INFO [o.e.j.s.h.ContextHandler] Started o.e.j.s.h.ContextHandler@689754d0{/pdb,null,AVAILABLE}
2015-11-25 21:55:55,525 INFO [o.e.j.s.ServerConnector] Started ServerConnector@594ee70f{HTTP/1.1}{127.0.0.1:8080}
2015-11-25 21:55:55,568 INFO [o.e.j.s.ServerConnector] Started ServerConnector@59de9c86{SSL-HTTP/1.1}{127.0.0.1:8081}
2015-11-25 21:55:55,569 INFO [o.e.j.s.Server] Started @19582ms
2015-11-25 21:55:55,572 INFO [p.p.metrics] Starting metrics server
2015-11-25 21:55:55,574 INFO [o.e.j.s.h.ContextHandler] Started o.e.j.s.h.ContextHandler@322f974b{/metrics,null,AVAILABLE}
2015-11-25 21:55:55,597 INFO [p.p.c.services] PuppetDB version 3.2.0
2015-11-25 21:55:55,691 INFO [p.p.s.migrate] There are no pending migrations
2015-11-25 21:55:55,701 INFO [c.j.b.BoneCP] Shutting down connection pool...
2015-11-25 21:55:55,703 INFO [c.j.b.BoneCP] Connection pool has been shutdown.
2015-11-25 21:55:55,705 INFO [p.p.c.services] Starting broker
2015-11-25 21:55:56,370 INFO [o.a.a.s.k.MessageDatabase] KahaDB is version 5
2015-11-25 21:55:56,379 INFO [o.a.a.s.k.MessageDatabase] Recovering from the journal ...
2015-11-25 21:55:56,381 INFO [o.a.a.s.k.MessageDatabase] Recovery replayed 32 operations from the journal in 0.009 seconds.
2015-11-25 21:55:56,474 INFO [p.p.c.services] Starting sweep of stale reports (threshold: 14 days)
2015-11-25 21:55:56,496 INFO [p.p.c.services] Finished sweep of stale reports (threshold: 14 days)
2015-11-25 21:55:56,497 INFO [p.p.c.services] Starting database garbage collection
2015-11-25 21:55:56,517 INFO [p.p.c.services] Finished database garbage collection
2015-11-25 21:55:56,591 INFO [p.p.dashboard] Redirecting / to the PuppetDB dashboard
2015-11-25 21:55:56,594 INFO [o.e.j.s.h.ContextHandler] Started o.e.j.s.h.ContextHandler@2372a439{/,null,AVAILABLE}
2015-11-25 21:55:56,595 INFO [p.p.pdb-routing] PuppetDB finished starting, disabling maintenance mode
2015-11-25 21:58:35,987 INFO [p.t.internal] Shutting down due to JVM shutdown hook.
2015-11-25 21:58:35,988 INFO [p.t.internal] Beginning shutdown sequence
2015-11-25 21:58:36,005 INFO [p.p.c.services] Shutdown request received; puppetdb exiting.
2015-11-25 21:58:36,006 INFO [p.p.c.services] Shutting down the messsage queues.
2015-11-25 21:58:36,525 INFO [c.j.b.BoneCP] Shutting down connection pool...
2015-11-25 21:58:36,528 INFO [c.j.b.BoneCP] Connection pool has been shutdown.
2015-11-25 21:58:36,528 INFO [c.j.b.BoneCP] Shutting down connection pool...
2015-11-25 21:58:36,530 INFO [c.j.b.BoneCP] Connection pool has been shutdown.
2015-11-25 21:58:36,532 INFO [p.t.s.w.jetty9-service] Shutting down web server(s).
2015-11-25 21:58:36,533 INFO [p.t.s.w.jetty9-core] Shutting down web server.
2015-11-25 21:58:36,535 INFO [o.e.j.s.ServerConnector] Stopped ServerConnector@594ee70f{HTTP/1.1}{127.0.0.1:8080}
2015-11-25 21:58:36,536 INFO [o.e.j.s.ServerConnector] Stopped ServerConnector@59de9c86{SSL-HTTP/1.1}{127.0.0.1:8081}
2015-11-25 21:58:36,536 INFO [o.e.j.s.h.ContextHandler] Stopped o.e.j.s.h.ContextHandler@2372a439{/,null,UNAVAILABLE}
2015-11-25 21:58:36,536 INFO [o.e.j.s.h.ContextHandler] Stopped o.e.j.s.h.ContextHandler@322f974b{/metrics,null,UNAVAILABLE}
2015-11-25 21:58:36,536 INFO [o.e.j.s.h.ContextHandler] Stopped o.e.j.s.h.ContextHandler@689754d0{/pdb,null,UNAVAILABLE}
2015-11-25 21:58:36,537 INFO [p.t.s.w.jetty9-core] Web server shutdown
2015-11-25 21:58:36,538 INFO [p.t.internal] Finished shutdown sequence
puppetdb foreground