Questions tagged [postgresql]
PostgreSQL, often simply Postgres, is an object-relational database management system (ORDBMS) available for many platforms including Linux, FreeBSD, Solaris, Microsoft Windows and Mac OS X.
365 questions
2
votes
1
answer
74
views
PostgreSQL 15 container with data directory mounted as host bind mount
I'm trying to create PostgreSQL container with bind mounted host directory in it as the PostgreSQL data directory. Doing it according to official PostgreSQL docker image documentation and Example from ...
-2
votes
2
answers
69
views
How to check version of PostgreSQL available on pacman?
Is there a way I can check what version of PostgreSQL is available on pacman without needing to install it first?
I know I can install it and then run the following SQL to get the version:
SELECT ...
-1
votes
1
answer
45
views
PostgreSQL: When would be mandatory use the "manually configure the Apt repository" approach?
To install PostgreSQL in either Debian or Ubuntu according with the official docs:
Linux downloads (Debian)
Linux downloads (Ubuntu)
Exists the PostgreSQL Apt Repository section where exists two ...
0
votes
0
answers
48
views
Ubuntu Server 24.04 difficulty with uninstalling Postgresql
I have packages that I need to remove including postgresql-client-16, postgresql-client-18, postgresql-client-common and postgreql-common. Whenever I try to remove/purge any of them I get a message ...
0
votes
0
answers
128
views
can't install pgAdmin4 desktop on arch linux
I need your help! I'm trying to install pgAdmin4 desktop version on my Arch system. I am getting libfakeroot internal error: payload not recognized! while building package for pgadmin4-server(which is ...
2
votes
1
answer
132
views
systemd-tmpfiles doesn't create /run/postgresql at reboot, but does when called manually with --create
I have a problem related to a few already answered here in the past, but the solutions offered for them already appear to be in place for me:
/var/run/postgresql missing after reboot
Tired of ...
0
votes
0
answers
64
views
Manually Installing PostgreSQL from Packages
I'm in the process of bringing my server to life. I have already installed Proxmox onto it and now I'm in the bootstrapping stage whereby I'm planning to manually install a minimum number of VMs to ...
0
votes
1
answer
66
views
ldd /usr/bin/pg_restore gives error not a dynamic executable
I am trying to determine the libraries needed for pg_restore in the official postgres:15 docker image, but when I run ldd /usr/bin/pg_restore inside the container it returns this error: not a dynamic ...
1
vote
1
answer
63
views
How to replace source list in old postgres:9 image before effectively run apt-get update
I would like to install java in final dockerfile stage from postgres:9, and I have to change following outdated addresses:
RUN sed -i s/deb.debian.org/archive.debian.org/g /etc/apt/sources.list
RUN ...
0
votes
1
answer
696
views
How to install Postgresql17 to my EC2 instance on Amazon Linux [duplicate]
I'm trying to install postgres version 17 on my EC2 instance on Amazon Linux but I get this error:
[ec2-user@ip-172-31-8-1 ~]$ sudo dnf install -y postgresql17 postgresql17-server
Last metadata ...
0
votes
1
answer
844
views
system ID mismatch, node belongs to a different cluster
I have etcd cluster, and now trying to initialize patroni (on server A and server B), but whenever I try to do so I'm getting the error about cluster mismatch. Tried removing 'initialize' from etcd, ...
1
vote
1
answer
135
views
/proc/pid exists but does pid not found in ps
I am seeing a very odd behavior.
/proc/1154/cmdline exists, and kill -0 1154 succeeds,
but ps -ef | grep 1154 and ls /proc | grep 1154 do not show anything.
1154 was a postgres process in the middle ...
0
votes
1
answer
498
views
Cannot install postgres on Centos 7 as signature cannot be verified/gpg keys not imported
I am currently trying to access a postgres 12 RDS on a private VPC through an EC2 instance on the same VPC, and in order to do so I am trying to install postgres on this instance (which is a Centos 7 ...
0
votes
1
answer
257
views
An ALTER USER postgres PASSWORD 'postgres' fails when provisioning vagrant with Postgresql
I'm provisioning a vagrant box with Postgresql.
It looks going well, but at the end, it cannot run an ALTER USER postgres PASSWORD 'postgres'; for a Permission denied.
Here's what I'm doing, and what ...
-3
votes
1
answer
687
views
Issue with postgre database creation in Kali Linux
I just installed postgresql 16 on my Kali Linux. It's working perfectly but when I try to create a database (using the correct command line), it gives me this feedback :
postgres=# create database ...
0
votes
1
answer
223
views
Can't start new PostgreSQL installation on Bazzite
I've recently installed Bazzite (an atomic Fedora variant) and want to get PostgreSQL running so I can continue an online development course I'm taking. I opened BoxBuddy (a.k.a. Toolbox) and ...
0
votes
0
answers
132
views
Unable to start posgtresql on AlmaLinux 8.4
I’ve been working with the database for over a year, but after rebooting the server I can’t start postgresql:
Job for postgresql.service failed because a fatal signal was delivered causing the control ...
0
votes
1
answer
57
views
How to escape symbols inside runuser command?
I want to get list of PostgreSQL databases.
PostgreSQL works by postgres user, so I need to use runuser.
While I'm execute
runuser -l postgres -c 'psql -tc "SELECT datname FROM pg_database WHERE ...
0
votes
2
answers
235
views
Find out if user name and database are matching | grep
I found that grep -w 'desired_string' should deliver just lines exactly desired_string, but not desired_string-22 or any variant.
What I need is a check if a certain Postgres database is owned by a ...
0
votes
1
answer
598
views
Why do some repositories configured in /etc/apt/sources.list.d/ not have a signed-by= set? - Is that a problem?
Most third-party repositories configured in /etc/apt/sources.list.d have a signing key configured like this for example: deb [signed-by=/etc/apt/keyrings/lutris.gpg] https://.
However, some like the ...
0
votes
1
answer
446
views
postgresql service down, "/run/postgresql/.s.PGSQL.5432" failed: No such file or directory
i on artix with runit postgresql have issues after starting
#sudo sv start postgresql
ok: run: postgresql: (pid 849) 1236s
#sudo -u postgres psql
psql: error: connection to server on socket "/run/...
1
vote
0
answers
208
views
Ubuntu service - pq: password authentication failed for user "root"
I have an application running on Ubuntu server that's using PostgreSQL.
I can run the application's executable (as a non-root user) from the project's directory.
I have created a service for this ...
1
vote
2
answers
1k
views
PostgreSQL Failing to Start Even after Reinstalling on Arch Linux
It's been some months since I've last used PostgreSQL on my Arch Linux desktop, and, apparently, after some updates, something must have broken. If I ask for the service's status, I get (systemctl ...
1
vote
1
answer
2k
views
Running sudo apt-gt update gives E: The repository 'https://apt.postgresql.org/pub/repos/apt virginia-pgdg Release' does not have a Release file
I am using Linux Mint Cinnamon 21.3 Virginia.
I installed PostgreSQL recently and the installation proceeded successfully. However, there seems to be some issue with the package manager now.
On ...
1
vote
1
answer
2k
views
Trying to install postgresql16-client on an Alpine Docker Container
I'm trying to create a Docker container with postgresql16-client but i'm getting an error saying that the package does not exist.
I'm going to also install dotnet 8 on this container in order to run ...
0
votes
1
answer
1k
views
How to connect postgresql database without using sudo
I need to create a postgres database on a linux server. However, I don't have admin privileges and cannot use sudo. How to install postgres and create a database without using sudo. I looked at ...
-1
votes
2
answers
219
views
410 Gone [IP: 2606:4700:20::681a:d05 443] when trying to run sudo apt update
I have been trying to fix an error when running docker and as a result want to update my kali version, however i receive this when running sudo apt update
E: Failed to fetch https://mirror.mwt.me/...
1
vote
1
answer
5k
views
Obsolate postgresql version 15 on Kali
I'm begginer who tries to start working with Kali Linux so I downloaded virtual box, then kali, but after command 'sudo apt upgrade -y && sudo apt update' I got message that postgresql 15 is ...
0
votes
0
answers
455
views
How was my postgres docker container hacked / infected
My VPS have been infected by the kdevtmpfsi malware, twice. That's the problem, because I've taken every possible precaution after being infected for the first time, and I have no idea how I'm being ...
0
votes
3
answers
533
views
Tracking the source of PostgreSQL authentication failures in Linux Localhost
I have these logs in my PostgreSQL database log file that appeared after I changed the database password.
2023-09-14 11:57:15.937 UTC [3401773] username@db-name FATAL: password authentication failed ...
0
votes
0
answers
76
views
Ubuntu - PostegreSQL displays errors in foreign language even after changing all locales to en_US and reinstalling it
I inherited a Ubuntu desktop from another employee and installed PostgreSQL with the help of the official guide.
abc@lenovo:~$ sudo apt install postgresql-15
I had not known that I had to setup an ...
2
votes
1
answer
392
views
How to tell rsyslog to use Unix domain sockets to write syslog messages to a Postgresql database?
I created a database as explained here:
https://github.com/rsyslog/rsyslog/blob/master/plugins/ompgsql/createDB.sql
I created a "root" user in the database and granted insert permissions:
...
1
vote
1
answer
4k
views
Debian Bullseye install error for postgresql-client-15 (Depends: libreadline7 (>= 6.0) but it is not installable)
I'm inside a docker container that uses the Ruby 3.2.2 Debian 11 bullseye image as a base image (see https://github.com/docker-library/ruby/blob/ed1be47a38a7a24a0aa03c450549afcb592f02a8/3.2/bullseye/...
0
votes
3
answers
83
views
comment out line between in a file based on pattern
File: /home/jian/Desktop/pg_sources/main/postgres/src/test/regress/sql/test_setup.sql
246: --
247: -- Create some C functions that will be used by various tests.
248: --
249:
250: CREATE FUNCTION ...
0
votes
0
answers
322
views
I cannot add users or otherwise control PostgreSQL 15 using openSUSE Tubleweed (updated recently)
I just switched workstations and installed openSUSE Tumbleweed and PostgreSQL 15 using the postgresql database repo.
Details:
Kernel: 6.3.4-1-default arch: x86_64 bits: 64 Desktop: LXQt
v: 1.3.0 ...
0
votes
1
answer
160
views
Cannot start postgres service because expected file is not in run directory
I recently tried to install postgres on my arch machine. I was able to run the initdb command as the postgres user, but I cannot actually run the service. This is what I see in my terminal when I try ...
1
vote
1
answer
5k
views
Permission denied when starting PostgreSQL service using systemctl but works with postmaster
I previously installed PostgreSQL by following this documentation then I uninstalled it using the following commands (I'm on Fedora)
sudo rm -rf /var/lib/pgsql/
sudo dnf remove postgresql postgresql-...
0
votes
1
answer
1k
views
PostgreSQL not working after creating a symbolic link on the pg_hba.conf file
I'm trying to create a symbolic link on /var/lib/pgsql/data/pg_hba.conf (default path on Fedora) pointing to the real file located somewhere else, for example /var/lib/pgsql/data/pg_hba.conf -> /...
0
votes
0
answers
784
views
AlmaLinux Postgersql installation error
I've followed the instruction at here to install Postgresql at AlmaLinux. But the error persists.
$ sudo yum install -y postgresql15-server
The error:
PostgreSQL 9.6 for RHEL/CentOS 8 - x86_64 ...
1
vote
1
answer
1k
views
how to download postgres data in csv format through bash script?
I am able to connect to db also getting output but it's not coming in proper format. So how to get the output in csv like format and also want to save that in csv format.
psql -d <db> -U <...
-1
votes
1
answer
199
views
[email protected] fails to load but not [email protected] - are both needed in linux boot?
[email protected] fails to load but not [email protected] - are both needed in linux boot?
linux - bookworm sid.
So [email protected] is needed ?
1
vote
1
answer
2k
views
Unable to change Postgresql data directory with systemd service overrides on Ubuntu 22
I am trying to change the data directory that Postgres uses to look for its configuration files.
I have a fresh update of Ubuntu 22 and newly installed Postgresql@15.
In order to maintain version ...
0
votes
0
answers
537
views
Fedora: Error when install Postgres SQL: nothing provides libicui18n.so.69()
I had installed the Postgresql database on my Fedora system, which worked without problems.
After some time I had uninstalled Postgres and wanted to reinstall it.
When reinstalling with the following ...
8
votes
3
answers
15k
views
Upgrade your postgreSQL Database from 14 to 15 on Debian
I wonder how I can upgrade the data from an existing PostgreSQL 14 installation to 15.
I automatically got PG 15 installed via apt, so I see
# dpkg -l | grep ii | cut -d" " -f3 | grep ...
0
votes
0
answers
256
views
PostgreSQL: indexes and partitions
I have a PostgreSQL database and I noticed a weird behaviour while working with indexes and partitions. The engine version is 10.21.
Now, I have a table with this structure:
guid varchar(50) PK
guid_a ...
0
votes
1
answer
312
views
Bash: psql command not found when called inside a function
I have a bash script, where the psql connect string is stored in a variable.
After this I have defined three functions.
—————————
export PC="usr/bin/psql --host=abx --port=1234 --dbname=A --...
2
votes
0
answers
135
views
Is there a single command to remove a package source and its signing key?
I added the postgresql package source to my Linux Mint system. I'm new to apt and was wondering if, instead of deleting the package source from /etc/apt/sources.list.d and the signing key from /etc/...
1
vote
1
answer
385
views
Running psql with a role
When using psql I always have to issue set role ... first.
Could this be executed automatically before accepting interactive commands?
E.g.:
psql -h HOST -U USER -c "set role 'ROLE';" -f -
...
0
votes
1
answer
2k
views
-bash: psql: command not found after manual installation of PostgreSQL
I installed the PostgreSQL database via source code, and I successfully up it and installed the pg admin also. I am able to execute SQL functions via it. But when I type psql in the server I am having ...
1
vote
0
answers
729
views
psql: error while loading shared libraries: libssl.so.3
after incorrectly reinstalling postgresql on Linux, an error appears:
libssl.so.3: cannot open shared object file: No such file or directory
I decided to remove postgress and looked at the commands ...