Previous Topic: Define the Archive and Purge PathNext Topic: Archive and Purge Rule Fields


Create an Archive and Purge Rule

Before you can perform an archive or purge, you create a rule. The rule defines what you want to archive and when.

Example: You create an archive and purge rule to remove deleted forums from the database.

Follow these steps:

  1. Select Archive and Purge, Archive and Purge Rules on the Administration tab.

    The Archive and Purge Rule List page opens.

  2. Click Create New.

    The Create New Archive and Purge Rule page opens.

  3. Complete the archive and purge rule fields, as appropriate.
  4. Click Save.

    The new rule is displayed on the Archive and Purge Rule List page.

Example: You create an optional configuration rule inside the arcpur_cfg.xml and itil_arcpur_cfg.xml files to archive and purge the KPI_Ticket_Data node.

Follow these steps:

  1. Log in to the following server, depending on your CA SDM configuration:
  2. Find the following files in the $NX_ROOT/site/cfg/ directory:
  3. Edit the files to define the end_time (last_mod_dt) in KPI_Ticket_Data node. It specifies the criteria to select the records for archive and purge.
  4. Link the records in the KPI_Ticket_Data table to the records in the Ticket table (such as cr, chg, or iss). This ensures that all ticket related records in the KPI_Ticket_Data table are archived and purged.
  5. KPI_Ticket_Data node does not have a SREL relationship with any Ticket node and it relies on two fields, obj_name, and obj_id, to link with a ticket. The obj_name value can be cr, chg, or iss and the obj_id value is the ticket id. Define a main_obj for each ticket object.

    The following is a sample main_object definition for the ticket object, cr:

    <!-- KPI Ticket Data -->
    
    <main_obj>
    
    <name>KPI Ticket Data</name>
    
    <internal_name>KPI Ticket Data</internal_name>
    
    <factory>ktd</factory>
    
    <default_query>obj_name='cr'</default_query>
    
    <date_field>end_time</date_field>
    
    <ref_by value="obj_id">cr.id</ref_by>
    
    </main_obj> 
    

    Note: The configuration rule can only select records for cr. The ref_by tag can match the value of obj_id in KPI Ticket Data to the value of id in cr. If a match is found, it means that a KPI Ticket Data record is referenced by a cr record, so the KPI Ticket Data record is not archived and purged.

  6. After adding the configuration rules for all ticket objects, depending on your CA SDM configuration, do one of the following:

    These configuration rules become selectable configuration object names in the Archive and Purge Rule Detail form.