Re: [GENERAL] Search connections created per day

2008-01-16 Thread João Paulo Zavanela
>> Hi there,
>>
>> I want to know how many connections is created simultaneously in data
base
>> per day.
>
>Do you want to know the max simo connections at any given time, or the
>total connections in a given day?  Assuming you want to know the max
>simo connections at any given time, I think you're going to have to
>check pg_stat_activity every x minutes and store the number of rows
>somewhere to retrieve later.
>
>> Are there some table where i can search it?
>
>pg_stat_activity, but it only has the info for "right now" in it.

Thanks...

I want to know the max simo connections at any given time, but I only have
a backup of the database, so, I don't can use the pg_stat_activity.

This database is running in a client, and I should to know if he is creating
more connections of it is allowed.

Thanks.



---(end of broadcast)---
TIP 3: Have you checked our extensive FAQ?

   http://www.postgresql.org/docs/faq


Re: [GENERAL] Search connections created per day

2008-01-11 Thread Erik Jones


On Jan 11, 2008, at 11:51 AM, Joshua D. Drake wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Fri, 11 Jan 2008 14:29:32 -0300
João Paulo Zavanela <[EMAIL PROTECTED]> wrote:


Hi there,

I want to know how many connections is created simultaneously in data
base per day.


Entirely depends on your machine. I wouldn't suggest having more  
than a

1000 open at any given time though. Also take a look at connection
pooling.


Are there some table where i can search it?


pg_stat_activity


All users is connected in the database with postgres user.


I think he was looking for some kind of logging/reporting of how many  
connections have actually been made for a given day.  He should be  
looking at turning on log_connections and then parsing his logs for  
connection entries.


Erik Jones

DBA | Emma®
[EMAIL PROTECTED]
800.595.4401 or 615.292.5888
615.292.0777 (fax)

Emma helps organizations everywhere communicate & market in style.
Visit us online at http://www.myemma.com




---(end of broadcast)---
TIP 4: Have you searched our list archives?

  http://archives.postgresql.org/


Re: [GENERAL] Search connections created per day

2008-01-11 Thread Scott Marlowe
On Jan 11, 2008 11:29 AM, João Paulo Zavanela <[EMAIL PROTECTED]> wrote:
> Hi there,
>
> I want to know how many connections is created simultaneously in data base
> per day.

Do you want to know the max simo connections at any given time, or the
total connections in a given day?  Assuming you want to know the max
simo connections at any given time, I think you're going to have to
check pg_stat_activity every x minutes and store the number of rows
somewhere to retrieve later.

> Are there some table where i can search it?

pg_stat_activity, but it only has the info for "right now" in it.

---(end of broadcast)---
TIP 9: In versions below 8.0, the planner will ignore your desire to
   choose an index scan if your joining column's datatypes do not
   match


Re: [GENERAL] Search connections created per day

2008-01-11 Thread Joshua D. Drake
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Fri, 11 Jan 2008 14:29:32 -0300
João Paulo Zavanela <[EMAIL PROTECTED]> wrote:

> Hi there,
> 
> I want to know how many connections is created simultaneously in data
> base per day.

Entirely depends on your machine. I wouldn't suggest having more than a
1000 open at any given time though. Also take a look at connection
pooling.

> Are there some table where i can search it?

pg_stat_activity

> All users is connected in the database with postgres user.
> 

Sincerely,

Joshua D. Drake


> Thanks.
> João Paulo Zavanela
> 
> 
> 
> 
> ---(end of
> broadcast)--- TIP 9: In versions below 8.0,
> the planner will ignore your desire to choose an index scan if your
> joining column's datatypes do not match
> 


- -- 
The PostgreSQL Company: Since 1997, http://www.commandprompt.com/ 
Sales/Support: +1.503.667.4564   24x7/Emergency: +1.800.492.2240
Donate to the PostgreSQL Project: http://www.postgresql.org/about/donate
SELECT 'Training', 'Consulting' FROM vendor WHERE name = 'CMD'


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHh6yOATb/zqfZUUQRAuqCAKCFHs1tp6Zar+2FIEhipJaSWskEowCbBp9y
TmFyoOPqqYajvLQqy36EB0k=
=v8pM
-END PGP SIGNATURE-

---(end of broadcast)---
TIP 2: Don't 'kill -9' the postmaster


[GENERAL] Search connections created per day

2008-01-11 Thread João Paulo Zavanela
Hi there,

I want to know how many connections is created simultaneously in data base
per day.
Are there some table where i can search it?
All users is connected in the database with postgres user.

Thanks.
João Paulo Zavanela




---(end of broadcast)---
TIP 9: In versions below 8.0, the planner will ignore your desire to
   choose an index scan if your joining column's datatypes do not
   match