Re: PostgreSQL 9.6 Temporary files

2018-03-20 Thread Jimmy Augustine
2018-03-20 15:00 GMT+01:00 Adrian Klaver : > On 03/20/2018 03:16 AM, Jimmy Augustine wrote: > >> Thanks all for your response, >> >> $du -h $MY_DATA/base/$BASE_OID/ returns 162GB but when I execute this >> query: >> >> |SELECT stats.relname AS table, >> pg_size_pretty(pg_relation_size(statsio.rel

Re: PostgreSQL 9.6 Temporary files

2018-03-20 Thread Adrian Klaver
On 03/20/2018 03:16 AM, Jimmy Augustine wrote: Thanks all for your response, $du -h $MY_DATA/base/$BASE_OID/ returns 162GB but when I execute this query: |SELECT stats.relname AS table, pg_size_pretty(pg_relation_size(statsio.relid)) AS table_size, pg_size_pretty(pg_total_relation_size(statsi

Re: PostgreSQL 9.6 Temporary files

2018-03-20 Thread Jimmy Augustine
Thanks all for your response, $du -h $MY_DATA/base/$BASE_OID/ returns 162GB but when I execute this query: SELECT stats.relname AS table, pg_size_pretty(pg_relation_size(statsio.relid)) AS table_size, pg_size_pretty(pg_total_relation_size(statsio.relid)

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Adrian Klaver
On 03/19/2018 10:27 AM, Jimmy Augustine wrote: I tried this query and my database size is equal to 162GB. Well you can always look in $DATA directly. The database will be under $DATA/base/. You can find the like this: select oid, datname from pg_database where datname=''; -- Adrian Kla

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Adrian Klaver
On 03/19/2018 10:29 AM, Jimmy Augustine wrote: That's aggregated. Not current values. Ah did you know some documentation about that ? https://www.postgresql.org/docs/10/static/monitoring-stats.html#PG-STAT-DATABASE-VIEW Andreas -- 2ndQuadrant - The PostgreSQL Suppor

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
2018-03-19 18:25 GMT+01:00 Andreas Kretschmer : > On 19 March 2018 18:21:42 CET, Jimmy Augustine > wrote: > >2018-03-19 18:15 GMT+01:00 Adrian Klaver : > > > >> On 03/19/2018 10:12 AM, Jimmy Augustine wrote: > >> > >> > >>> On 03/19/2018 09:31 AM, Jimmy Augustine wrote: > >>> > >>>

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
I tried this query and my database size is equal to 162GB. 2018-03-19 18:17 GMT+01:00 Melvin Davidson : > > > On Mon, Mar 19, 2018 at 1:12 PM, Jimmy Augustine > wrote: > >> >> >> 2018-03-19 18:09 GMT+01:00 Adrian Klaver : >> >>> On 03/19/2018 10:04 AM, Jimmy Augustine wrote: >>> 2

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Adrian Klaver
On 03/19/2018 10:17 AM, Melvin Davidson wrote: * *I think your problem is that SELECT pg_size_pretty(pg_total_relation_size('table_name')); only looks at the current database * *but SELECT pg_size_pretty(pg_database_size('Database Name')); looks at ALL databases. Not according to he

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Andreas Kretschmer
On 19 March 2018 18:21:42 CET, Jimmy Augustine wrote: >2018-03-19 18:15 GMT+01:00 Adrian Klaver : > >> On 03/19/2018 10:12 AM, Jimmy Augustine wrote: >> >> >>> On 03/19/2018 09:31 AM, Jimmy Augustine wrote: >>> >>> Dear Friends, >>> >>> I am newbie to

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
2018-03-19 18:15 GMT+01:00 Adrian Klaver : > On 03/19/2018 10:12 AM, Jimmy Augustine wrote: > > >> On 03/19/2018 09:31 AM, Jimmy Augustine wrote: >> >> Dear Friends, >> >> I am newbie to postgresql. >> I have 162 GB on my database but

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Melvin Davidson
On Mon, Mar 19, 2018 at 1:17 PM, Jimmy Augustine wrote: > Hi, > > I used this command and I found the same value in total_size column. > > 2018-03-19 18:01 GMT+01:00 Melvin Davidson : > >> >> >> On Mon, Mar 19, 2018 at 12:45 PM, Adrian Klaver < >> adrian.kla...@aklaver.com> wrote: >> >>> On 03/19

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Melvin Davidson
On Mon, Mar 19, 2018 at 1:12 PM, Jimmy Augustine wrote: > > > 2018-03-19 18:09 GMT+01:00 Adrian Klaver : > >> On 03/19/2018 10:04 AM, Jimmy Augustine wrote: >> >>> >>> >>> 2018-03-19 17:45 GMT+01:00 Adrian Klaver >> >: >>> >>> On 03/19/2018 09:31 AM, Jimmy Au

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
Hi, I used this command and I found the same value in total_size column. 2018-03-19 18:01 GMT+01:00 Melvin Davidson : > > > On Mon, Mar 19, 2018 at 12:45 PM, Adrian Klaver > wrote: > >> On 03/19/2018 09:31 AM, Jimmy Augustine wrote: >> >>> Dear Friends, >>> >>> I am newbie to postgresql. >>> I

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Adrian Klaver
On 03/19/2018 10:12 AM, Jimmy Augustine wrote:     On 03/19/2018 09:31 AM, Jimmy Augustine wrote:         Dear Friends,         I am newbie to postgresql.         I have 162 GB on my database but when I check size of all         tables, I approxima

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
2018-03-19 18:09 GMT+01:00 Adrian Klaver : > On 03/19/2018 10:04 AM, Jimmy Augustine wrote: > >> >> >> 2018-03-19 17:45 GMT+01:00 Adrian Klaver > >: >> >> On 03/19/2018 09:31 AM, Jimmy Augustine wrote: >> >> Dear Friends, >> >> I am newbie to p

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Adrian Klaver
On 03/19/2018 10:04 AM, Jimmy Augustine wrote: 2018-03-19 17:45 GMT+01:00 Adrian Klaver >: On 03/19/2018 09:31 AM, Jimmy Augustine wrote: Dear Friends, I am newbie to postgresql. I have 162 GB on my database but when I check size

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
2018-03-19 17:45 GMT+01:00 Adrian Klaver : > On 03/19/2018 09:31 AM, Jimmy Augustine wrote: > >> Dear Friends, >> >> I am newbie to postgresql. >> I have 162 GB on my database but when I check size of all tables, I >> approximately obtain 80 GB. >> I also see that I have 68GB of temporary files ho

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Melvin Davidson
On Mon, Mar 19, 2018 at 12:45 PM, Adrian Klaver wrote: > On 03/19/2018 09:31 AM, Jimmy Augustine wrote: > >> Dear Friends, >> >> I am newbie to postgresql. >> I have 162 GB on my database but when I check size of all tables, I >> approximately obtain 80 GB. >> I also see that I have 68GB of tempo

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
Hi Andreas thanks for your response, 2018-03-19 17:44 GMT+01:00 Andreas Kretschmer : > On 19 March 2018 17:31:20 CET, Jimmy Augustine > wrote: > >Dear Friends, > > > >I am newbie to postgresql. > >I have 162 GB on my database but when I check size of all tables, I > >approximately obtain 80 GB.

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Adrian Klaver
On 03/19/2018 09:31 AM, Jimmy Augustine wrote: Dear Friends, I am newbie to postgresql. I have 162 GB on my database but when I check size of all tables, I approximately obtain 80 GB. I also see that I have 68GB of temporary files however I only found 2.4MB at postgres/data/base/pgsql_tmp. E

Re: PostgreSQL 9.6 Temporary files

2018-03-19 Thread Andreas Kretschmer
On 19 March 2018 17:31:20 CET, Jimmy Augustine wrote: >Dear Friends, > >I am newbie to postgresql. >I have 162 GB on my database but when I check size of all tables, I >approximately obtain 80 GB. Indexes? >I also see that I have 68GB of temporary files however I only found Where can you see

PostgreSQL 9.6 Temporary files

2018-03-19 Thread Jimmy Augustine
Dear Friends, I am newbie to postgresql. I have 162 GB on my database but when I check size of all tables, I approximately obtain 80 GB. I also see that I have 68GB of temporary files however I only found 2.4MB at postgres/data/base/pgsql_tmp. Could you tell me what are those temporary files and