Subject | RE: [firebird-support] Re: Performance when deleting a lot of records, again |
---|---|
Author | Gili Buzaglo |
Post date | 2005-04-17T09:07:46Z |
Hi
I've perfomed gstat -h on every write to the database, to see when next transaction number becomes
a lot larger the oldest snapshot number.
I've noticed that when ever it occured the following select was performed for the first time:
select DISTINCT v.vol_id,sd.dev_id,pa.cc_id,ba.branch_id,sd.allocation,s.allocation,ba.allocation,pa.allocation,da.allocation,s.stt_id,da.disk_id,cm.client_id from stt_allocation s LEFT JOIN volume v on s.stt_id = v.stt_id and v.vol_id = ?
Left JOIN client_map cm on cm.vol_id = v.vol_id
Left join stt_comp sc on s.stt_id = sc.stt_id
Left join Storage_device sd on sc.dev_id = sd.dev_id
LEFT JOIN device_owner do1 on sd.dev_id = do1.dev_id Left join branch_visibility bv on do1.branch_id = bv.branch_id and bv.is_owner=1
Left join pool_allocation pa on pa.cc_id = bv.cc_id
Left join branch_allocation ba on ba.branch_id = do1.branch_id
Left join DISK_ARRAY_STORAGE das on das.dev_id = do1.dev_id
Left join disk_allocation da on da.disk_id = das.disk_array_id
WHERE v.vol_id is not null;
All *_allocation are views , the rest are tables.
Can you see any problem with this query ?
-gili
-----Original Message-----
From: Ann W. Harrison [mailto:aharrison@...]
Sent: Thursday, April 07, 2005 7:52 PM
To: firebird-support@yahoogroups.com
Subject: Re: [firebird-support] Re: Performance when deleting a lot of records, again
Gili Buzaglo wrote:
transaction when you use it to query the database. That transaction
stays open until explicitly closed.
Try closing all connections to the database, then run gstat -h and send
us the results.
Regards,
Ann
_____
Yahoo! Groups Links
* To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/
* To unsubscribe from this group, send an email to:
firebird-support-unsubscribe@yahoogroups.com <mailto:firebird-support-unsubscribe@yahoogroups.com?subject=Unsubscribe>
* Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service <http://docs.yahoo.com/info/terms/> .
[Non-text portions of this message have been removed]
I've perfomed gstat -h on every write to the database, to see when next transaction number becomes
a lot larger the oldest snapshot number.
I've noticed that when ever it occured the following select was performed for the first time:
select DISTINCT v.vol_id,sd.dev_id,pa.cc_id,ba.branch_id,sd.allocation,s.allocation,ba.allocation,pa.allocation,da.allocation,s.stt_id,da.disk_id,cm.client_id from stt_allocation s LEFT JOIN volume v on s.stt_id = v.stt_id and v.vol_id = ?
Left JOIN client_map cm on cm.vol_id = v.vol_id
Left join stt_comp sc on s.stt_id = sc.stt_id
Left join Storage_device sd on sc.dev_id = sd.dev_id
LEFT JOIN device_owner do1 on sd.dev_id = do1.dev_id Left join branch_visibility bv on do1.branch_id = bv.branch_id and bv.is_owner=1
Left join pool_allocation pa on pa.cc_id = bv.cc_id
Left join branch_allocation ba on ba.branch_id = do1.branch_id
Left join DISK_ARRAY_STORAGE das on das.dev_id = do1.dev_id
Left join disk_allocation da on da.disk_id = das.disk_array_id
WHERE v.vol_id is not null;
All *_allocation are views , the rest are tables.
Can you see any problem with this query ?
-gili
-----Original Message-----
From: Ann W. Harrison [mailto:aharrison@...]
Sent: Thursday, April 07, 2005 7:52 PM
To: firebird-support@yahoogroups.com
Subject: Re: [firebird-support] Re: Performance when deleting a lot of records, again
Gili Buzaglo wrote:
> What is a culprit ?The culprit is the guilty person. IBConsole starts a snapshot
> Anywhay, even if I close the ibconsole, there is still a gap!
transaction when you use it to query the database. That transaction
stays open until explicitly closed.
Try closing all connections to the database, then run gstat -h and send
us the results.
Regards,
Ann
_____
Yahoo! Groups Links
* To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/
* To unsubscribe from this group, send an email to:
firebird-support-unsubscribe@yahoogroups.com <mailto:firebird-support-unsubscribe@yahoogroups.com?subject=Unsubscribe>
* Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service <http://docs.yahoo.com/info/terms/> .
[Non-text portions of this message have been removed]