jan. 30th, 2015kit seminar, paul scherrer institute, switzerland the electronic logbook elog and its...
TRANSCRIPT
Jan. 30th, 2015KIT Seminar,
Paul Scherrer Institute, Switzerland
The electronic logbook ELOG and its utilization for accelerator operations
Stefan Ritt
Stefan Ritt 2/23
• Part 1• Quick demo• Design principles of ELOG• Advanced features: Automatic
entries, Checklists, Mirroring• Part 2• ELOG @ PSI for accelerator
operation
Agenda
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 3/23
• MIDAS DAQ system developed in 1996-• Originally for PIBETA experiment @ PSI• First system with web interface
• Need for electronic logbook• Searchable• Easy to copy/distribute• Remote access
• Birth of ELOG• First was integral part of MIDAS system• Standalone version in 2001• 83 Releases 1.0.0 – 3.0.0 (current)
(elog/doc/ChangeLog)
A bit of history
Jan. 30th, 2015KIT Seminar,
Version 1.8.3, released August 8, 2001--------------------------------------
- Fixed problems occurring under Red Hat 7.1- modified mserver.c to run under xinetd- put xinetd configuration info into INSTALL file- added /Custom tree in ODB for mhttpd to display user-specific pages- standalone elogd program included for offline logbook display- added mail notification in elog in mhttpd
OPEN SOURCE PACKAGE
Stefan Ritt 4/23
• Web access• Reachable from any computer with Web Browser• Monolithic C(++) program
• Faster than interpreted languages• Needs less memory, runs nicely on Raspberry PI• Does not depend on Web servers• No dependency of external libraries
(except SSL and Kerberos)• Simple to compile and install
• Recent extensions in JavaScript
• “Designed by user”• Only contains features that are needed• (Most) needed features are contained
• Configurable• Can be electronic logbook, discussion forum, bug tracker, …• Huge number of configuration options• Some will be covered in this seminar
Basic principles of ELOG
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 5/23
• Simple text database• Relational databases (mySQL) were not available or were
“heavy” back in 2001• Database cannot get corrupt• Database can be edited with ASCII editor (by “experts”)• Many people use scripting tools to analyze or modify ELOG
databases• Attachments as files
• Data storage with one file per day YYMMDDa.log• Can make easy backups $ cp 14????a.log /backup• Recent change with one
subdirectory per year
2013/13*a.log2014/14*a.log…
ELOG Database
Jan. 30th, 2015KIT Seminar,
$@MID@$: 1Date: Thu Nov 08 18:37:57 2001Author: Stefan RittType: RoutineCategory: GeneralSubject: WelcomeAttachment: Encoding: ELCode========================================[B]Congratulations for installing ELOG sucessfully![/B]
This is a demo entry to ensure the elogd server is working correctly. Click [I]"New"[/I] to add new pages and [I]"Delete"[/I] to delete this page.
Stefan Ritt 6/23
Different “faces”
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 7/23
• Configuration via single text file, editable through web browser• Total of 149 settings and 41 flags• Documented on one huge page:
http://midas.psi.ch/elog/config.html
Configuration Concepts
Jan. 30th, 2015KIT Seminar,
[global]port = 8080
[demo]Theme = defaultComment = General Linux Tips & TricksAttributes = Author, Type, Category, SubjectOptions Type = Routine, Problem Fixed, Configuration, OtherOptions Category = General, Hardware, Software, Network, OtherRequired Attributes = Author, TypeQuick filter = Date, TypeReverse sort = 1. . .
Server options valid for all logbooks
Logbook
Attributes
Flag
Stefan Ritt 8/23
• Attributes are values common to all entries in a logbook, like “columns” in a relational database
• Defined via Attributes = Author, Type, Category
• Stored in header of text files• Attribute sets are extendable
Attributes
Jan. 30th, 2015KIT Seminar,
$@MID@$: 1Date: Thu Nov 08 18:37:57 2001Author: Stefan RittType: RoutineCategory: GeneralSubject: WelcomeAttachment: Encoding: ELCode========================================[B]Congratulations for installing ELOG sucessfully![/B]
This is a demo entry to ensure the elogd server is working correctly. Click [I]"New"[/I] to add new pages and [I]"Delete"[/I] to delete this page.
Stefan Ritt 9/23
• Settings can depend on the value of an attribute
• Hide certain attributes on condition, different tooltips, logical or of conditions, …
• “Merge” different logbooks into one
Conditional attributes
Jan. 30th, 2015KIT Seminar,
Attributes = PC Name, Operating System, VersionOptions Operating System = Linux{1}, Windows{2}{1} Options Version = 2.2, 2.4, 2.6{2} Options Version = NT, XP, W7, W8
Stefan Ritt 10/23
• Enable/Disable almost all features• Default presets for most dialog boxes• Select language (17 languages available)
Flags
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 11/23
• Email notifications for certain processes• New entry, modified entry• Email to registered user(s) or external email addresses• Attributes have certain values
(like new entry with system=DAQ & category=Error)• Email can contain summary, full entry, with/without
attachments
Email notifications
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 12/23
• Simple access control via read & write passwords (obsolete)
• User accounts with central password database (XML) and optional guest access
• Auto-logout, self register [with admin approval]• Kerberos & LDAP support
Access control
Jan. 30th, 2015KIT Seminar,
<?xml version="1.0" encoding="ISO-8859-1"?><!-- created by MXML on Wed Dec 17 14:52:42 2014 --><list> <user> <name>stefan</name> <password encoding="SHA256">GbnPpEbx9tFFQ/iUW3mU8Cmi/a.JXVwdmVk74jFt56C</password> <full_name>Stefan Ritt</full_name> <email>[email protected]</email> <last_logout>Thu Oct 23 09:37:45 2014</last_logout> <last_activity>Thu Oct 23 11:43:28 2014</last_activity> <email_notify> <logbook>Online</logbook> <logbook>DAQ</logbook> </email_notify> </user></list>
Stefan Ritt 13/23
Themes
Jan. 30th, 2015KIT Seminar,
CSS = <file.css>
/* default formatting */body { margin:3px; color:black; background-color:white; font-family:verdana,tahoma,sans-serif; /* background-image:url(elog.gif); */}
/* standard link colors and decorations */a:link { color:#0000FF; text-decoration:none }a:visited { color:#800080; text-decoration:none }a:hover { color:#0000FF; text-decoration:underline }a:active { color:#0000FF; text-decoration:underline }a:focus { color:#0000FF; text-decoration:underline }
td { color:black; font-size:12px;}
Stefan Ritt 14/23
• Keep two or more logbooks in sync• Synchronization works both ways• Implementation using MD5 hash values
Mirroring
Jan. 30th, 2015KIT Seminar,
ID 3 MD5
ID 2 MD5
ID 1 MD5
ID 3 MD5
ID 2 MD5
ID 1 MD5
Logbook 1 Logbook 2
ID 3 MD5
ID 2 MD5
ID 1 MD5
ID 3 MD5
ID 2’ MD5
ID 1 MD5
ID 4 MD5
ID 3 MD5
MD5
ID 1 MD5
ID 3 MD5
ID 2’ MD5
ID 1 MD5
ID 4 MD5
ID 2’
ID 4 MD5
Mirror server = <URL-list>Mirror config = 0 | 1Mirror cron = 0 3 * * * // every night at 3:00
Stefan Ritt 15/23
elog -h <hostname> Host name of elog server [-p port] Port number, default 80 -l logbook Name of logbook -s Use SSL for communication [-v] For verbose output [-w password] Write password defined on server [-u username password] User name and password [-f <attachment>] Up to 50 attachments -a <attribute>=<value> Up to 50 attributes [-r <id>] Reply to existing message [-q] Quote original text on reply [-e <id>] Edit existing message [-x] Suppress email notification [-n 0|1|2] Encoding: 0:ELcode,1:plain,2:HTML -m <textfile>] | <text> Entry body
“elog” utility
Jan. 30th, 2015KIT Seminar,
• Command line utility to commit ELOG entries• Scriptable “cat text | elog –h … -l …”• Automatic entries e.g. accelerator status → next talk
Stefan Ritt 16/23
• Completely custom HTML hand crafted forms as input forms for logbooks
• Perfect for shift checks with tablet computers
Shift Checklist
Jan. 30th, 2015KIT Seminar,
https://midas.psi.ch/elogs/Forum/66909
Stefan Ritt 17/23
Check list table
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 18/23
Search engine in Browser
Jan. 30th, 2015KIT Seminar,
• Most browsers allow definition of custom search engines• Define ELOG as a search engine with custom search string
http://midas.psi.ch/elogs/Forum/?subtext=%s
Stefan Ritt 19/23
• Recent extension (Dario Milicic) allows Rich Editing, Drag & Drop of images and smartphone photo upload
CKEditor
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 20/23
• http://midas.psi.ch/elog/download.html• Public GIT repository
• “make”• “sudo make install”• “sudo /etc/init.d/elogd start”• “launchctl” under OSX
• Source code TAR ball• Windows Binaries• Linux Binaries (RPS)• Debian Package
Installation
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 21/23
• Use since 2001 for three large experiments with ~30 logbooks
• Reliable, easy to use• “monit” tool to restart crashed server (couple of
times per year on public server)• In spite of vast usage (~10 labs, all LHC
experiments) I get only ~few issues per month• Logbook size fine to ~few 100’000 entries, search
can get slow
Personal experience with ELOG
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 22/23
In case of questions …
Jan. 30th, 2015KIT Seminar,
Stefan Ritt 23/23
How to match existing functionality to accelerator operation needs?
ELOG for accelerator operation
Jan. 30th, 2015KIT Seminar,
CSS
Bookmarks
ConditionalFormatting
Kerberos
Mirror Servers
Access Rules
elogCommand
Forms
Export
StructuredInformation
Logbook Groups
Calculated Fields Actions
→ Andreas Lüdeke