Subject AW: [firebird-support] Re: Bad Performance after Backup-Restore
Author André Dostal
Dear Arno,
here are the results:
orig_db:
RDB$INDEX_NAME RDB$STATISTICS
================================ ==============
RDB$FOREIGN109 0,00233644852414727
RDB$PRIMARY49 3,32189483742695E-6
RDB$FOREIGN122 0,0333333350718021
RDB$PRIMARY31 2,96226080536144E-5
RDB$PRIMARY22 0,00380228133872151

backuped_db:
RDB$INDEX_NAME RDB$STATISTICS
================================ ==============
RDB$FOREIGN109 0
RDB$PRIMARY49 0
RDB$PRIMARY31 0
RDB$PRIMARY22 0
RDB$FOREIGN122 0,333333343267441

thanks / Liebe Grüße aus einem sonnigen Wien
Andre

-----Ursprüngliche Nachricht-----
Von: Arno Brinkman [mailto:firebird@...]
Gesendet: Donnerstag, 06. Mai 2004 13:37
An: firebird-support@yahoogroups.com
Betreff: Re: [firebird-support] Re: Bad Performance after Backup-Restore


Hi,

> I've compared the metadata of the origin and the backuped database,
> and they are eqaul. So I assume that the indices didn't get lost.
>
> Then I've looked on the plans, and they do differ. So I tried to
> provide the plan to the firebird server, and that worked perfekt:
> time on origin db : ~ 4 seconds
> time on backup db : ~ 4 minutes!! (no typo,
> it's real, belive me)
> time on backup*db with plan from origin db : ~ 3 seconds (here again,
> no
> typo)

> restored db:
> PLAN SORT (JOIN (LIN NATURAL,CI INDEX (RDB$PRIMARY22),POSGRP INDEX
> (RDB$PRIMARY49,RDB$FOREIGN122),GRPREL INDEX (RDB$FOREIGN109)))
>
> original db:
> PLAN SORT (JOIN (POSGRP INDEX (RDB$FOREIGN122),LIN INDEX
> (RDB$PRIMARY31),CI INDEX (RDB$PRIMARY22),GRPREL INDEX
> (RDB$FOREIGN109)))


Could you give us the statistics of the indexes (from both db's if
possible):

SELECT
RDB$INDEX_NAME,
RDB$STATISTICS
FROM
RDB$INDICES
WHERE
RDB$INDEX_NAME IN (
'RDB$PRIMARY31','RDB$PRIMARY22',
'RDB$PRIMARY49','RDB$FOREIGN122',
'RDB$FOREIGN109','RDB$FOREIGN122')

Regards,
Arno Brinkman
ABVisie

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features
:
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/

Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com

Nederlandse firebird nieuwsgroep :
news://80.126.130.81





Yahoo! Groups Links