Re: growth of the database - Mailing list pgsql-admin

From Guido Neitzer
Subject Re: growth of the database
Date
Msg-id AA1DDA93-3883-4E39-BDA8-B41FC4134D68@event-s.net
Whole thread Raw
In response to growth of the database  ("Karthikeyan Sundaram" <skarthi98@hotmail.com>)
List pgsql-admin
On 21.03.2007, at 11:25, Karthikeyan Sundaram wrote:

>     Our database is growing fast.  I want to create a cronjob that
> should tell me what is the current size of the database on each day.
>
>    How can I find this from the database? Is there any pre-written
> scripts written by somebody to share?

Be aware of linebreaks ...

[Galadriel: cug ] cug $ psql -U postgres -c "select pg_size_pretty
(pg_database_size('testdb'));"

pg_size_pretty
----------------
495 MB
(1 row)


pgsql-admin by date:

Previous
From: "Karthikeyan Sundaram"
Date:
Subject: growth of the database
Next
From: "Morten W. Petersen"
Date:
Subject: Read-only access to a database