Presentation is loading. Please wait.

Presentation is loading. Please wait.

The DCS Databases Peter Chochula. 31/05/2005Peter Chochula 2 Outline PVSS basics (boring topic but useful if one wants to understand the DCS data flow)

Similar presentations


Presentation on theme: "The DCS Databases Peter Chochula. 31/05/2005Peter Chochula 2 Outline PVSS basics (boring topic but useful if one wants to understand the DCS data flow)"— Presentation transcript:

1 The DCS Databases Peter Chochula

2 31/05/2005Peter Chochula 2 Outline PVSS basics (boring topic but useful if one wants to understand the DCS data flow) Configuration Database DCS Archive –Architecture –Access to the DCS archive Current status

3 31/05/2005Peter Chochula 3 Driver Layer Communication and Storage Layer Application Layer UI Layer The PVSS Architecture User Interface Manager Data Manager Driver User Interface Manager User Interface Manager Event Manager API Manager Control Manager

4 31/05/2005Peter Chochula 4 User Interface Manager Data Manager Driver User Interface Manager User Interface Manager Event Manager API Manager Control Manager In a scattered system, the managers can run on dedicated machines In a simple system all managers run on the same machine

5 31/05/2005Peter Chochula 5 Distribution Manager Distribution Manager Distribution Manager User Interface Manager Data Manager Driver User Interface Manager User Interface Manager Event Manager API Manager Control Manager User Interface Manager Data Manager Driver User Interface Manager User Interface Manager Event Manager API Manager Control Manager User Interface Manager Data Manager Driver User Interface Manager User Interface Manager Event Manager API Manager Control Manager In a distrubuted system several PVSSII systems (simple or scatered) are interconnected

6 31/05/2005Peter Chochula 6 Remarks The DCS configuration is not static and will change in time –The managers may be scattered if needed –Individual systems may be split into distributed system, or joined together –Devices might be added/removed, channel assignment might change At present time we expect the global DCS will be formed by a distributed PVSS system consisting of individual scattered systems

7 31/05/2005Peter Chochula 7 PVSSII basics - Datapoints PVSS data is stored as Datapoints (DP) of a given Datapoint Type (DPT) DPT represents data structure of the device –User definable DP contains information related to an instance of a device (similar to Objects and Classes) –DP can contain many read/write parameters called Datapoint Elements (DPE) –Possible DPE types include char,integer, float, boolean … and arrays made of them –DP contains configs, which are defining its behavior (e.g. archiving, smoothing, alarm handling etc.) –Several status bit indicate the quality of acquired data, etc.

8 31/05/2005Peter Chochula 8 Example Datapoint DPT DP DPE SystemName:DPName:DPE Value Timestamp Config System1:TestFloat1:floatvalue

9 31/05/2005Peter Chochula 9 Remarks The full Datapoint name includes the system name. This can change with time if the system gets distributed An alias name is available for each DP and can be used to simplify its tracking (e.g. if a device channel assignment changes within a detector)

10 31/05/2005Peter Chochula 10 DCS Databases Two databases are essential for the DCS operation Configuration database stores : –Static settings (channel assignments, board configuration…) –Dynamic settings (alarm limits, voltage set values, FERO parameters…) DCS Archive stores: –Measured values –Alarms

11 31/05/2005Peter Chochula 11 The DCS configuration database Configuration of all DCS devices is stored here Different versions (recipes) exist for different operation modes (calibration, cosmics, collisions…) Recipes can be changed during the operation (e.g. HV ramping through the intermediate state)

12 31/05/2005Peter Chochula 12 The DCS Archive Designed to store measured values Configured and accessed via the PVSS Tools exists for mass configuration of archival settings (smoothing, averaging, etc.) All data written into the archive is timestamped Only values read from devices are stored in the archive (e.g. no direct data flow between the configuration database and the archive) Recipe versions are archived if the recipe is changed

13 31/05/2005Peter Chochula 13 What data goes into the DCS archive? Only monitored values marked for archival are stored (DP config required). This includes: Data directly acquired by the DCS – HV, LV, FERO, magnetic field, environmental parameters, … External Data and Services – electricity, racks, DSS, LHC information, … ALICE specific information – run number, run type, …

14 31/05/2005Peter Chochula 14 The DCS Data Flow Config. PVSS Archive Devices ECS Electricity Ventilation Cooling Gas Magnets Safety Access Control LHC DAQTRIHLT DIM, DIP

15 31/05/2005Peter Chochula 15 DCS Archive implementation New method of PVSS archiving is finally available The PVSS RDB archival is replacing the previous method based on local files –All PVSS-based tools are compatible with the new approach (we can profit from the PVSS trending etc.) –Oracle database server is required –Architecture resembles the previous concept based on files A set of Windows DLL’s and Linux libraries is used to access the archive from PVSS –Data storage and retrieval within the PVSS works without changes A library handles the management of data on the Oracle Server (create/close tables, backup tables…)

16 31/05/2005Peter Chochula 16 PVSS Archive Tables For each group of archived values a set of tables is generated –LastVal – input table storing the most recent value –Current – a table keeping a history record of measured values. An Oracle trigger is used to write data to this table The table is closed if it exceeds a predefined size and is replaced with a new one The latest available values are copied to the new table automatically –Online – a copy of the closed Current table –Offline – a table written to backup media and not directly available A set of internal tables for database maintenance exists Archive tables are using their own tablespace (this is why a trigger is needed) For each Datapoint several parameters are stored: –Value –Timestamp(s) –Flags (for example reliability)

17 31/05/2005Peter Chochula 17 Online SPD HistoryValues 00000123 Online SPD History 00000123 Online SPD HistoryValues 00000124 Online SPD History 00000124 Basic DCS archive configuration SPD LastValValues SPD LastVal Current SPD HistoryValues 00000125 Current SPD History 00000125 Offline SPD HistoryValues 00000011 Offline SPD HistoryValues 00000012 Offline SPD History 00000011 Offline SPD History 00000012 (arrays)(“basic” datapoints)

18 31/05/2005Peter Chochula 18 Accessing the Archive Tables A set of libraries is available on the PVSS side to access the data from the database The libraries hide the archival complexity – user need to specify the Datapoint name and the time interval A dedicated library allows for direct database access (bypassing the PVSS managers)

19 31/05/2005Peter Chochula 19 Example of Data Selection in PVSS (1)

20 31/05/2005Peter Chochula 20 Example of Data Selection in PVSS (2)

21 31/05/2005Peter Chochula 21 Example of Data Selection in PVSS (3)

22 31/05/2005Peter Chochula 22 Example of Data Selection in PVSS (4) Generated SQL Statement Result of the query

23 31/05/2005Peter Chochula 23 External access to the PVSS archive Database schema is available – data can be queried from external programs A set of basic Oracle views is provided by the ETM –The complexity of the table partitioning is hidden A PVSS HTTP server allows for remote DP queries

24 31/05/2005Peter Chochula 24 Root–to–PVSS interface Developed by V.Filimonov (ATLAS) Allows for extraction of PVSS data into root PVSS manager (GetArc) accepts requests from clients, reads data from PVSS database and sends it to the client. A set of Root classes define the client protocol Manager and Client interact via TCP/IP using the PVSS API

25 31/05/2005Peter Chochula 25 Root–to–PVSS communication Example: get data for a given period of time TPVSSAccess *sock = new TPVSSAccess("pcpix06.cern.ch",4242); char *dp = "TestFloat1.floatvalue"; int rlen = sock->GetTimePeriod(dp,startTime,endTime,len,Values,ts); Additional classes allow for displaying trends etc. DP name Time Period Length of data values timestamps

26 31/05/2005Peter Chochula 26 Root–to–PVSS example of trend Online trend in PVSS Online trend in Root

27 31/05/2005Peter Chochula 27 Condition database developments The conditions database will store a subset of the archived data in a form convenient for offline processing JCOP framework is developing the interface to conditions database Conditions data will be written “on fly” by a dedicated process CMS, ATLAS and LHC-B plan to use COOL so all common tools will be available only for this architecture No developments for root are foreseen

28 31/05/2005Peter Chochula 28 Present Status Prototype of the configuration database exists We are running a private Oracle server in the DCS lab First tests with RDB archiving performed, feedback provided to ETM We are aiming for a stable service during this summer (P2 and Lab)


Download ppt "The DCS Databases Peter Chochula. 31/05/2005Peter Chochula 2 Outline PVSS basics (boring topic but useful if one wants to understand the DCS data flow)"

Similar presentations


Ads by Google