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
2
votes
2answers
457 views

Installing Postgres App on Linux Mint

I've been put on a web app project that is built using Ruby on Rails and uses PostgreSQL for the database. All the other developers on the team have Macs so they just installed Postgres app to set up ...
0
votes
1answer
765 views

Installation of postgresql on linux mint 17.1 (problem with apt-get update)

I have a linux mint system 17.1 and I want to install postgresql. Now in trying to update the packages, I type: sudo apt-get update and here are the error messages I get: W: Unable to recover ...
2
votes
1answer
270 views

Why zsh behaves as less when querying a (postgresql) database?

Context zsh shell, oh-my-zsh framework, no special zsh's configuration about postgresql. Trouble I noticed an annoying behavior: when querying the database, e.g.: SELECT * FROM mytable ; it ...
0
votes
1answer
207 views

How to run PostgreSQL as daemontools service?

svscanboot was ran and added to autostart added script from article http://thedjbway.b0llix.net/services/postgresql.html to /service/postgres/run and change mode a+x,root owner Add service: svc -u /...
2
votes
0answers
718 views

Use Letsencrypt certificates for Postgresql [closed]

I have successfully configured Letsencrypt for my NGINX webserver on Debian 8 Jessie. Now I have installed Postgresql 9.4 and want to use the LE certificates (in /etc/letsencrypt/live/mydomain/com/......
1
vote
1answer
2k views

How to Enable pg_stat_statements module in postgresql(9.4)

I have installed postgres database of version 9.4.1 through source code method ( not by rpm installation) so left out the option of installing postgresql-contrib, Now i need to enable the module ...
1
vote
0answers
349 views

How can I import CSV file into a PostgreSQL based on condition

I have CSV file that contains records for all the provinces (chm, mk ...). file.csv: time,language,province,longitude,latitude number en chm number number number en mk number number ...
3
votes
2answers
7k views

sudo yum install postgresql doesn't work on CentOS 7?

I'm trying to install PostgreSQL on CentOS 7 (by following this guide to install Discourse) but when I give this command: sudo yum install postgresql91-server.x86_64 postgresql91-contrib.x86_64 ...
3
votes
1answer
2k views

Encrypt postgresql database

I am reading the postgresql database documentation, but I can't found nothing about encrypting the database files to prevent someone to see the data without the database password. There is some way to ...
0
votes
1answer
50 views

migrate running on Virtual Box PostgreSql instance to another machine

I have a PostgreSql instance that Run on Virtual Box at the Physical Machine A This instance is collecting real-time data, so any downtime is undesirable. I want to move this instance to the ...
2
votes
1answer
7k views

How to change the path of shared libraries shown by ldd?

I am trying to make the postgis extension work on my system and it always spits out "$libdir/postgis2.2" no such file or directory error. For my curiosity I executed "ldd postgis-2.2.so" and it spits ...
0
votes
2answers
594 views

How to use sqlformat tool with pgAdmin

I am trying to add external SQL formatting utility to pgAdmin. There is an option available in pgAdmin3 in Preferences -> Query tool -> Query editor called external formatting utility I set up ...
1
vote
2answers
478 views

How to log PostgreSQL table data changes into syslog?

I have a program which uses these tables, and I want to add some additional functionality to its logging without modifying the program. groups ------ id bigint not null name character varying(100) ...
0
votes
1answer
526 views

Clean up conflicting postgresql installations

I have a little development box which I upgraded to Debian 8.5 (to have a current apache and postgres which better match the productive servers). Now I have both Postgres 9.1 (old) and 9.4 (which I'd ...
5
votes
3answers
22k views

Unable to start posgtresql, the reason isn't clear

I've installed postgresql by pacman. Now I'm trying to run it: $ sudo systemctl start postgresql Job for postgresql.service failed because the control process exited with error code. See "...
0
votes
1answer
588 views

Is there any way to Install postgres from Binary in linux machine irrespective of Linux build(Debian/CentOS/others)

I am trying to install postgres on different machine using ansible. Currently I am using postgres source to install on a partical location. Its taking too much time. Is their a way to run postgres by ...
1
vote
0answers
53 views

Not able to install postgresql in Ubuntu 14.04

I tried many times installing postgresql in Ubuntu 14.04 without success. I keep getting the following error: Can't exec "/tmp/postgresql-common.config.WJ3dGb": Permission denied at /usr/share/...
1
vote
1answer
738 views

postgresql auth against samba active directory

I've recently set up a new Samba4 Active Directory to handle centralized authentication for my small office network. On this server is also a postgresql-9.5 instance, and I'm trying to have it ...
0
votes
1answer
251 views

What's the fastest way to install Postgresql on Wind River 7.0?

I'm new to bare-bones Linux systems and need to install postgres on a wind river Linux distribution. My plan was to install yum and then use yum to install the postgres rpm. I've tried to install ...
0
votes
1answer
21 views

1 VM host 2 PostgreSQL Databases

I'm very new to postsql. Here is my situation. There is an existing postsql running on my VM on port 1234 pointing to a database name : db1. Now, I want to add db2, will I need re-configure another ...
0
votes
1answer
705 views

Failed to start PostgreSQL 9.5 with systemctl - SELinux

I've installed PG 9.5 (/usr/pgsql-9.5/) and when I start it manually with postgres -D it has no problems, but if I try to use systemctl I get an error. By looking to journalctl -xen output, I see: /...
0
votes
0answers
144 views

Debian 8 crashes once every few days

I'm running Debian 8 on Linode 32 GB and once every few days the system crashes. This server is being used in productions and I need to find a solution ASAP The only server running on Debian is ...
2
votes
1answer
5k views

backup file locally in shell script

This is my crontab: crontab -e 30 5 * * * sh /home/donato/Documents/pg_bak.sh Every day at 5:30am I want to execute a shell script I created called pg_bak.sh. This is the contents of the shell ...
1
vote
2answers
3k views

Delete rows from postgres database contain string/sentence [closed]

I would like to know how to delete entire rows in a postgres table that contain a particular string in the title column. So if the string is: it is a sunny day How can I issue a command in postgres ...
6
votes
4answers
36k views

“psql: could not connect to server: No such file or directory”

Actually, I installed PostgreSQL 9.4 (with postGIS extension), and when installed, everything used to work fine. As said on many tuts, I've set the /data folder, checked configuration files, and so ...
0
votes
1answer
2k views

Using regexp_replace to replace single quotes around string but not within words e.g. can't

I'm using the below code from a bash script to replace single quotes from my title column in a postgres database with spaces. psql -U postgres -d my_database -c "UPDATE my_table SET title = ...
0
votes
1answer
914 views

Install PostgreSQL 9.5 CentOS 7

I'm trying to install PostgreSQL 9.5 on CentOS 7. I've searched online and to get access to the 9.5 RPMs it requires installation of pgdg95 via the following command: sudo rpm -ivh http://yum....
0
votes
1answer
2k views

syntax error: unterminated quoted string when using regexp_replace in bash script

I've added some code to the end of a bash script I am using. The code shown here is intended to copy a csv into my postgres table, and then remove brackets, quotes and double quotes from the title ...
1
vote
1answer
631 views

How can I install PostgreSQL and PostGIS on Ubuntu 14.04 and enable remote access over the internet?

I would like to install PostgreSQL and PostGIS on my Ubuntu 14.04 virtual private server that is hosted in a remote datacenter. How can I enable remote access on them?
2
votes
1answer
522 views

Ways to restrict remote user to only access a remote database

I want to be able to setup a remote user that can update a PostgreSQL database on a production server. I have two machines, one is a local server that I use as a command and control system, named ...
3
votes
1answer
2k views

Copy csv data while simultaneously filling serial column

I've created my first postgres table and i'm trying to work out how to copy a .csv file into the table, whilst simultaneously generating a serial number number in column 1 (ID) which starts at number ...
2
votes
1answer
878 views

Chroot Postgresql Error

Currently I'm trying to create the first PostgreSQL 9.5 cluster on Linux deploy android 5.0.2, and it seems to be a shared memory error. FATAL: could not create shared memory segment: Function not ...
1
vote
1answer
2k views

SSH access asking for password in local network but public

I have a problem when ssh to another server. I created ssh-key and copied it to other server. -bash-4.2$ whoami postgres -bash-4.2$ ssh-keygen Generating public/private rsa key pair. Enter file in ...
1
vote
1answer
78 views

Postgresql error after upgrading database

We recently upgraded POSTGRESQL to 9.4.4 and now when my application tries to run a query I am getting this error. LOGS: 2016-03-15 16:34:51 ERROR http-nio-8282-exec-2:FeedRestController:224 - org....
5
votes
2answers
43k views

How do you stop posgresql on centos 7?

How does one stop a Postgresql instance, 9.2, on CentOS 7. I found nothing under /etc/init.d/ nor a ctl program.
1
vote
1answer
1k views

How to debug an Out of memory crash

Recently one of my CentOS6 server crashed because of an Out of memory Error: It seems to be related to the postgres database used by java web-applications (deployed on tomcat). But I cannot find ...
0
votes
1answer
101 views

Issue with dropping table which contains special char in tablename. (Linux&Postgres)

I am facing issue with DROP table command in Linux (backend : Postgres). I have a table named "prabhu2016-02-08--2016-02-15". when I drop this table using below commend i am receiving error.... ERROR:...
0
votes
1answer
545 views

failure at starting on postgresql

I installed a postgresql database on Redhat 7.1 and I decided to move the database on a ISCSI device (LUN) inside a logical volume, mounted at starting of the machine (xfs formatted). The mounting ...
2
votes
1answer
264 views

Mount a large squashfs in a way that allows random writes (to a separate filesystem)?

I just received a few-dozen-gigabyte squashfs that contains a PostgreSQL database. In order to be able to conveniently query it, I need to have a write access, which makes it complicated. Is there a ...
2
votes
0answers
70 views

What is the equivalent to this apt-get when installing PostgreSQL extension for acoustid?

On bitbucket, it says to install the extension using sudo apt-get install postgresql-9.X-acoustid. but I'm running on CentOS... when I replace apt-get with yum: $ sudo apt-get install postgresql-9.X-...
1
vote
0answers
419 views

Installing Ubuntu and PostgreSQL database on different drives

I just received a new root server (this one) with the following drives: Disk /dev/sda: 480 Gb Disk /dev/sdb: 480 Gb Disk /dev/sdc: 240 Gb Plus the 240Gb SSD. Both sda and sdb are set up on RAID-1 ...
4
votes
2answers
4k views

how to split long psql command in bash script over several lines

I have a long psql command to execute within a bash shell script, and I am wondering what the correct way is to split it across several lines? The standard Unix script 'split line' backslash ...
1
vote
1answer
3k views

AWS linux - How could I install postgreSQL on amazon linux?

I want to install postgreSQL on Amazon linux. Please let me know what I should type in regular sequence. I saw some of questions about installing postgreSQL on linux, but there is no example about ...
0
votes
1answer
315 views

How to run command after entering postgres

I am trying to execute ls after opening a new Guake tab and logging into postgres. guake -n guake -e 'sudo -i -u postgres && ls' The command successful opens a new tab then prompts me for my ...
0
votes
1answer
553 views

SUSE Linux Enterprise Server 11 (x86_64) install postgresql93 uninstallable providers

I'm trying to install postresql93 but I have a problem with package dependencies Problem: postgresql93-9.3.5-2.1.14.x86_64 requires systemd, but this requirement cannot be provided uninstallable ...
48
votes
1answer
82k views

Install PostgreSQL client (psql) only on CentOS

Simple question, but no resources found about this. Is there any way to install only a PostgreSQL client, the terminal-based one, psql, on a CentOS7 system, without installing the complete PostgreSQL ...
1
vote
4answers
1k views

Releasing a deleted but open log file

my Debian server disk maxed out because of a large postgresql log file and while I have deleted it, it is still held by postgresql. When I restart postgresql I get an error as the disk is full and the ...
1
vote
1answer
77 views

Basic Hosting Postgresql in Virtualbox + Ubuntu 14.04

I have configured Postgres to accept network connections from anywhere: In pg_hga.conf: host all all 0.0.0.0/0 md5 In postgresql.conf: listen_addresses = '*' ...
1
vote
2answers
6k views

No package pgadmin3 available

I'm running CentOS release 6.7 (Final) I'm trying to install sudo yum install pgadmin3 I keep getting Loaded plugins: fastestmirror, refresh-packagekit, security Setting up Install Process ...
0
votes
0answers
611 views

Cannot telnet to Postgresql Forwarded Port

I'm trying to portforward a PostgreSQL port using my DLINK ADSL Router. I have the following IP addresses. Public Internet IP 197.321.321.32 PostgreSQL 192.123.123.12:5432 (Port To ...