Keys in the ODB /Logger/History subtree
Links
/Logger/History subtree
The ODB /Logger/History subtree is a subdirectory of the ODB /Logger tree, created when the MIDAS logger utility mlogger is started for the first time. The keys will be filled with default values which users may change as required to customize their experiments.
When mlogger is started for the first time, it now creates five /Logger/History/<history-logging-channel> ODB subtrees to control the five default history-logging-channels, named for each of the default History drivers.
The keys present in each history-logging-channel are described below.
Example
The following example shows the /Logger/History ODB subtree after creation by mlogger (obtained using the odbedit ls command). See below for information on individual keys.
[local:midas:S]/>ls -r /Logger/History History MIDAS Type MIDAS Active y Debug 0 PerVariableHistory 0 ODBC Type ODBC Active n Debug 0 Writer_ODBC_DSN history_writer Reader_ODBC_DSN history_reader SQLITE Type SQLITE Active n Debug 0 Sqlite dir MYSQL Type MYSQL Active n Debug 0 MYSQL Writer mysql_writer.txt MYSQL Reader mysql_reader.txt FILE Type FILE Active n Debug 0 History dir
<history-logging-channel> subtrees
Each <history-logging-channel> subtree in the /Logger/History|Logger/History subtree is created to control one of the history drivers available, and named for that history driver.
Keys common to all history logging channels
The following three keys are common to all history logging channel subtrees :
Type
- Type: STRING
- Default: History driver name
Each <history-logging-channel> subtree contains a Type key which specifies the type of History driver for this history-logging-channel.
mlogger creates each channel with this key set to the history-logging-channel, e.g. for MIDAS-history logging ;
- /Logger/History/MIDAS/Type will be set to "MIDAS"
- for ODBC-history logging
- /Logger/History/ODBC/Type will be set to "ODBC"
etc.
(see Example above).
Active
- Type: BOOL
- Default: "n"
Each <history-logging-channel> subtree contains a Active key which enables or disables history logging in this history-logging-channel.
By default, only the MIDAS-history logging channel will be set active, i.e. /Logger/History/MIDAS/Active will be set to "y".
Note;
- this key in the /Logger/History/MIDAS subtree replaces obsolete key
Debug
- Type: INT
- Default: 0
Each <history-logging-channel> subtree contains a Debug key which controls the debug level for this <history-logging-channel>. If set to 0, debugging is disabled.
Note;
- Debug key in the ODBC subtree replaces obsolete key
MIDAS subtree
This is the history-logging-channel subtree that controls MIDAS-history logging.
The following section(s) describe keys unique to the MIDAS subtree.
For those Keys common to all history-logging-channels see
Note;
- By default, this logging channel will be set active.
PerVariableHistory
- Type: INT
- Default: 0
This key is present in the MIDAS-history logging subtree only (i.e. with Type key set to "MIDAS").
The default value of 0 is intended to operate the MIDAS-history in "traditional" mode. In this mode:
- there is one history record for each equipment
- history record id is equal to the equipment id
- /History/Events and /History/Tags are not required and can be safely deleted
Note;
- this key replaces obsolete key /History/PerVariableHistory
ODBC subtree
This is the [[<history-logging-channel> subtrees| history-logging-channel subtree]] that controls ODBC-history logging.
The following section(s) describe keys unique to the MIDAS subtree.
For those Keys common to all history-logging-channels see
Note:Debug key in this subtree replaces obsolete key /Logger/ODBC_Debug
Writer_ODBC_DSN
- Type: STRING
- Default: "history_writer"
This key is present in the ODBC-history logging subtree only (i.e. with Type key set to "ODBC"). It contains the ODBC Data Source Name for writing and is used by mlogger.
Note;
- this key replaces obsolete key
Reader_ODBC_DSN
- Type: STRING
- Default: "history_reader"
This key is present in the ODBC-history logging subtree only (i.e. with Type key set to "ODBC"). It contains the ODBC Data Source Name for reading, and is used by mhttpd and mhist utilities.
Note;
- this key replaces obsolete key /history/ODB_DSN
SQLITE subtree
This is the [[<history-logging-channel> subtrees| history-logging-channel subtree]] that controls SQLITE-history logging.
The following section(s) describe keys unique to the SQLITE subtree.
For those Keys common to all history-logging-channels see
Sqlite dir
- Type: STRING
- Default:
This key is present in the SQLITE-history logging subtree only (i.e. with Type key set to "SQLITE").
It contains the location of SQLITE database files, and is of the form "/file/system/path".