Bug#891488: postgresql: Installing postgresql fails due to "error creating symbolic link '/usr/share/man/man1/psql.1.gz.dpkg-tmp': No such file or directory"

2018-07-22 Thread Karl-Philipp Richter

> No longer marked as found in versions postgresql-common/181+deb9u1.
> Request was from Christoph Berg  to
> cont...@bugs.debian.org. (Mon, 26 Feb 2018 09:12:06 GMT) (full text,
> mbox, link).
The issue still occurs with postgresql-common/181+deb9u2. It seems to
occur in the Docker image `debian:stretch-slim` only and not in
`debian:stretch`.



signature.asc
Description: OpenPGP digital signature


Bug#891488: postgresql: Installing postgresql fails due to "error creating symbolic link '/usr/share/man/man1/psql.1.gz.dpkg-tmp': No such file or directory"

2018-07-22 Thread Karl-Philipp Richter
On Mon, 26 Feb 2018 02:31:21 + Karl-Philipp Richter
 wrote:
> Package: postgresql
> Version: 9.6+181+deb9u1
> Severity: normal
> 
> Dear Maintainer,
> 
> Installing `postgresql` in the (quite empty) Docker image 
> `debian:stretch-slim` fails due to the `dpkg` error
> 
> ```
> Setting up postgresql-client-9.6 (9.6.6-0+deb9u1) ...
> update-alternatives: using /usr/share/postgresql/9.6/man/man1/psql.1.gz to 
> provide /usr/share/man/man1/psql.1.gz (psql.1.gz) in auto mode
> update-alternatives: error: error creating symbolic link 
> '/usr/share/man/man1/psql.1.gz.dpkg-tmp': No such file or directory
> dpkg: error processing package postgresql-client-9.6 (--configure):
>  subprocess installed post-installation script returned error exit status 2
> ```
> 
> The failure is repeatable 100% of times. I attached the output of an example 
> run as `postgresql.log`. In case this is a user error (e.g. if it's 
> impossible to install postgresql in such a minimal environment) the feedback 
> should be improved.
> 
> 
> -- System Information:
> Debian Release: 9.3
>   APT prefers stable-updates
>   APT policy: (500, 'stable-updates'), (500, 'stable')
> Architecture: amd64 (x86_64)
> 
> Kernel: Linux 4.13.0-21-generic (SMP w/8 CPU cores)
> Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968), LANGUAGE=C 
> (charmap=ANSI_X3.4-1968)
> Shell: /bin/sh linked to /bin/dash
> Init: unable to detect
> 
> Versions of packages postgresql depends on:
> iu  postgresql-9.6  9.6.6-0+deb9u1
> 
> postgresql recommends no packages.
> 
> Versions of packages postgresql suggests:
> iu  postgresql-doc  9.6+181+deb9u1
> 
> -- no debconf information
I work around this issue with `mkdir -p /usr/share/man/man1/
/usr/share/man/man3/ /usr/share/man/man7/`. This issue seems to be
hidden on system which have a basic set of manpages installed (and not
having the directories which only occur in environments like minimal
Docker images), however the situation should still be handled automatically.



signature.asc
Description: OpenPGP digital signature


Bug#891488: postgresql: Installing postgresql fails due to "error creating symbolic link '/usr/share/man/man1/psql.1.gz.dpkg-tmp': No such file or directory"

2018-02-25 Thread Karl-Philipp Richter
Package: postgresql
Version: 9.6+181+deb9u1
Severity: normal

Dear Maintainer,

Installing `postgresql` in the (quite empty) Docker image `debian:stretch-slim` 
fails due to the `dpkg` error

```
Setting up postgresql-client-9.6 (9.6.6-0+deb9u1) ...
update-alternatives: using /usr/share/postgresql/9.6/man/man1/psql.1.gz to 
provide /usr/share/man/man1/psql.1.gz (psql.1.gz) in auto mode
update-alternatives: error: error creating symbolic link 
'/usr/share/man/man1/psql.1.gz.dpkg-tmp': No such file or directory
dpkg: error processing package postgresql-client-9.6 (--configure):
 subprocess installed post-installation script returned error exit status 2
```

The failure is repeatable 100% of times. I attached the output of an example 
run as `postgresql.log`. In case this is a user error (e.g. if it's impossible 
to install postgresql in such a minimal environment) the feedback should be 
improved.


-- System Information:
Debian Release: 9.3
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.13.0-21-generic (SMP w/8 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968), LANGUAGE=C 
(charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash
Init: unable to detect

Versions of packages postgresql depends on:
iu  postgresql-9.6  9.6.6-0+deb9u1

postgresql recommends no packages.

Versions of packages postgresql suggests:
iu  postgresql-doc  9.6+181+deb9u1

-- no debconf information
> sudo docker run -i -t debian:stretch-slim
Unable to find image 'debian:stretch-slim' locally
stretch-slim: Pulling from library/debian
8176e34d5d92: Pull complete 
Digest: sha256:e8e19950797443676474a4d12624325371f739f195abb3162c67df8d0fba0c50
Status: Downloaded newer image for debian:stretch-slim
root@8d140b5d195e:/# apt-get update
Get:3 http://security.debian.org stretch/updates InRelease [63.0 kB]
Ign:1 http://cdn-fastly.deb.debian.org/debian stretch InRelease   
Get:2 http://cdn-fastly.deb.debian.org/debian stretch-updates InRelease [91.0 
kB]
Get:4 http://cdn-fastly.deb.debian.org/debian stretch Release [118 kB]  
 
Get:5 http://cdn-fastly.deb.debian.org/debian stretch-updates/main amd64 
Packages [8431 B]  
Get:6 http://cdn-fastly.deb.debian.org/debian stretch Release.gpg [2434 B]
Get:7 http://security.debian.org stretch/updates/main amd64 Packages [415 kB]
Get:8 http://cdn-fastly.deb.debian.org/debian stretch/main amd64 Packages [9531 
kB]
Fetched 10.2 MB in 8s (1137 kB/s)   


Reading package lists... Done
root@8d140b5d195e:/# apt-get install --yes postgresql
Reading package lists... Done
Building dependency tree   
Reading state information... Done
The following additional packages will be installed:
  bzip2 cron dh-python distro-info-data exim4 exim4-base exim4-config 
exim4-daemon-light file guile-2.0-libs krb5-locales libbsd0 libc-l10n libedit2 
libexpat1 libffi6 libfribidi0
  libgc1c2 libgmp10 libgnutls30 libgpm2 libgsasl7 libgssapi-krb5-2 libhogweed4 
libicu57 libidn11 libk5crypto3 libkeyutils1 libkrb5-3 libkrb5support0 
libkyotocabinet16v5 libldap-2.4-2
  libldap-common libltdl7 liblzo2-2 libmagic-mgc libmagic1 libmailutils5 
libmariadbclient18 libmpdec2 libncurses5 libnettle6 libntlm0 libp11-kit0 
libpopt0 libpq5 libprocps6
  libpython2.7 libpython2.7-minimal libpython2.7-stdlib libpython3-stdlib 
libpython3.5-minimal libpython3.5-stdlib libreadline7 libsasl2-2 
libsasl2-modules libsasl2-modules-db
  libsensors4 libsqlite3-0 libssl1.1 libtasn1-6 libunistring0 libwrap0 libxml2 
libxslt1.1 locales logrotate lsb-release mailutils mailutils-common 
mime-support mysql-common netbase
  openssl postgresql-9.6 postgresql-client-9.6 postgresql-client-common 
postgresql-common postgresql-contrib-9.6 procps psmisc python3 python3-minimal 
python3.5 python3.5-minimal
  readline-common sgml-base ssl-cert sysstat tcpd ucf xml-core xz-utils
Suggested packages:
  bzip2-doc anacron checksecurity libdpkg-perl eximon4 exim4-doc-html | 
exim4-doc-info spf-tools-perl swaks gnutls-bin gpm krb5-doc krb5-user 
libsasl2-modules-gssapi-mit
  | libsasl2-modules-gssapi-heimdal libsasl2-modules-ldap libsasl2-modules-otp 
libsasl2-modules-sql lm-sensors lsb mailutils-mh mailutils-doc ca-certificates 
postgresql-doc
  locales-all postgresql-doc-9.6 libdbd-pg-perl python3-doc python3-tk 
python3-venv python3.5-venv python3.5-doc binutils binfmt-support readline-doc 
sgml-base-doc openssl-blacklist
  isag debhelper
The following NEW packages will be installed:
  bzip2 cron dh-python distro-info-data exim4 exim4-base exim4-config 
exim4-daemon-light file guile-2.0-libs krb5-locales libbsd0 libc-l10n libedit2 
libexpat1 libffi6 libfribidi0
  libgc1c2 libgmp10 libgnutls30 libgpm2 libgsasl7 libgssapi-krb5-2 libhogweed4 
libicu57 libidn11 libk5crypto3 libkeyutils1 libkrb5-3 libkrb5support0