Re: Excessive cpu usage on linux 64bit

From: Yechiel Adar <>
Date: Thu, 26 Jun 2008 11:59:19 +0300
Message-id: <>

Think about it.
For each record:
1) For each fk:

  • calculate the value for the the referencing fk.
  • search the index to see if you do not invalidate the fk by deleting the record. 2) For each index on the table:
  • calculate the index value.
  • get the block that contain that value, may cause 0 or more physical I/O.
  • update the index tree 3) Delete the record from the block.

Multiply this by 4 M records and you get a lot of work.

Check the logical reads and I think you will see a lot of them.

Adar Yechiel
Rechovot, Israel

Giovanni Cuccu wrote:
> What really puzzles me is that I cannot understand where the cpu is
> spent, because it's the cpu usage that slows the entire delete.
> Thanks a lot,
> Giovanni

Received on Thu Jun 26 2008 - 03:59:19 CDT

Original text of this message