Jira (PDB-4445) puppetdb hangs on first start after installation

8 views
Skip to first unread message

Daniel Krämer

unread,
Jun 26, 2019, 9:26:03 AM6/26/19
to puppe...@googlegroups.com
Daniel Krämer created an issue
 
PuppetDB / Bug PDB-4445
puppetdb hangs on first start after installation
Issue Type: Bug Bug
Affects Versions: PDB 5.2.8, PDB 5.1.3
Assignee: Unassigned
Components: PuppetDB
Created: 2019/06/26 6:25 AM
Priority: Major Major
Reporter: Daniel Krämer

Distri: Debian 9

Packages from: http://apt.puppetlabs.com/ stretch puppet5

I just try to install and start puppetdb in a virtual machine right after i installed puppetserver.

On first start of puppetdb it just hangs.

Log:

[...]
2019-06-26 13:08:12,575 INFO  [p.p.s.migrate] Applying database migration version 64
2019-06-26 13:08:12,576 INFO  [p.p.s.migrate] [1/8] Cleaning up unreferenced facts...
2019-06-26 13:08:12,580 INFO  [p.p.s.migrate] [2/8] Creating new fact storage tables...
2019-06-26 13:08:12,589 INFO  [p.p.s.migrate] [3/8] Copying unique fact values into fact_values
2019-06-26 13:08:12,592 INFO  [p.p.s.migrate] [4/8] Reconstructing facts to refer to fact_values...
2019-06-26 13:08:12,596 INFO  [p.p.s.migrate] [5/8] Cleaning up duplicate null values...
2019-06-26 13:08:12,598 INFO  [p.p.s.migrate] [6/8] Computing fact value hashes...
2019-06-26 13:08:12,600 INFO  [p.p.s.migrate] [7/8] Indexing fact_values table...
2019-06-26 13:08:12,614 INFO  [p.p.s.migrate] [8/8] Indexing facts table...
2019-06-26 13:08:12,626 INFO  [p.p.s.migrate] Applied database migration version 64 in 51 ms
2019-06-26 13:08:12,627 INFO  [p.p.s.migrate] Applying database migration version 65
 
==> /var/log/postgresql/postgresql-10-main.log <==
2019-06-26 13:08:12.633 GMT [3434] puppetdb@puppetdb ERROR:  relation "resource_events_status_for_corrective_change_idx" already exists
2019-06-26 13:08:12.633 GMT [3434] puppetdb@puppetdb STATEMENT:  alter table resource_events
	     alter column status type text,
	     alter column property type text,
	     alter column containing_class type text,
	     alter column file type text
 
==> /var/log/puppetlabs/puppetdb/puppetdb.log <==
2019-06-26 13:08:12,644 ERROR [p.p.s.migrate] Caught SQLException during migration
java.sql.BatchUpdateException: Batch entry 1 alter table resource_events
     alter column status type text,
     alter column property type text,
     alter column containing_class type text,
     alter column file type text was aborted.  Call getNextException to see the cause.
	at org.postgresql.jdbc.BatchResultHandler.handleError(BatchResultHandler.java:133)
	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2004)
	at 
 
[...]
 
clojure.core.async.impl.channels.ManyToManyChannel$fn__17042$fn__17043.invoke(channels.clj:95)
	at clojure.lang.AFn.run(AFn.java:22)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
2019-06-26 13:08:12,667 INFO  [p.t.internal] Shutting down due to JVM shutdown hook.
2019-06-26 13:08:12,670 INFO  [p.t.internal] Beginning shutdown sequence

 

Tried installation with module puppetlabs-puppetdb

and by hand with instructions from

https://puppet.com/docs/puppetdb/5.1/install_from_packages.html

https://puppet.com/docs/puppetdb/5.1/configure.html#using-postgresql

 

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93)
Atlassian logo

Daniel Krämer

unread,
Jun 26, 2019, 9:27:03 AM6/26/19
to puppe...@googlegroups.com
Daniel Krämer updated an issue
Change By: Daniel Krämer
Attachment: puppet_fail_start.txt

Daniel Krämer

unread,
Jun 26, 2019, 10:07:03 AM6/26/19
to puppe...@googlegroups.com
Daniel Krämer updated an issue
Change By: Daniel Krämer
Method Found: Needs Assessment

Charlie Sharpsteen (JIRA)

unread,
Jun 26, 2019, 10:43:03 AM6/26/19
to puppe...@googlegroups.com
Charlie Sharpsteen commented on Bug PDB-4445
 
Re: puppetdb hangs on first start after installation

Postgres versions released last Thursday June 20th, which includes 9.6.14, contain a regression in the behavior of the ALTER TABLE statement that is causing this issue by preventing PuppetDB from initializing its database schema. A concise summary of the issue can be found in this message to the Postgres mailing list:

https://www.postgresql.org/message-id/20190621004554.GB1626%40paquier.xyz

There is a preliminary patch up for PuppetDB to work around the issue:

https://github.com/puppetlabs/puppetdb/pull/3010

Until PuppetDB or Postgres release a new version, the best workaround is to use an older version of Postgres such as 9.6.13.

Closing as a duplicate of PDB-4422.

Reply all
Reply to author
Forward
0 new messages