#1111593 'psql' not found and '/usr/bin/psql' permission denied by default

#1111593#5
Date:
2025-08-19 19:50:18 UTC
From:
To:
psql is now linked to /usr/share/postgresql-common/pg_wrapper (Perl script):

# realpath /usr/bin/psql
/usr/share/postgresql-common/pg_wrapper


The post-install script in the Debian package should do a
chmod 775 /usr/share/postgresql-common
because by default, the rights are not accessible to postgres user:

# ls -ld /usr/share/postgresql-common
drwx------ 6 root root 4096 19 août  21:25 /usr/share/postgresql-common


I'm using Debian Forky AMD64.

Fixed the issue by using

chmod 775 /usr/share/postgresql-common

#1111593#8
Date:
2025-08-27 16:23:44 UTC
From:
To:
Re: Gilles Quenot

Hi,

I cannot reproduce that here; setting umask 077 and installing
postgresql-client results in proper permissions on all directories.

What did you do to get the system into this state?

Christoph

#1111593#13
Date:
2025-08-27 16:23:44 UTC
From:
To:
Re: Gilles Quenot

Hi,

I cannot reproduce that here; setting umask 077 and installing
postgresql-client results in proper permissions on all directories.

What did you do to get the system into this state?

Christoph

#1111593#18
Date:
2025-08-27 19:31:15 UTC
From:
To:
Hi,


I build a Vagrant VM from scratch.

I don't change ownership of the directory.

The base is Debian 12, but I use testing apt repository.


Hi,

I cannot reproduce that here; setting umask 077 and installing
postgresql-client results in proper permissions on all directories.

What did you do to get the system into this state?

Christoph

#1111593#23
Date:
2025-08-27 19:31:15 UTC
From:
To:
Hi,


I build a Vagrant VM from scratch.

I don't change ownership of the directory.

The base is Debian 12, but I use testing apt repository.


Hi,

I cannot reproduce that here; setting umask 077 and installing
postgresql-client results in proper permissions on all directories.

What did you do to get the system into this state?

Christoph

#1111593#26
Date:
2025-08-27 20:24:12 UTC
From:
To:
Re: Gilles Quenot

Could you share the Vagrantfile?

Christoph

#1111593#31
Date:
2025-08-28 13:10:51 UTC
From:
To:
Hi,


AFAIK, there's nothing interesting inside this Vagrantfile:
-------8<------------------ # -*- mode: ruby -*- # vi: set ft=ruby : Vagrant.configure("2") do |config| config.vm.box = "debian/bookworm64" config.disksize.size = '1024GB' config.vm.network "private_network", ip: "192.168.56.2" config.vm.provider "virtualbox" do |v| v.gui = false v.memory = "8192" v.cpus = 4 end config.vm.provision "shell", inline: <<-SHELL ln -sv /vm_share/files/install-stuff.sh /usr/local/bin/install-stuff.sh apt-get -yq update; apt-get -yq install screen screen -d -m -S install /usr/local/bin/install-stuff.sh SHELL end -------8<------------------ The subscript install-stuff.sh have been checked, there's no ownership change of the postgres directory. This is how I install postgres: -------8<------------------ apt-get -t testing -o DPkg::options::="--force-confdef" -o Dpkg::Options::="--force-confold" -yq install postgresql-$pg_version -------8<------------------ Gilles Could you share the Vagrantfile? Christoph
#1111593#34
Date:
2025-08-29 15:43:14 UTC
From:
To:
Re: Gilles Quenot

Are you creating any PG directories in there? I need to see the file
to be sure.

Christoph