From: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
---|---|
To: | wambacher(at)posteo(dot)de, pgsql-admin(at)lists(dot)postgresql(dot)org |
Subject: | Re: finding queries doing sequential search |
Date: | 2018-12-15 13:55:07 |
Message-ID: | a63c0b4ae8eae198ad9554b020d89f458225c600.camel@cybertec.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
wambacher(at)posteo(dot)de wrote:
> i have a very big table (PostGIS OpenStreetMap data, but that does not mapper)
> with about 380 million records and a size of 275 GB + Indices.
> Permanently updated and growing.
> Of course i enabled autovacuum.
> The log shows me 8.2 Mio index scans (iscan), which is fine, and right now
> 424 sequential scans (sscan) for planet_osm_polygon. see attached image.
> I want to locate the query doing this stuff but EXPLAIN won't help because
> most querys are dynamicly created.
> Is there a way/trick do this?
With a big table it shouldn't be a problem.
Set log_min_duration_statement = 10000 or similar, and all long running
statements will be logged. The sequential scans should be among them.
Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com
From | Date | Subject | |
---|---|---|---|
Next Message | Gustav Karlsson | 2018-12-17 11:41:10 | [ADMIN] Is it safe to run pg_stat_reset() i Prod? |
Previous Message | Jehan-Guillaume (ioguix) de Rorthais | 2018-12-15 07:56:25 | Re: PG how to stop streaming replication( master host) |