Re: [GENERAL] max_connections reached in postgres 9.3.3

2014-06-20 Thread Erik van Zijst
On Thu, Jun 19, 2014 at 10:10 PM, Erik van Zijst erik.van.zi...@gmail.com wrote: On Thu, Jun 19, 2014 at 3:57 PM, Merlin Moncure mmonc...@gmail.com wrote: In your case user% is dominating system load. Along with the high cs this is really suggesting spinlock contention. A 'perf top' is

[GENERAL] How can I get first day date of the previous month ?

2014-06-20 Thread Arup Rakshit
How can I get first day date of the previous month. Last day of previous month can be found using the answer - http://stackoverflow.com/a/8945281/2767755   Regards, Arup Rakshit

Re: [GENERAL] How can I get first day date of the previous month ?

2014-06-20 Thread Michael Paquier
On Fri, Jun 20, 2014 at 3:42 PM, Arup Rakshit arupraks...@rocketmail.com wrote: How can I get first day date of the previous month. Last day of previous month can be found using the answer - http://stackoverflow.com/a/8945281/2767755 Here is how to get the first day date of the previous month:

Re: [GENERAL] How can I get first day date of the previous month ?

2014-06-20 Thread Arup Rakshit
Thanks for your answer. How to get the first day date of last 6 months from now then will be : yelloday_development=# select date_trunc('month', now()) - interval '5 month' as first_month;         first_month         ---  2014-01-01 00:00:00+05:30 (1 row) Is it correct

[GENERAL] Strange Error in postgresql 8.4

2014-06-20 Thread Dick Kniep
Hi list, We have been using Postgresql for more than a decade now. Never had any real problems. Thank you very much for this great product. Now recently I have noticed a strange problem. Below is a traceback of a python program using psycopg and this correlates with the postgresql log below

Re: [GENERAL] How can I get first day date of the previous month ?

2014-06-20 Thread Alban Hertroys
On 20 June 2014 09:11, Arup Rakshit arupraks...@rocketmail.com wrote: Thanks for your answer. How to get the first day date of last 6 months from now then will be : yelloday_development=# select date_trunc('month', now()) - interval '5 month' as first_month; first_month

Re: [GENERAL] pg_restore: custom archiver unexpected end of file , ERROR: missing data for column

2014-06-20 Thread Khangelani Gama
Now you can edit the dump and attempt to restore it until it succeeds on a different system, after which you know for certain that your data matches at least your integrity constraints. That makes sense to me, thanks Is there is an easier or better way to edit the binary dump file? Like

Re: [GENERAL] PostgreSQL 9.2.4 + CentOS 6.5 64 bit - segfault error in initdb

2014-06-20 Thread Bhushan Pathak
Have not faced any issues with the rhel6 RPMs. Thanks for your time help. Regards Bhushan Pathak On Tue, Jun 10, 2014 at 4:00 PM, Bhushan Pathak bhushan.patha...@gmail.com wrote: I will try the the RPMs from the rhel 6 link post updates. Thanks Bhushan Pathak On Mon, Jun 9, 2014 at

[GENERAL] Postgresql not getting assigned memory

2014-06-20 Thread Oliver
Hello, I'm new in postgresql, I'm sorry if I do something bad. Default value or shared_buffers is 128MB, I have a dedicated server for postgresql with 8GB RAM. I've changed shared_buffers value to 2048MB and uncommented the entry in postgresql.conf. It shows now: # - Memory - shared_buffers =

Re: [GENERAL] Postgresql not getting assigned memory

2014-06-20 Thread Abdul Sayeed
Hi, Can you please check the output of below command: postgres=# show shared_buffers ; Thanks Regards, Abdul Sayeed System Engineer The Postgres Database Company Are you updated: Latest version of Postgres Plus Advanced Server are 8.4.19.42, 9.0.16.34, 9.1.12.20, 9.2.8.19 and 9.3.4.10 To

Re: [GENERAL] Postgresql not getting assigned memory

2014-06-20 Thread Oliver
Thank you very much to all. postgres=# show shared_buffers; shared_buffers 2GB (1 row) Is it ok then, isn't it? DB hasn't activity now because it is a new instance, top command indicates only 350MB of used memory .. I understand that postgresql could reach until 2GB of server

Re: [GENERAL] max_connections reached in postgres 9.3.3

2014-06-20 Thread Merlin Moncure
On Fri, Jun 20, 2014 at 12:58 AM, Erik van Zijst erik.van.zi...@gmail.com wrote: On Thu, Jun 19, 2014 at 10:10 PM, Erik van Zijst erik.van.zi...@gmail.com wrote: On Thu, Jun 19, 2014 at 3:57 PM, Merlin Moncure mmonc...@gmail.com wrote: In your case user% is dominating system load. Along with

Re: [GENERAL] Postgresql not getting assigned memory

2014-06-20 Thread Abdul Sayeed
Hi, It shows 2GB. It means it is updated. Shared_buffer memory is used at postgresql database level, It will consume while doing operation such as INSERT, UPDATE, DELETE and other maintenance task (VACUUM/VACUUM FULL). Thanks, Abdul On Fri, Jun 20, 2014 at 6:28 PM, Oliver ofab...@gmail.com

Re: [GENERAL] Postgresql not getting assigned memory

2014-06-20 Thread Kevin Grittner
Oliver ofab...@gmail.com wrote: DB hasn't activity now because it is a new instance, top command indicates only 350MB of used memory .. I understand that postgresql could reach until 2GB of server memory as total, correct? It's usually much better to copy/paste what you're talking about than

Re: [GENERAL] Strange Error in postgresql 8.4

2014-06-20 Thread Adrian Klaver
On 06/20/2014 01:18 AM, Dick Kniep wrote: Hi list, We have been using Postgresql for more than a decade now. Never had any real problems. Thank you very much for this great product. Now recently I have noticed a strange problem. Below is a traceback of a python program using psycopg and this

Re: [GENERAL] pros/cons of using synchronous commit=off - AWS in particular

2014-06-20 Thread Merlin Moncure
On Thu, Jun 19, 2014 at 9:24 AM, Larry J Prikockis lprikoc...@vecna.com wrote: so from the much-loved https://wiki.postgresql.org/wiki/Tuning_Your_PostgreSQL_Server page, we have this: PostgreSQL can only safely use a write cache if it has a battery backup. See WAL reliability for an

Re: [GENERAL] pros/cons of using synchronous commit=off - AWS in particular

2014-06-20 Thread Larry Prikockis
On 06/20/2014 09:41 AM, Merlin Moncure wrote: On Thu, Jun 19, 2014 at 9:24 AM, Larry J Prikockis lprikoc...@vecna.com wrote: so from the much-loved https://wiki.postgresql.org/wiki/Tuning_Your_PostgreSQL_Server page, we have this: PostgreSQL can only safely use a write cache if it has a

Re: [GENERAL] max_connections reached in postgres 9.3.3

2014-06-20 Thread Tom Lane
Erik van Zijst erik.van.zi...@gmail.com writes: On Thu, Jun 19, 2014 at 3:57 PM, Merlin Moncure mmonc...@gmail.com wrote: In your case user% is dominating system load. Along with the high cs this is really suggesting spinlock contention. A 'perf top' is essential for identifying the culprit.

Re: [GENERAL] pros/cons of using synchronous commit=off - AWS in particular

2014-06-20 Thread Merlin Moncure
On Fri, Jun 20, 2014 at 8:49 AM, Larry Prikockis lprikoc...@vecna.com wrote: On 06/20/2014 09:41 AM, Merlin Moncure wrote: On Thu, Jun 19, 2014 at 9:24 AM, Larry J Prikockis lprikoc...@vecna.com wrote: so from the much-loved https://wiki.postgresql.org/wiki/Tuning_Your_PostgreSQL_Server

Re: [GENERAL] Best backup strategy for production systems

2014-06-20 Thread Marti Raudsepp
On Fri, Jun 20, 2014 at 1:47 AM, Borislav Ivanov biva...@atlassian.com wrote: If your database is relatively small, I would recommend http://www.pgbarman.org/. It does binary backup and will take care of your WAL files. The laster version of pgbarman can also take backups from a slave using

Re: [GENERAL] pros/cons of using synchronous commit=off - AWS in particular

2014-06-20 Thread Alvaro Herrera
Larry Prikockis wrote: ok... so maybe a better question would be: other than cases of power failure or something else that caused the server to shut down unexpectedly and uncleanly, what is the actual risk of data loss? In my case, the possibility of losing a recent transaction or two in the

Re: [GENERAL] How can I get first day date of the previous month ?

2014-06-20 Thread Steve Crawford
On 06/20/2014 12:11 AM, Arup Rakshit wrote: Thanks for your answer. How to get the first day date of last 6 months from now then will be : yelloday_development=# select date_trunc('month', now()) - interval '5 month' as first_month; first_month --- 2014-01-01

Re: [GENERAL] Strange Error in postgresql 8.4

2014-06-20 Thread Steve Crawford
On 06/20/2014 01:18 AM, Dick Kniep wrote: Hi list, ... Now recently I have noticed a strange problem. ... psycopg2.DatabaseError: SSL error: ccs received early Did you try Googling SSL error: ccs received early? Like Adrian, I suspect your answer will be found in one of those messages. What

Re: [GENERAL] Postgresql not getting assigned memory

2014-06-20 Thread Jeff Janes
On Fri, Jun 20, 2014 at 4:51 AM, Oliver ofab...@gmail.com wrote: Hello, I'm new in postgresql, I'm sorry if I do something bad. Default value or shared_buffers is 128MB, I have a dedicated server for postgresql with 8GB RAM. I've changed shared_buffers value to 2048MB and uncommented the

[GENERAL] pgAgent

2014-06-20 Thread enrique.perez
how can i install pgAgent in postgresql 8.4 if mi internet conection don't allow to any program to conect internet. -- View this message in context: http://postgresql.1045698.n5.nabble.com/pgAgent-tp5808135.html Sent from the PostgreSQL - general mailing list archive at Nabble.com. -- Sent

Re: [GENERAL] How to store fixed size images?

2014-06-20 Thread Jonathan Vanasco
On Jun 19, 2014, at 11:21 AM, Andy Colson wrote: I think it depends on how you are going to use them. I, for example, have lots of images that are served on a web page, after benchmarks I found it was faster to store them on filesystem and let apache serve them directly. I rarely store

Re: [GENERAL] How can I get first day date of the previous month ?

2014-06-20 Thread Gavin Flower
On 21/06/14 03:12, Steve Crawford wrote: On 06/20/2014 12:11 AM, Arup Rakshit wrote: Thanks for your answer. How to get the first day date of last 6 months from now then will be : yelloday_development=# select date_trunc('month', now()) - interval '5 month' as first_month; first_month

Re: [GENERAL] How can I get first day date of the previous month?

2014-06-20 Thread Arup Rakshit
On Friday, June 20, 2014 08:12:14 AM you wrote: Welcome. And yes, it is awesome. I agree. Being new to the DB No. I worked on Oracle DB earlier days(approx 2 years). But pgsql just 1 month. and mailing list, please note that the convention on all PostgreSQL mailing lists is to post your