[Piuparts-devel] how to report this bug? postinst connects to daemon that was not started due to policy-rc.d

Andreas Beckmann debian at abeckmann.de
Tue Apr 3 18:57:12 UTC 2012


Hi, 

please take a look at
http://piuparts.debian.org/sid/fail/keystone_2012.1~rc1-2.log

What is the proper way to report this bug? 

Installation fails during postinst configure:

  ...
  Creating config file /etc/dbconfig-common/keystone.conf with new version
  invoke-rc.d: policy-rc.d denied execution of start.
  No handlers could be found for logger "keystoneclient.client"
  Unable to communicate with identity service: [Errno 111] Connection refused. (HTTP 400)
  dpkg: error processing keystone (--configure):
   subprocess installed post-installation script returned error exit status 1

After starting the service (which does not happen due to policy-rc.d)
the postinst connects to the service to do 'some configuration', but
this connection fails because the service is not running ...

How should a package handle this case?

citadel-server for instance unconditionally starts the service during
postinst, configures it, stops it and thereafter uses invoke-rc.d to
start it (if allowed).

running the postinst with set -x and strace shows:

...
+ export SERVICE_TOKEN=ADMIN
+ export SERVICE_ENDPOINT=http://127.0.0.1:35357/v2.0/
+ strace -o /tmp/str.out keystone role-create --name=admin

...
socket(PF_INET, SOCK_STREAM, IPPROTO_TCP) = 4
setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0
connect(4, {sa_family=AF_INET, sin_port=htons(35357), sin_addr=inet_addr("127.0.0.1")}, 16) = -1 ECONNREFUSED (Connection refused)
close(4)                                = 0
write(2, "No handlers could be found for l"..., 62) = 62
write(2, "Unable to communicate with ident"..., 87) = 87
write(2, "\n", 1)                       = 1
rt_sigaction(SIGINT, {SIG_DFL, [], SA_RESTORER, 0x7f5e67dad030}, {0x42b600, [], SA_RESTORER, 0x7f5e67dad030}, 8) = 0
exit_group(1)                           = ?

Andreas



More information about the Piuparts-devel mailing list