To keep AMPS running smoothly, 60East recommends developing a maintenance plan, and creating an action configuration to implement the maintenance plan.
AMPS actions provide a way for the server to perform specific tasks in response to specific events. The most common use for actions is to create a maintenance schedule, as described below.
The following table describes maintenance for various features of AMPS. If your installation of AMPS doesn't use a given feature, there is no need to have a maintenance plan for that feature.
60East recommends that you consider the following maintenance actions, and whether they are appropriate for your installation:
For example, the following maintenance plan runs each day, at 23:00 (11 PM local time).
The plan performs the following maintenance:
Archives journal files older than three days
Removes journal files older than 14 days
Truncates statistics to keep the last 7 days of statistics
Removes log files in the $AMPS_ADMIN/logs
directory that are older than 7 days, and
Removes any records in the Orders
topic in the SOW that have a status of canceled
that have not been updated in the last two days.
There are a few important points to notice in the filter used to remove records from the Orders
topic:
Since the timestamps have a unit of seconds, the Filter
describes 48 hours as 172800 seconds (60 seconds in a minute * 60 minutes in an hour * 48 hours).
Since the configuration file is in XML format, the Filter
uses the XML escape for the <
symbol (<
). This is translated into a <
symbol when the configuration file is parsed.
Within an action, AMPS replaces the token {{AMPS_UNIX_TIMESTAMP}}
with the point in time that the action begins running. We can use this to create a Filter
that uses the correct value no matter when the filter is run.