Professional Documents
Culture Documents
Archive Reference
www.schneider-electric.com
Legal Information
The Schneider Electric brand is the sole property of Schneider Electric Industries SAS. Any
trademarks of Telvent Canada Ltd. or Telvent USA, LLC referred to in this guide are the sole
property of Telvent Canada Ltd. or Telvent USA, LLC. The Schneider Electric brand and
trademarks may not be used for any purpose without the owner's permission, given in writing. This
guide and its content are protected, within the meaning of the applicable copyright and trademark
laws and international conventions. Unless otherwise agreed in writing, you may not reproduce all
or part of this guide on any medium whatsoever without the permission of Telvent Canada Ltd. You
also agree not to establish any hypertext links to this guide or its content. All other rights are
reserved.
© 2016 Telvent Canada Ltd. All rights reserved.
Archive Reference Table of Contents
Table of Contents
1 Archiving..................................................................................................................................................5
2 The Archive Process...............................................................................................................................6
2.1 rts_archive.csc................................................................................................................................6
3 The Archive/Dearchive Menu..................................................................................................................8
4 Opening the Archive Schedule Summary window...................................................................................9
4.1 Filtering the information on the Archive Schedule Summary window...........................................10
5 Archive Control dialog box.....................................................................................................................12
5.1 Opening the Archive Control dialog box.......................................................................................12
5.2 Adding a New Entry in the Archive Schedule Summary window..................................................13
5.3 Modifying an Entry in the Archive Schedule Summary window....................................................13
5.4 Deleting an Entry in the Archive Summary window......................................................................14
6 Archive Cutoff........................................................................................................................................15
7 Archive Intervals....................................................................................................................................16
7.1 Daily Archive.................................................................................................................................16
7.2 Monthly Archive............................................................................................................................17
7.3 Yearly Archive...............................................................................................................................18
8 Adding an Archive Device.....................................................................................................................20
8.1 Defining an Archive Device..........................................................................................................20
9 Media Initialization.................................................................................................................................22
9.1 Initializing an Archive Device........................................................................................................22
10 Archive Troubleshooting......................................................................................................................23
11 Data Dearchiving.................................................................................................................................24
11.1 Opening the Dearchive window..................................................................................................25
11.2 Opening the Dearchive dialog box..............................................................................................25
12 Data Cleanup.......................................................................................................................................27
12.1 rts_cleanup.csc...........................................................................................................................28
12.2 Cleaning up Dearchived Data (Method 1)..................................................................................28
12.3 Cleaning up Dearchived Data (Method 2)..................................................................................29
13 Data Rearchiving.................................................................................................................................30
14 MonitorArchive Process.......................................................................................................................31
15 Archive Support...................................................................................................................................32
16 Archive Structure.................................................................................................................................34
16.1 Archive Catalog Table.................................................................................................................34
16.2 Archive ConfigModEventKeys Table..........................................................................................35
16.3 Archive Device Table..................................................................................................................36
16.4 Archive DumpSchedule Table....................................................................................................36
16.5 Archive Rearchive Table.............................................................................................................36
16.6 Archive RearchiveDatabases Table............................................................................................37
16.7 Archive Schedule Table..............................................................................................................37
16.8 Archive ScheduleAuditTrail Table...............................................................................................38
3
Table of Contents Archive Reference
4
Archive Reference Archiving
1 Archiving
Disk space is gradually used up as data is stored in Historical. To conserve space, information should be
archived if it is not currently in use. Archive scheduling is the customer’s responsibility and must be
configured according to each customer’s individual requirements. If required, archived information can
be dearchived and restored to Historical.
An archive device can be installed on the archive host. The historical databases can then be configured
to be archived on the archive device. For the archiving to function properly, define and set up the
designated archive device entries, and then customize the archive schedule.
5
The Archive Process Archive Reference
Archiving is a multi-step process. When archiving is initiated, the data to be archived is placed in a
temporary table. The temporary table is copied to disk and the new file is copied to an archive file on the
archive device. The archive device is configured in the archive schedule table. An archive file name
takes the following form:
system_service_database_table_date.archive_version
where:
service is the name of the service that contains the archived data; the default value is Archive.
database is the name of the database that contains the archived data.
table is the name of the table that contains the archived data.
version is the version number of the archive, starting with 0. The version number is incremented if data
is re-archived.
NOTE: OASyS DNA Services with SQL Servers may be scheduled for archiving data.
A log of the archive is written into the catalog table and the date of the archive is recorded in the
schedule table.
Data is automatically archived when it becomes older than the date specified by the archive cutoff date
set in the archive schedule table. The is used to set this value. The format of the Archive Cutoff field
entry contained in this form is YY:MM:DD. YY, MM, and DD specify the number of years, months, and
days, respectively, that should elapse before the specified data can be archived.
2.1 rts_archive.csc
Archiving is done by executing rts_archive.csc on the RealTime machine.
First, the rts_archive.csc locates the archive host, then executes archive_support.exe
program. The Job Scheduler (JSH) is normally configured to execute rts_archive.csc once per day,
usually at a time when the system is not busy. The syntax for rts_archive.csc is:
where:
-A specifies a host where the archive device is located. If a host is not specified, the primary Archive
Service host for the local system is used.
6
Archive Reference The Archive Process
7
The Archive/Dearchive Menu Archive Reference
NOTE: Creation of an archive device is performed by Schneider Electric personnel during system
configuration. To open the Archive/Dearchive Menu:
Procedure
The following table lists the buttons on the Archive/Dearchive menu and the corresponding actions
when these are chosen.
Related Information
Data Cleanup on page 27
8
Archive Reference Opening the Archive Schedule Summary window
Procedure
The following table provides brief descriptions of the buttons, fields, and column headings that appear
on the Archive Schedule Summary window.
9
Opening the Archive Schedule Summary window Archive Reference
Related Information
Archive Intervals on page 16
Data Cleanup on page 27
10
Archive Reference Opening the Archive Schedule Summary window
Procedure
11
Archive Control dialog box Archive Reference
The Archive Control dialog box is used to create or schedule an archive entry.
• Click Add Schedule on the summary window. This opens a blank Archive Control dialog box.
Use this to add a new signal configuration.
The following table provides brief descriptions of the buttons, fields, and column headings that appear
on the Archive Control dialog box.
12
Archive Reference Archive Control dialog box
Related Information
Archive Intervals on page 16
13
Archive Control dialog box Archive Reference
14
Archive Reference Archive Cutoff
6 Archive Cutoff
For time-based tables, the Archive Cutoff field indicates how old the data must be before being
archived (time-based tables contain a column named time).
The format is YY:MM:DD, where YY is the number of years old that the data must be, MM is the number
of months, and DD is the number of days. For example, if the current time is 05-Feb‑96 14:35 when
archive runs, then the conditions that are indicated in Archive Cutoff sample (time-based) (Table 1)
apply.
For non-time-based tables, the cutoff indicates the interval at which the entire table’s data must be
archived. For example, consider the cutoff specifiers and possible archiving frequencies listed in
Archive Cutoff sample (non time-based) (Table 2).
Note that the archive end time is not a guarantee that data is archived up to the end time. It guarantees
only that data younger than the end time is not archived. Refer to the Archive Intervals section for
more information.
15
Archive Intervals Archive Reference
7 Archive Intervals
What’s in This Chapter?
7.1 Daily Archive.....................................................................................................................................16
An archive schedule is performed daily, monthly, or yearly depending on the Archive Cutoff field
configuration in the Archive Control dialog box.
A daily archive is performed on data that requests archiving at a cutoff interval of less than one month. A
monthly archive is performed on data that requests archiving at a cutoff interval of greater than or equal
to one month but less than one year. A yearly archive is performed on data that requests archiving at a
cutoff interval of greater than or equal to one year.
NOTE: Timestamps start on the midnight of the Archive server time, except on tables configured for
partitioning, where timestamps start on UTC midnight.
Related Information
Opening the Archive Schedule Summary window on page 9
Opening the Archive Control dialog box on page 12
16
Archive Reference Archive Intervals
The figure above shows a schedule created on January 1, 1997 with an Archive Cutoff value of three
days and a Delete Cutoff value of four days. Archiving does not take place until the start of the day on
January 5th since, until then, none of the collected data is more than three days old. Data that have
been archived once are not archived a second time even if these have not been removed by the
cleanup process. Data cleanup does not take place until the start of the day on January 6th since, until
then, none of the collected data is more than four days old.
17
Archive Intervals Archive Reference
The figure above shows a schedule created on January 1, 1997 with an Archive Cutoff value of two
months and a Delete Cutoff value of two months. Archiving does not take place until the start of the
day, April 1, since until then, none of the collected data is older than two months. Intervals between two
and three months are considered to be two months for purposes of monthly archiving. Data cleanup
does not take place until the start of the day, April 1, since until then, none of the collected data is older
than two months. The data must be archived before the cleanup process because unarchived data
cannot be deleted. If the execution times for these two scripts were set up in the wrong order, the first
data cleanup would not take place until May 1.
18
Archive Reference Archive Intervals
The figure above shows a schedule created on January 1, 1993 with an Archive Cutoff value of one
year and a Delete Cutoff value of one year. Archiving does not take place until the start of the day,
January 1, 1995 since, until then, none of the collected data is older than one year. Intervals between
one and two years are considered to be one year for purposes of yearly archiving. Data cleanup does
not take place until the start of the day, January 1, 1995 since, until then, none of the collected data is
older than one year. Unarchived data cannot be deleted; hence, the data must first be archived before
the cleanup process. If the execution time for these two scripts were set up in the wrong order, the first
data cleanup would not take place until January 1, 1996.
19
Adding an Archive Device Archive Reference
Prior to archiving data into an archive device, the device must first be defined and initialized. The Add
Archive Device dialog box is used to define an archive device.
Procedure
• To open the Add Archive Device dialog box, click the Add Device button on the Archive/Dearchive
menu.
The following table lists the items that appear on the Add Archive Device dialog box.
Related Information
Data Cleanup on page 27
20
Archive Reference Adding an Archive Device
Procedure
21
Media Initialization Archive Reference
9 Media Initialization
What’s in This Chapter?
9.1 Initializing an Archive Device............................................................................................................22
Prior to archiving data into an archive device, the device must first be defined and initialized. The
Archive Initialization dialog box is used to initialize an archive device.
1. To open the Archive Initialization dialog box, click Initialize Media on the Archive/Dearchive
menu.
Related Information
Archive Troubleshooting on page 23
Data Cleanup on page 27
Procedure
22
Archive Reference Archive Troubleshooting
10 Archive Troubleshooting
This section gives the generic alarm messages that the archive process may generate and the
recommended user response. The actual messages are often variations of those listed in this section.
Either no disk is present in the disk drive or the wrong disk is in the drive. Remove the existing disk and
replace it with the disk having the label (some_label) that is indicated.
When archiving to a fixed disk, this means that the disk is now full. For removable media, this means
that a new media is needed.
Related Information
Media Initialization on page 22
23
Data Dearchiving Archive Reference
11 Data Dearchiving
What’s in This Chapter?
11.1 Opening the Dearchive window......................................................................................................25
NOTE: As of Elk SP3, if a supported table has been configured for Partitioning for the Historical service,
the Start Time and End Time will be determined by UTC time. However, the Start Time and
End Time of the other tables will still be determined by Archive host time. For more information
on Partitioning, see the Historical documentation.
24
Archive Reference Data Dearchiving
Procedure
You may use the filters to find the archived file to dearchive.
2. Click the row header of a selected record. This opens the Dearchive Control dialog box with its
field populated by configuration information of the record.
3. Select the archive host.
25
Data Dearchiving Archive Reference
4. (If required) Select the Service, the Database and the Table.
5. Select the Start/End Date.
6. Click Dearchive.
The following table provides brief descriptions of the buttons, fields, and column headings that appear
on the Dearchive Control dialog box.
Related Information
Data Cleanup on page 27
26
Archive Reference Data Cleanup
12 Data Cleanup
What’s in This Chapter?
12.1 rts_cleanup.csc...............................................................................................................................28
After the historical data has been archived, it is eligible for cleanup. The cleanup process deletes all
data that has been archived and is older than the Delete Cutoff time specified in the Archive Control
dialog box. The date of the most recent deletion is also recorded in the schedule table.
After the historical data has been archived, it is eligible for cleanup. The cleanup process deletes all
data that has been archived and is older than the Delete Cutoff time specified in the Dearchive
Control dialog box. The date of the most recent deletion is also recorded in the schedule table.
In order to delete data, it must be archived. Therefore, when using JSH to schedule archiving and
cleanup, the former must be performed first. If you do not wish to save the data to an archive device,
then archive to the null device (i.e. NUL).
The Delete Cutoff field entry in the Archive Control dialog box specifies how old data must be before it
is deleted. Each entry follows the YY:MM:DD format, where YY specifies how many years must elapse,
MM specifies how many months must elapse, and DD specifies how many days must elapse before
deletion. The deletion time is calculated with respect to the start of the current day.
To illustrate, if the current time is 05-Feb‑96 14:35 when the cleanup process runs, the cutoff specifier
causes the archived data to be deleted as shown in the Delete Cutoff sample table below.
Previously deleted data that is subsequently dearchived is not cleaned up automatically by the system.
NOTE: Delete dearchived data as soon as it is no longer needed; otherwise, it fills up the database and
leaves no room for the data that is currently being collected.
Related Information
Using the Dearchive Cleanup dialog box
The Archive/Dearchive Menu on page 8
Opening the Archive Schedule Summary window on page 9
Adding an Archive Device on page 20
Media Initialization on page 22
Opening the Dearchive window on page 25
27
Data Cleanup Archive Reference
12.1 rts_cleanup.csc
Manual data cleanup can also be done using rts_cleanup.csc.
The process is started by executing rts_cleanup.csc on the RealTime machine. This locates the
Archive service host and executes the archive_support.exe program on that host. The syntax is:
where:
-A specifies a optional host name to force the command to run on. If a host is not specified, the primary
Archive service host for the local system is used.
NOTE: The Job Scheduler (JSH) is normally configured to run rts_cleanup.csc once per day after
rts_archive.csc has already run.
28
Archive Reference Data Cleanup
Procedure
Procedure
29
Data Rearchiving Archive Reference
13 Data Rearchiving
If historical data that has already been archived is edited, it is automatically scheduled for rearchiving.
Rearchive is triggered after each regular archive is performed by rts_archive.csc. The archive program
checks the rearchive table. If there are any entries in the table, the archive program collects information
from the schedule and catalog tables as required for rearchiving (for example, rearchive format and
device). After the information is collected, the rearchive is performed.
The archive file name for rearchived data is identical to the original file name, except that the version
number suffix is incremented each time the data is required. Therefore, the file name with the highest
version number reflects the most current state of the data.
Rearchive Troubleshooting
If rearchiving cannot be scheduled in the rearchive table after data is modified or inserted, the reason
may be one of the following:
• The data being modified or inserted has not been previously archived.
• The database and table in which the data was modified or inserted are not scheduled for archive in
the schedule table.
• The data being modified or inserted corresponds to the same period defined by the start and end
times of an entry already in the rearchive table, which was created previously due to modification or
insertion of the data in the same time interval in the same database and table.
If you need help to troubleshoot data rearchiving concerns, please contact your Service manager.
30
Archive Reference MonitorArchive Process
14 MonitorArchive Process
The monitorArchive process integrates the Archive Service into the Historical Service by
continuously transferring system data between the two services.
The monitorArchive process connects to the database server of the specified service and periodically
scans for any rearchive requests which have been logged there for processing.
NOTE: It gathers the rearchive requests and ensures that such requests are added to the rearchive
table.
In order to prevent overloading the specified system at peak period, the monitorArchive process halts
all connections during the first 10 minutes at the top of the hour.
The monitorArchive process also forwards the operational activities from the Archive Service to other
services for processing. Configuration modification events which are logged internally from various
Archive operations are forwarded by the monitorArchive process to the Historical Service in order to
complete proper OASyS DNA® event logging and audit trail.
31
Archive Support Archive Reference
15 Archive Support
The archiveSupport program accepts requests on the Archive host to perform archive, dearchive and
cleanup operations.
It is called by rts_archive.csc, ezXOS Dearchive Control form and rts_cleanup.csc respectively. Specific
arguments which related to each operation are passed along to the archive.exe, dearchive.exe and
cleanup.exe as appropriate.
32
Archive Reference Archive Support
33
Archive Structure Archive Reference
16 Archive Structure
What’s in This Chapter?
16.1 Archive Catalog Table.....................................................................................................................34
The Archive database is composed of tables that are only accessible to the System Manager. The
following sections list the tables in the Archive database.
A large part of the Archive database functionality is configured at system set-up. If you have questions
or concerns with the system, please contact your Service manager.
The following table provides information on Schneider Electric-defined data-types that are used in
Archive tables.
boolType bit
cutoffType char(8)
deviceType varchar(40)
devnameType varchar(40)
eventNameType nvarchar(192)
filenameType varchar(80)
GMToffset smallint
GMTtime int
IDType smallint
labelType varchar(8)
sysNameType varchar(30)
34
Archive Reference Archive Structure
35
Archive Structure Archive Reference
36
Archive Reference Archive Structure
37
Archive Structure Archive Reference
38
Archive Reference Archive Structure
39
Schneider Electric
49 Quarry Park Blvd SE
Calgary, AB T2J 6V8 - Canada
Phone: 1 (403) 253-8848
www.schneider-electric.com