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.

Filter by
Sorted by
Tagged with
0 votes
0 answers
33 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 ...
xpt's user avatar
  • 1,232
0 votes
3 answers
55 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 ...
Amir Sabeghi's user avatar
0 votes
0 answers
16 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 ...
qc033's user avatar
  • 1
0 votes
0 answers
69 views

Why does an upgrade from OpenSuSE Leap 15.4 to 15.5 lead to a downgrade of PostgreSQL, vim, and some other packages?

When upgrading my homelab from OpenSuSE Leap 15.4 (x86_64) to 15.5 by using zypper --releasever=15.4 dup --download-in-heaps, I am told to confirm a downgrade a bunch of packages, most (but not all) ...
Neppomuk's user avatar
  • 316
2 votes
1 answer
54 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: ...
ceving's user avatar
  • 3,461
0 votes
1 answer
446 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/...
23tux's user avatar
  • 165
0 votes
3 answers
55 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 ...
jian's user avatar
  • 539
0 votes
0 answers
71 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 ...
DrKC's user avatar
  • 3
0 votes
1 answer
62 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 ...
Anthony Bias's user avatar
1 vote
1 answer
499 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-...
Jérôme MEVEL's user avatar
0 votes
1 answer
258 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 -> /...
Jérôme MEVEL's user avatar
0 votes
0 answers
256 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 ...
Igor Savinkin's user avatar
0 votes
1 answer
306 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 <...
zircon's user avatar
  • 103
0 votes
1 answer
55 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 ?
Estatistics's user avatar
1 vote
0 answers
116 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 ...
Geuis's user avatar
  • 111
0 votes
0 answers
209 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 ...
TobKel's user avatar
  • 143
0 votes
0 answers
131 views

How to install plperl, plpython extensions in derived alpine docker image?

I am trying to set up and use the official (alpine-based) postgres docker image with Dockerfile here. But I got an error about missing libperl.so as follows: 2023-03-09 17:37:49.146 UTC [49] ERROR: ...
tinlyx's user avatar
  • 556
0 votes
0 answers
38 views

ImportError: cannot import name 'json' from 'itsdangerous' (/usr/local/lib/python3.9/dist-packages/itsdangerous/__init__.py)

I am using kali-linux. Installed pgadmin4 with python: $ sudo mkdir /var/lib/pgadmin $ sudo mkdir /var/log/pgadmin $ sudo chown $USER /var/lib/pgadmin $ sudo chown $USER /var/log/pgadmin $ python3 -m ...
Yilmaz's user avatar
  • 289
2 votes
2 answers
4k 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 ...
rubo77's user avatar
  • 27.9k
0 votes
0 answers
22 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 ...
Federico Loro's user avatar
0 votes
1 answer
127 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 --...
Bash3d's user avatar
  • 1
2 votes
0 answers
29 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/...
Bunny's user avatar
  • 41
0 votes
1 answer
64 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 - ...
laktak's user avatar
  • 5,636
0 votes
1 answer
485 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 ...
Zero5's user avatar
  • 11
1 vote
0 answers
458 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 ...
mArSeN's user avatar
  • 11
0 votes
0 answers
585 views

Debian stretch, executor failed running and some packages can not be authenticated

I have an error when I am building my Docker containers. It seems that there are problems with Postgres Stretch for Debian. I saw that Debian strech was removed and no longer supported. W: The ...
bubamara's user avatar
1 vote
0 answers
564 views

Unable to start PostgreSQL, error looks like its pointing to DB user not found

Asking for some assistance with trying to start postgresql-9.6.2 service using systemctl (systemd). I'm installing a monitoring tool that installs an instance of PostgreSQL to support the tool. It ...
A.brashear's user avatar
0 votes
1 answer
109 views

How to upgrade Postgresql 11.2 to 11.17 on Ubunutu 14.04

We have a Ubuntu 14.04 server with Postgresql 11.2 installed. We need to upgrade it to 11.17. I have read old versions of Postgresql will move to https://apt-archive.postgresql.org/. So I have updated ...
Chinna2022's user avatar
2 votes
1 answer
4k views

How can I upgrade the postgreSQL from 14 to 15 in kali linux VM?

I am setting up my first VM with debian (x64) and kali linux... I am a windows user but want to learn linux. while upgrading linux using sudo apt upgrade I got a message like this. But I do not ...
paxanoA1607's user avatar
0 votes
1 answer
56 views

Why isn't password based auth working in postgresql until I disable ident auth?

I just installed postgresql and pgadmin from the repos on Fedora 36. I set up the initial postgres role and database, and logged in with the postgres user sudo su - postgres psql From there, I set up ...
John's user avatar
  • 457
0 votes
1 answer
726 views

Unzip compressed dump and import via psql

I'm trying to dump a huge database and compress the dump in order to not have to wait hours till it's done. I dump the database the following way: pg_dump -Fc -U -v | gzip > db$(date +%d-%m-%y_%H-%...
Djabone's user avatar
  • 113
1 vote
1 answer
954 views

"CREATE EXTENSION postgis" fails with 'could not access file "$libdir/postgis-3"'

# dnf list installed | grep postgresql VRTSnbpostgresqlagent.x86_64 9.1.0.0-1620848511 @System postgresql.x86_64 ...
raphael's user avatar
  • 195
0 votes
1 answer
4k views

E: Unable to locate package postgresql-12

I'm using Linux Mint and I'm trying to upgrade PostgreSQL 10 to version 12 through sudo apt-get install postgresql-12, but I see this frequent error: E: Unable to locate package postgresql-12 So what'...
ezzeddin's user avatar
  • 105
1 vote
0 answers
99 views

promscale-extension fatal error: 'libintl.h' file not found

I'm attempting to compile promscale-extension for PostgreSQL 14.5 on FreeBSD 13.1, but I keep getting fatal error: 'libintl.h' file not found. I've verified that the file /usr/local/include/libintl.h ...
Darwin von Corax's user avatar
1 vote
0 answers
49 views

Remove duplicates from database output

Assume you have three tables in a database: name, email and phone. If you join these tables you may get following output: Alice Miller, [email protected], 12345 Alice Miller, [email protected], 12345 Alice Miller,...
Harald Lichtenstein's user avatar
0 votes
1 answer
119 views

Make Tar from Snapshot of Changing Folder (Btrfs?)

I have BTRFS on my Ubuntu server, and I’m using PostgreSQL as a database. I’d like to make a .tar.gz archive from the current state of the database folder. However, since the database is of course ...
Florian Wendelborn's user avatar
1 vote
3 answers
3k views

Debian & PostgreSQL - [ASSERT] Assertion failed for PostgreSQL Cluster 14

Right after booting Debian server I get this error: [ASSERT] Assertion failed for PostgreSQL Cluster 14. my PostgreSQL is active (I checked this by this command: systemctl status postgresql@14-main....
Saba's user avatar
  • 11
1 vote
0 answers
134 views

psql asks for a password when username in host and postgres server are identical?

I have a postgres server running in a docker container. I added a user there named "myuser". I also have a linux user named "myuser". Then (as root) I do: $ su - myser $ psql ...
birgersp's user avatar
  • 261
0 votes
0 answers
30 views

how to get backup two postgresql servers in virtual box

I'm new in postgresql and I am watching a video about it. In this video the teacher connect two real debian servers and everything works fine. I have two debian servers in my virtualbox and my ...
Saba's user avatar
  • 11
0 votes
1 answer
37 views

Creating a secure transcient duplicate of a folder for consumption by ‘psql’ running as ‘postgres’

This is a question about finding an ideal way to deal with a particular situation. In a folder under my home folder is a group of psql script files that reference each others through \include_relative ...
mesr's user avatar
  • 167
0 votes
1 answer
686 views

Dry-running psql scripts

Psql script files may (and typically do) contain psql-specific instructions, includes and variable substitutions that are resolved client-side. I am looking for a generic way of getting the sequence ...
mesr's user avatar
  • 167
0 votes
0 answers
28 views

firewalld Not Registering Directives

I've sent some commands to firewalld to open up a PostgreSQL port 5432 to be opened. nmap shows it open on localhost4 to be open, but on its ip 192.168.1.23 to be non-existent. sniffing ports 0-10000 ...
Rich_F's user avatar
  • 144
0 votes
2 answers
251 views

How to compile and pipe the output info of a executeable file

.... .... checking whether gcc supports -Wl,--as-needed... yes configure: using compiler=gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0 configure: using CFLAGS=-Wall -Wmissing-prototypes -Wpointer-arith -...
jian's user avatar
  • 539
0 votes
1 answer
43 views

make file trying to figure out postgresql source code DESTDIR mean

make append and separate by white space https://superuser.com/questions/360178/what-does-make-install-do Trying to understand the following make command. installincludes: $(INSTALL) -d '$(DESTDIR)$...
jian's user avatar
  • 539
0 votes
1 answer
644 views

systemctl status postgresql.service not working as intended

System: Ubuntu 20/WSL Check status. sudo service postgresql status or sudo pg_ctlcluster status 15 main Now I am pretty sure the status is online. But even if postgresql is online, if i do ...
jian's user avatar
  • 539
0 votes
2 answers
585 views

Upgrade matrix synapse postgresql database from 9.6 to 11

I have a VM on my server where I host a Matrix synapse homeserver. Now I need to update postgresql, because version 9.6 is EOL. The database in /var/lib/postgresql/9.6/main already has 56 GByte. I ...
rubo77's user avatar
  • 27.9k
0 votes
1 answer
881 views

Unix-domain Socket

I'm trying to set my server up and came across some troubles related to Unix domain sockets. I don't have so much experience with Unix, despite the stack for web development: Apache, PHP and SQL. I ...
Ivan Zanoth's user avatar
0 votes
1 answer
486 views

Can I pipe live data from the \watch command of postgresql into another command?

I'd like to pipe live data from psql into another command for purposes of monitoring via the shell. Can this be done? So far I have the following: $ psql bareos -c '\watch (SELECT * FROM log ORDER BY ...
leeand00's user avatar
  • 4,475
0 votes
2 answers
446 views

Slackware and postgres

I want to install postgres and psql via a Slackbuild and I did so. After installing it I tried running the command as suggested in the readme of the Slackbuild but I get an error upon running it as ...
naarter's user avatar
0 votes
1 answer
299 views

Debian - Schedule a SQL query with crontab

I wan't to schedule a SQL query in a PostgreSQL database with a crontab. In terminal, in root, when I run: psql -U postgres -d my_database -h localhost -p 5432 -c "INSERT INTO schema.table (name) ...
GeoGyro's user avatar
  • 129

1
2 3 4 5
7