-rdb_url jdbc:... : default: 'jdbc:postgresql://localhost:5432/alarm' -rdb_user <user> : default: 'alarm' -rdb_password <password> : default: '$alarm' -rdb_schema <schema> : default: 'ALARM.' (The schema has to end with '.')
AlarmConfigTool -list
AlarmConfigTool -import -file /some/path/Test.xml -root TestThis deletes the configuration, then loads the file. The
-modify
option will instead try to update the existing configuration,
i.e. load new components or PVs, or update the guidance etc. of existing
entries.
This would import the demo.xml:
AlarmConfigTool -import -file /some/path/demo.xml -root demoNote that the name of the root element in the configuration file must match the name specified in the
-root ....
command-line argument.
This is a basic consistency check to avoid importing the wrong configuration.
It is best to always specify the full path to the XML configuration file.
When not using the full path, the tool will read or create files relative
to its current working directory, which in turn will be the 'workspace'
directory that depends on the operating system and can thus be somewhat unpredictable.
Using the full, absolute path, there will be no surprises.
AlarmConfigTool -export -file /some/path/Test.xml -root TestAgain provide the full path to the XML file to assert that it is indeed created in the desired location.
-- List all 'root' elements, note its NAME or COMPONENT_ID SELECT * FROM ALARM_TREE WHERE PARENT_CMPNT_ID is null; DELETE FROM ALARM_TREE WHERE NAME='that_name';
<config name="demo"> </config>For a better overview in the alarm system user interface the monitored PVs can be arranged in components (groups).
<component name="SomeGroup"> <!-- List of PVs --> </component> <component name="AnotherGroup"> <!-- List of PVs --> </component>The alarm system will typically latch alarms. This means that the alarm trigger PV can return to OK, later re-enter the alarm state and so on, but the alarm system will only react when a PV enters an alarm state for the first time. Subsequently, the alarm system user interface will display the current state of the PV, but it will not trigger a new alarm nor issue another annunciation. This is meant to reduce noise from the alarm system.
latching
statement in the config file this behaviour can be changed for each PV.<pv name="SomePVname"> <description>PVdescription</description> <latching>true</latching> <annunciating>true</annunciating> </pv>A complete configuration file is included in the package (
css-panda/AlarmConfigTool/demo.xml
)
css-panda/AlarmServer/settings.ini
:
# Generic Alarm Server Settings # Alarm System 'root', i.e. configuration name org.csstudio.alarm.beast/root_component=Annunciator # Alarm System RDB Connection org.csstudio.alarm.beast/rdb_url=jdbc:postgresql://localhost:5432/alarm org.csstudio.alarm.beast/rdb_user=alarm org.csstudio.alarm.beast/rdb_password=$alarm org.csstudio.alarm.beast/rdb_schema=ALARM # Alarm System JMS Connection org.csstudio.alarm.beast/jms_url=failover:(tcp://localhost:61616) org.csstudio.alarm.beast/jms_user=alarm org.csstudio.alarm.beast/jms_password=$alarm # Alarm Server: Period for repeated annunciation of active alarms org.csstudio.alarm.beast.server/nag_period=00:15:00 # Channel Access # Network traffic can be optimized by only monitoring ALARM updates org.csstudio.platform.libs.epics/use_pure_java=true org.csstudio.platform.libs.epics/support_dbe_property=true org.csstudio.platform.libs.epics/monitor=ALARM org.csstudio.platform.libs.epics/addr_list= org.csstudio.platform.libs.epics/auto_addr_list=true # Logging preferences org.csstudio.logging/console_level=CONFIG org.csstudio.logging/jms_url= org.eclipse.ui/SHOW_PROGRESS_ON_STARTUP = falseThe RDB and JMS Connection settings have to match the configuration of environmental set up. Note that in contrary to the command-line argument from the config tool the RDB schema must not end with '.' in the settings.ini file. If the AlarmServer is running on a machine with multiple active network connections the channel access protocol will find the PVs existing on this host at all IP addresses which will cause an error because PV names must be unique within the whole network. In this case set
auto_addr_list=false
and list all relevant IP addresses for channel access in addr_list
seperated by a single blank.
To start/stop the AlarmServer a shell script is included (css-panda/AlarmServer/alarmserver
). The DIR
variable in this
file must be set to the path where the AlarmServer is located.
-rdb_url jdbc:... : default: 'jdbc:postgresql://localhost:5432/archive' -rdb_user <user> : default: 'archive' -rdb_password <password> : default: '$archive' -rdb_schema <schema> : default: 'archive.' Note: the schema has to end with '.'
ArchiveConfigTool -list
ArchiveConfigTool -import -config /some/path/Test.xml -engine Test -description "Description of this engine" -host localhost -port 4812 [-replace_engine]The ArchiveEngine uses a web interface to display status information. The address is defined with the
-host
and -port
arguments. Typically localhost and port 4812 are used.
Each channel can only be used in one engine. If setting up a second engine with channels that are already in another engine append the argument -steal_channels
.
This overwrites the engine settings for all channels in the imported configuration that are already in another engine.
It is best to always specify the full path to the XML configuration file.
When not using the full path, the tool will read or create files relative
to its current working directory, which in turn will be the 'workspace'
directory that depends on the operating system and can thus be somewhat unpredictable.
Using the full, absolute path, there will be no surprises.
ArchiveConfigTool -export -config /some/path/Test.xml -engine TestAgain provide the full path to the XML file to assert that it is indeed created in the desired location.
-replace_engine
.
ArchiveConfigTool -delete_config -engine TestThis deletes only the entry in the engine table. The channels and samples stay in the RDB. If desired, the channels and samples need to be removed manually via direct RDB SQL access.
css-panda/ArchiveConfigTool/demo.xml
)
http://<host>:<port>/main
The engine will compare the port number from the URL with the port number provided as a commandline
argument.
The engine web server provides several web pages, mostly linked from the .../main URL, that allow
you to see: http://localhost:4813
will result in an empty page. You have to start browsing at http://localhost:4813/main
.
Starting at .../main
, one can drill down to the status of groups and individual channels.
A few engine web pages are not accessible by following web browser links because they affect the engine
operation. This is meant to prevent a web-crawling program to accidentally stop the engine.
http://<host>:<port>/stop |
Invoke this URL to stop the engine gracefully, i.e. to ask the engine to write a final Archive_Off sample to each channel, then quit. |
http://<host>:<port>/restart |
Invoke this URL to trigger a running restart of the engine. The engine will stop sampling, read its configuration, then start again. Invoking this URL is required after changes to the configuration of an archive engine. |
http://<host>:<port>/reset |
Invoke this URL to reset engine statistics, for example the average write time displayed on the main page of the engine. |
http://<host>:<port>/environment |
Invoke this URL to display engine environment settings which might be useful when trying to debug a problem. |
css-panda/ArchiveEngine/settings.ini
.
Again the RDB Connection settings (and in some cases the Channel Access settings)
have to match the configuration of environmental set up.
For starting the Engine the shell script css-panda/ArchiveEngine/archiveengine
can be used.
Stopping the engine using this script is not recommended because it will lead to data loss due
to the sample storage routine. http://<host>:<port>/stop
should be invoked instead.
-data
command line argument
css-panda -data /path/to/workspaceIt is best to use always the workspace already existing in this package (
css-panda/css-panda/workspace
), because color and font definitions used by the OPI builder
reside in this directory.
Like the ArchiveEngine or the AlarmServer the RDB and JMS servers, usernames, passwords, and schemas have to be configured.
This is done in the preference gui (Edit->Preferences).
-- FlorianFeldbauer - 25 Oct 2012