PostgreSQL is a powerful, open source object-relational database system. It has more than 15 years of active development and a proven architecture that has earned it a strong reputation for reliability, data integrity, and correctness. It runs on all major operating systems, including Linux, UNIX (...

learn more… | top users | synonyms (1)

1
vote
2answers
20 views

How do I include the password for the user 'postgres' in a maintenance script?

I'm setting up a cron job to do some routine maintenance for a postgresql database. The script is as follows: #!/bin/sh dbname="dbname" username="postgres" psql -d $dbname -U $username << EOF ...
0
votes
2answers
13 views

Getting Too many Open files error for Postgres

In Ubuntu 14.04 server on a JAVA application we are getting Too many Open files error for Postgres (Using Postgresql 9.5). We set the following in /etc/security/limits.conf * soft nofile 16384 * ...
0
votes
0answers
17 views

Server migration with the shortest possible downtime [on hold]

If it was the same network and localization I'd simply do: 1. set up new server with nginx, ruby, rails and passenger 2. set up postgres data replication with new server as master 3. a) if load ...
-1
votes
0answers
27 views

Why database performance decrease in different data centers? [on hold]

I'm trying to migrate all our infrastructure to the cloud. In order to do that, we need to ensure that our application performance would, at least, be the same. So we set 2 environment with our ...
0
votes
0answers
6 views

parallize postgres queries with bash and psql?

I'm trying to run a series of postgres functions/stored-procedures that operate on separate tables in parallel using bash + psql as follows: psql -d samples_20160612_0616 -c "select insert_function('...
18
votes
2answers
20k views

How can I do a dump of only the table structure in PostgreSQL?

In a similar vein to this question, how would I do a schema-only dump in PostgreSQL?
1
vote
1answer
3k views

Can't get postgres and kerberos (gss) working together

I am trying to get postgres and kerberos, via GSSAPI, working together. Having trouble at this point. It does not help that I am really a newbie for both technologies. I have both postgres and ...
0
votes
2answers
1k views

Postgres pgpass windows - not working

DB: Postgres 9.0 Client: Windows 7 Server Windows 2008, 64bit I'm trying to connect remotely to a postgres instance for purposes of performing a pg_dump to my local machine. Everything works from my ...
0
votes
2answers
2k views

How to make a JDBC connect to Crystal Reports with Postgres

I want to create a new report using Crystal Reports. I downloaded the Postgres driver but when I want to create the connection, it shows an error "JDBC Driver not found" How can I solve it? Thanks :)...
-3
votes
1answer
22 views

How to insert values into point[] in postgreSQL? [on hold]

How to insert values into array of point[] in postgreSQL ?
1
vote
1answer
9k views

How do I fix issue causing “incomplete startup packet” log message trying to implement replication in Postgresql?

I've got two cloud servers running Ubuntu 13.04 and PostgreSQL 9.2. I've primarily used this blog post to aid me in setting things up. However, to do the initial database dump to the slave I'm using ...
2
votes
1answer
2k views

Postgres's pg_basebackup never finishes creating backup

I'm attempting to move files to another server to setup a slave. I have a database on one Postgres Server and am attempting to create a file-based backup using pg_backup. However, it never finishes ...
0
votes
0answers
12 views

Can I rotate/truncate a single logfile in PostgreSQL 9.4?

I want to setup my test PostgreSQL instance in a VM so that is logs queries to a single file (postgresql.log), which is rotated every hour. Using examples from the docs, I've added the following to ...
7
votes
2answers
11k views

Postgresql Performance - Adjusting SHMMAX and SHMALL

I've read just about everything there is online about improving postgres performance, but the "right" values for SHMMAX and SHMALL still elude me. The consensus seems to be SHMMAX = total_memory/4 ...
0
votes
0answers
6 views

Setup master master for postgres with one is Amazon RDS and another one external?

Is it possible to setup master master for postgres with one is Amazon RDS and another one external? My circumstance is I'm currently using postgres on Amazon RDS but I want to add another server in ...
0
votes
0answers
26 views

Postgres shared buffers tricking Linux into swapping? [duplicate]

Why is my system swapping when I have 45GiB of "cached Mem"? Is Postgres causing problems by using a lot of SHR memory? Here's my situation: 12 cores, 64GiB of RAM on my server running Ubuntu ...
1
vote
1answer
44 views

Postgresql replication with pgpool or pgbouncer

I'm looking for a good configuration for a postgresql replication with a robust failover strategy (self hosted). Actually, I configured two postgresql instances in master / slave with repmgr. Now, I ...
16
votes
5answers
16k views

What's the best way to automate backing-up of PostgreSQL databases?

I find it tedious to have to backup databases every week. And I also think weekly backups should be turned into daily backups. If I had to do that, I don't want to do it manually. What's the best way ...
0
votes
0answers
5 views

Use pg_stat_statements extension on Hot Standby Slave

I've added pg_stat_statements in the postgresql.conf shared_preload_libraries = 'pg_stat_statements' # (change requires restart) and issued a restart afterwards using pg_ctlcluster 9.3 main ...
0
votes
0answers
3 views

Postgresql perl : “NOTICE: elseif should be elsif at line …” [migrated]

It's not the first time I get this strange NOTICE when adding perl functions in Postgresql : NOTICE: elseif should be elsif at line 11. This happens at CREATE FUNCTION as well as when using the ...
0
votes
1answer
2k views

HAProxy pgsql-check error

I use HAProxy 1.5-dev21 to load balance PostgreSQL connections over some read-only Postgresql 9.2 servers. Version 1.5 of HAProxy implements a pgsql-check option, similar to mysql-check. Here is my ...
0
votes
0answers
12 views

Use EC2 instance as proxy to client's VPN

I have a client who has given me access to their database over a VPN. I need my web application to also connect to the same database. My current approach is: Create a new EC2 micro instance (...
0
votes
2answers
1k views

Cannot upgrade PostgreSQL on Ubuntu

When I run apt-get upgrade, I get the following error : dpkg: dependency problems prevent configuration of postgresql-9.1: postgresql-client-9.1 (9.1.7-0ubuntu12.04) breaks postgresql-9.1 (<< ...
0
votes
0answers
26 views

Dovecot/Postfix mail server SASL: Connect to private/auth failed

Trying to get this mail sever up has eaten up a good chunk of 2 days and I've made some headway but this specific error has persisted throughout. I'm using a Debian server with Postfix + Dovecot + ...
0
votes
1answer
64 views

Unable to connect to Postgresql on a server

On Digital Ocean I'm able to connect to Postgresql: psql -d my_db -U my_name for which it asks me a password and I get in successfully. But from my local computer I'm unable: psql -d my_db -U ...
1
vote
1answer
1k views

PostgreSQL master constantly demoted by pacemaker with repmgr

I'm in the process of setting up a PostgreSQL 9.2.8 cluster made of 2 nodes, one master, and one slave. I use streaming replication and repmgr 2.0. My platform is RHEL 6.3. Master and slave can be ...
4
votes
1answer
2k views

Postgresql Provided user name and authenticated user name do not match

I am trying to get tinyRSS running on my own server using PostgreSql. However I keep getting this error: LOG: provided user name (tinyrss) and authenticated user name (apache) do not match FATAL: ...
-1
votes
1answer
2k views

How to set up port forwarding for postgresql listening on localhost?

I have a postgresql instance running on SLES. I want to set it up to listen on localhost, and enable iptables to perform port forwarding. My current configuration postgresql.conf: ...
1
vote
1answer
4k views

Installing PostgreSQL Stack Builder on Windows with a proxy server

I have downloaded and installed PostgreSQL 9.3 (64 bit) on a developer machine running Windows 8.1 (64 bit). This developer machine requires use of a proxy server for accessing hosts external to the ...
0
votes
1answer
38 views

Is it possible to do database replication on aws s3

I have 4TB database in company. As many different analytics require that full data the current database is not able to handle concurrent session from 100s of users. Is it possible to have databse ...
0
votes
2answers
53 views

Why doesn't “psql -U” work for me?

I'm just starting with Postgres. This is a fresh install of Postgres 9.5 on Ubuntu 14.04 LTS. I used the apt repo from: http://www.postgresql.org/download/linux/ubuntu/ The intro page http://www....
1
vote
1answer
1k views

Error in osm data data import while nominatim installation

I am doing nominatim installation on my server. I run the following command ./utils/setup.php --osm-file /usr/share/osm2pgsql/planetfile/planet-latest.osm.pbf --all to import the pbf file and Few ...
0
votes
1answer
27 views

Sharepoint postgresql data connection

We are migrating our intranet to SharePoint and our previous system used postgresql so I'm trying to make it work with SharePoint, which is not easy. I tried to add a data source on SharePoint ...
0
votes
1answer
33 views

Postgres doesn't shut down properly

Here is my original error: $ psql psql: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/tmp/.s.PGSQL.5432"? ...
0
votes
1answer
35 views

Gitlab - Postgresql not working anymore after gitlabctl-reconfigure

I just installed a brand new server with Gitlab. The first time I done gitlab-ctl reconfigure it worked like a charm. After that, I didn't change anything but ran gitlab-ctl reconfigure again. This ...
0
votes
1answer
62 views

AWS RDS Postgres performance issue

We are using rds(postgres) with instance type as db.m4.2xlarge. Usually most of the time number of connections are 8-10. But on some occasion as the number of connections increases to 100-200. DB ...
0
votes
1answer
37 views

Error no 14 while installing PostgreSQL using yum

I am trying to install PostgreSQL on RHEL 6.3 using yum. I am getting a error while installing postgreSQL using yum. Command: yum install postgresql95-server postgresql95 Error: Loaded ...
0
votes
0answers
16 views

Strange Postgres PreparedStatement behaviour (JDBC)

i have a strange problem with the following parameterized PreparedStatement in Java: PreparedStatement ps=DBUtil.newPreparedStatement( "SELECT * FROM msg as m WHERE " + ...
0
votes
3answers
53 views

Verifying the reason why people say it's not a good practice to let an app connect to your db directly

I'm working with postgre (AWS RDS) for my db and using node (AWS EC2) for server side. I'm just starting out so I don't have much context. I always used other third party software like Parse for DB so ...
1
vote
2answers
1k views

installing zlib for postgres on ubuntu

i've installed postgres on ubuntu and am trying to do a pg_dump but get the error message: "pg_dump: [archiver] WARNING: requested compression not available in this installation -- archive will be ...
0
votes
1answer
40 views

Installing postgres on Cent OS

I am having a hard time getting postgres re-installed on Cent OS 7.2.Here is what I tried. Went to YUM repo of postgres Created a temporary folder on my machine for the RPM file Did wget https://...
0
votes
1answer
13 views

Unable to connect to Postgresql via login/password from my web app

On a server I'm able to connect to Postgresql via the terminal: $ psql -U me123 -d my_db psql (9.4.7) Type "help" for help. my_db=# \q Note that it didn't ask me for the password for some reason ...
215
votes
6answers
387k views

What's the default superuser username/password for postgres after a new install?

I have just installed postgres 8.4 on Ubuntu 9.10 and it has never asked me to create a superuser. Is there a default superuser and its password? If not, how do I create a new one?
1
vote
2answers
52 views

postgresql on iscsi that refuses to start … on server's boot - Redhat 7.1

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

Execute postgres function on server from local

I've a postgres database on server. There is an upsert function which takes a file as an input. Is there any way to execute the upsert function from my local without having to scp the file to server ...
0
votes
1answer
22 views

How to share data between web applications?

I got two web applications, one customer facing and one for internal usage. Both are using a PostgreSQL database. What are the approaches I could take to share data between these applications? Both ...