[Pdns-users] Performance issues

James Cloos cloos at jhcloos.com
Thu Sep 13 19:42:45 UTC 2018


I did a quite test vs postgres of that query.

This instance has 40 zones and about 2.25k records.

Explain analyze reports:

QUERY PLAN
Limit  (cost=105.26..105.27 rows=1 width=72) (actual time=0.542..0.542 rows=1 loops=1)
  ->  Sort  (cost=105.26..105.46 rows=78 width=72) (actual time=0.541..0.541 rows=1 loops=1)
        Sort Key: ordername DESC
        Sort Method: top-N heapsort  Memory: 25kB
        ->  Bitmap Heap Scan on records  (cost=22.53..104.87 rows=78 width=72) (actual time=0.119..0.429 rows=208 loops=1)
              Recheck Cond: ((domain_id = 1) AND (ordername IS NOT NULL))
              Filter: ((NOT disabled) AND (ordername <= 'hash'::text))
              Rows Removed by Filter: 199
              Heap Blocks: exact=61
              ->  Bitmap Index Scan on recordorder  (cost=0.00..22.51 rows=223 width=0) (actual time=0.099..0.099 rows=407 loops=1)
                    Index Cond: ((domain_id = 1) AND (ordername IS NOT NULL))
Planning time: 0.194 ms
Execution time: 0.575 ms
(13 rows)
Time: 1.320 ms


So I'd expect pg to be significantly faster for you.

-JimC
-- 
James Cloos <cloos at jhcloos.com>         OpenPGP: 0x997A9F17ED7DAEA6


More information about the Pdns-users mailing list