Results 1 to 5 of 5
  1. #1
    Join Date
    May 2015
    Posts
    4

    Unanswered: DB2 running out of space

    Hi,

    I had an issue this morning with my DB2 server running out of space. I was not able to find the root cause but the issue was with a trigger on a table. The trigger was created AFTER UPDATE on TABLE X. It checks the new value and performs some logic. If the logic satisfies, inserts a new row to table Y.

    Problem here was the new table Y might already have the same row inserted. If present, the TRIGGER will throw an error due to primary key constraint. So trigger failed. But why would it create the transaction logs every minute and run out of space? After dropping the trigger, the logging stopped. Any help in this is greatly appreciated.

    Thanks
    Anis GovindaRao
    Last edited by anisrao87; 05-21-15 at 21:16.

  2. #2
    Join Date
    Nov 2011
    Posts
    334
    Hi, Anis
    Which space are you running out ? active log space or container space?
    I think db2 will log all operations no matter they success or failure。 if a violation of primary key constraint happens , there will be a internal rollback and this will be logged too。
    So if you are running out of log space ,maybe you can first check whether the same row already exists before insert .

  3. #3
    Join Date
    May 2015
    Posts
    4
    Hi,

    I am running out of the active transaction logs. They are written to F drive and they filled up 200GB of data within two days.

    Thanks
    Anis Rao

  4. #4
    Join Date
    May 2010
    Location
    India
    Posts
    84
    Provided Answers: 2
    The problem seems to be related to application logic. Check whether your application is trying to update failed record again and again. Add logic to avoid this situation.

  5. #5
    Join Date
    Apr 2008
    Location
    Iasi, Romania
    Posts
    561
    Provided Answers: 2
    You also have some configuration problems. Maybe you should look at logprimary and logsecond DB configuration parameters. I think you have set -1 for logsecond, that is you have infinite active log space.
    Florin Aparaschivei
    DB2 9.7, 10.5 on Windows
    Iasi, Romania

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •