This discussion is archived
3 Replies Latest reply: Sep 2, 2013 11:05 PM by algibson RSS

How to activate DATA Monitor(DAMON) service in SQL 2005 Database?

1001854 Explorer
Currently Being Moderated

Hi Expert,

In our database data from tables

BGPLOG,REFRDEL,USESSAUD and USESSION is not getting deleted automatically.
Data is accumulated from long time (Since 2010).
I want to activate DAMON service so that data from these table will get deleted after every month.
I gone through Database administrator document but dosen't understnad completely.
Can anybody help me to do this setting by simplest way?
Its urget, you help is greatly appreciated.
  • 1. Re: How to activate DATA Monitor(DAMON) service in SQL 2005 Database?
    algibson Journeyer
    Currently Being Moderated

    Hi,

     

    To create the jobs you can log into SQL Server Management Studio as the 'sa' user and run the following:

     

    use <database name>

    EXEC initialize_background_procs

     

    It is worth noting that if you are using SQL Server Express that it does not have the SQL Server Agent that will run these (unless you manually installed the Primavera Background Agent or are on P6r8.2/8.3 where it no longer requires SQL Server Agent)

     

    To bring it up-to-date I recommend running the following however many times you need for it to clean up the data until it is current to within the last month.

     

    use <database_name>

    exec data_monitor

     

    You can run multiple so having the below is perfectly fine.

     

    use <database_name>

    exec data_monitor

    exec data_monitor

    exec data_monitor

     

    They usually clean up two weeks worth each so you will probably need to run it ~150 times.

    When you get closer to the end it should only take 10-15seconds for each run, I wouldn't be surprised if the first 50 or more take about 10minutes each.

     

     

    Regards

    Alex

  • 2. Re: How to activate DATA Monitor(DAMON) service in SQL 2005 Database?
    1001854 Explorer
    Currently Being Moderated

    Hi Alex

    Thanks for your reply.

    Once we activate DAMON service , how to set interval so that it will run on regular basis for table BGPLOG_Cleanup, REFRDEL_Cleanup,USESSAUD_Cleanup and USESSION_Cleanup.

  • 3. Re: How to activate DATA Monitor(DAMON) service in SQL 2005 Database?
    algibson Journeyer
    Currently Being Moderated

    Hi,

     

    It should run on a schedule automatically, I believe DAMON runs once a week.

     

    If you do need it to run more often then the below example will change it to run every 30minutes

    UPDATE settings SET setting_value='30m' where namespace = 'database.background.Damon' and setting_name='Interval';


    Regards

    Alex

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points