WEB-BASED ELECTRONIC OPERATION LOG SYSTEM –ZLOG SYSTEM
K. Yoshii† , T. Nakamura, T. Kitabayashi‡
Mitsubishi Electric System & Service Co., Ltd., Tsukuba, Ibaraki 305-0045, JapanK. Furukawa, T.T. Nakamura, T. Obina, M. Satoh, N. Yamamoto
High Energy Accelerator Research Organization (KEK), Tsukuba, Ibaraki 305-0801, Japan
Abstract
The Zlog system, which is an electronic operation log
system based on Zope, has been used at the KEKB andPF-AR accelerator facilities in KEK since January 2004.
Zope is a Web content management system based on several open source software components such as Python andPostgreSQL. By using the Zope system, we were able todevelop our Zlog system in a short period because the Zopesystem includes a development framework for the Web application server. The Zlog system has also been introducedin J-PARC/KEK-JAEA and RIBF/RIKEN on the basis ofits success at the KEKB and PF-AR. The Zlog system isquite portable even under different computer architectures.
The Zlog system at the KEKB has accumulated approximately 1.5 million event entries thus far, and screenshot
images captured during the operation can be stored andviewed along with the entries. In this paper, we describe
the present status and component details of the Zlog system.

on Zope [4], whose technology development was advancing rapidly.
Because Zope is a Python-based Web application server
whose RAD (rapid application development) is easy, it was
found that we, who learned the Python language, could
complete the development of the operation log in a shortperiod. This Zlog system has been used since the winter of2004 [5].

ZLOG SYSTEM STRUCTURE
The Zlog system consists of the Zlog core, PostgreSQL,
and log monitor server. The Zlog core is a Web-based
application for browsing and editing the operation log
records. All the records of the operation log are stored in
PostgreSQL, which is a backend database server. The log
monitor server monitors certain events and automaticallyrecords them into the database. We discuss each subsystemin the following subsections.

INTRODUCTION
The KEKB [1] operational logbook was based on handwritten notebook entries until the summer of 2002. Subsequently, an electronic operation log system built in MSAccess/MS-SQL was used from autumn 2002 to winter2003 [2].
In the MS-Access-based log system, most entries haveto be entered manually as the system was developed for theLinac control system and it has no linkage to the KEKB
control system. Because operators are usually devoted tobeam tuning, they cannot afford a large amount of time fordata entries. In the summer of 2003, the KEKB control
group examined the automatic entry of operation log (electronic operational logbook) records for reducing the timeof the logbook entries. At that time, we established thetechnology of automatic entries into the Unix files of theoperation content [3].
The addition of the function of automatically importing data from the file to the MS-Access-based log system
was examined initially; however, it was found that its development period was prolonged. Therefore, we subsequently started developing an operation log system based† < kenzi @ post.kek.jp >‡ Presently at Tokai University, Japan.

Figure 1: Zlog system.

Database Server: PostgreSQL
Our requirements for the database subsystem are the capability of handling a large amount of data, a stable operation, and an effective management system for ease ofconstruction and maintenance. We also planned for several
kinds of operation logs to be constructed in the Zlog system. Considering these factors, we introduced PostgreSQL
with a succession function.
The operation log of the KEKB comprises 1.5 million
event entries and 1500 entries are accumulated everyday;
however, it is working smoothly. We can set up another
PostgreSQL server for a behaviour test without any additional cost because PostgreSQL is free software.

Log Monitor Server
The log monitor server monitors the operation data fromthe machinery and inserts them into PostgreSQL. The data
are received through the EPICS (experimental physics andindustrial control system) channel access protocol. The log
monitor server converts the data into character strings in an
appropriate format before insertion into PostgreSQL.

Web Application Server: Zope
Zope is a tool for developing Web applications. Users
can browse through and enter data using the user interfaceof the Web application. Zope has the following features:• Its development is also possible through the Web.
• It includes the function of a Web server.
• It is easy to handle Japanese characters on multiplatform.
Zope contains an object termed “product”, which is a kindof template of the application. The following two products
are the major components of the Zlog system.
• DA (database adapter): This is one of the products ofZope. Data exchange between Zope and PostgreSQL
occurs through the DA.
• Zlog core: This is a Web application designed at
KEKB for the operation log using the Web application
development function of Zope. Users can enter thedata in the operation log, edit it, and browse throughit using the user interfaces of this application with aWeb browser.

Figure 2: Edit interface.
of operation log records. In this interface, the latest records(maximum of 48 hours up to that point) are displayed. Inaddition, the insertion of images, such as screenshots ofoperational terminals, to the operation log is possible. The
time range of the display can be selected from the menu,
which is denoted as “Latest Time Setting” in Fig. 2. The
display is automatically updated to show the latest entries.
To prevent the modification of records that are more than
2 days old, a limit is imposed for the time range. To edit
entries older than 2 days, permission from the manager isnecessary.

Viewer Interface
Figure 3 shows a screenshot image of the viewer interface, which is a user interface for browsing through the operation log. When a user selects the date and time (in unitsof 8-h shifts) using the “Select Date” drop-down menu andpresses the “LOG DISPLAY” button, all the entries of theselected date and time are displayed. The user can selectZLOG CORE
In this section, we briefly explain the development of theinterface of the Zlog core. Any terminal in which a Web
browser is installed can be used to access the Zlog system.
Each interface can be accessed by typing its URL in theWeb browser. We can use these user interfaces in KEK
wherever a PC terminal is available.

Edit Interface
Figure 2 shows a screenshot image of the edit interface,which is a user interface for manual entry and the editing

Figure 3: Viewer interface (single).

any date without restriction. However, the user cannot edit
the entries in the viewer interface. The display of the entries is updated automatically as new entries are added.
Figure 4 shows another type of viewer interface, whichdisplays multiple operation logs in a single list. For example, in Fig. 4, the log entries of PF-AR are shown in thekhaki background and those of the KEKB are shown in theazure background. The user can select the viewing condition using the menus and buttons present in the upper partof the window. An automatic update is not available in thisinterface.

• There is little dependency on the OS of the network
terminals.
• Because the system is developed in the Web server,
no additional procedures such as data conversion arenecessary for publishing on the Web.
• The Zlog system is object oriented, and it is superior
in serviceability.
Because the Zlog system has flexible expansibility, it
has been introduced in J-PARC, the RI beam factory ofRIKEN, and the vacuum system management at KEK aswell. Therefore, we are working on the portability of eachpart of the Zlog system. It takes only a few days for porting
to other environments.
The development of the Zlog core, while simultaneously
learning Zope, was accomplished in 2 × 1.25 man-months.
The breakup of this time period is as follows:• Learning the structure, usage, and technical details ofZope was accomplished in approximately 1.5 manmonths.
• The user interfaces were developed using HTML andCSS in 1 man-month.

Figure 4: Viewer interface (multiple).

Search Interface
Figure 5 shows a screenshot image of the search interface, which is a user interface for searching for operation
log records. A keyword search is possible. The user canselect any date without restriction.

The first version of the Zlog system, which comprised minimal functions, was developed in lesser time than anticipated. Subsequently, the Zlog system has been updated
periodically.
The system continuously accumulates more than 1,500
operational event entries at KEKB and PF-AR everyday. It
is a valuable basis for the analysis of the operational efficiency. Thus, it is indispensable for KEKB and PF-AR.

ACKNOWLEDGMENTS
We would like to express our sincere thanks to Professor
T. Katoh of KEK for the encouragement.

REFERENCES[1] S. Kurokawa and E. Kikutani, “Overview of the KEKB accelerators”, Nucl. Instrum. Meth. A 499 (2003) pp.1-7.
[2] S. Kusano et al., “The Operation Logbook System atKEKB Linac and Ring”, Proceedings of ICALEPCS 2003,Gyeongju, Korea, May 2003, pp.430-432.

Figure 5: Search interface.

[3] K. Yoshii et al., “The Operator-developed Useful Tools at
KEKB Accelerator”, Proceedings of Workshop on Accelerator Operation 2003, Hayama, Japan, March 10-14, 2003,
10P2-9.
[4] < http://zope.org/ >.

MERITS OF ZLOG SYSTEMThe Zlog system enables the automatic entry of the operation log records. In addition, it has the following advantages:• Users can browse through and edit the operation log
wherever a network terminal is available. The development of the Web application is also possible fromthe network terminal.

[5] K. Yoshii et al., “Zope Based Electronic Operation Log System - Zlog”, Proceedings of the 1st Annual Meeting of Particle Accelerator Society of Japan, Funabashi, Japan, August
4-6, 2004, 5P28.