Elixir Realtime Systems
There are several Elixir systems which process and display data in real-time during observations. This page summarizes the relevant process, the machines where they are located, and support information.


Synchronous Processes
elixir.fork select analysis for image director (endgo) session host
getseeing measure image quality elixir.fork wekiu
getfocus generate focus plot elixir.fork wekiu
mkjpeg create binned greyscale image elixir.fork wekiu

Xvnc (summit) X server wekiu
Xvnc (waimea) X server naio
ert waimea elixir realtime jobs naio
srt skyprobe plot generation wekiu
skyprobed skyprobe image acquisition wekiu
apache Elixir web server ulu

Waimea Realtime Jobs (from ert)
elixir imstats basic image statistics naio (distributed)
elixir sextract detailed image analysis naio (distributed)
gettemps extract probe data naio
el_plots generate elixir plots naio
elixir.link gather new images naio

Synchronous Processes for Images

Every image which is obtained by the relevant cameras (CFH12K) are passed to an elixir module which in turn runs one of several analysis jobs on the image. These jobs are synchronous in the sense that they are triggered by the acquisition of the image and run immediately. In addition, this set of jobs run completely at the summit with as few interactions with the Waimea computers as possible.

elixir.fork : NEO calls the elixir.fork command at the end of every exposure. This command is passed the relevant filename for the current exposure, which is in the form /complete/path/filename.fits for MEF images, and /complete/path/filename (a directory) in the case of SPLIT images. Based on the image type, elixir.fork calls several different possible commands, launching them remotely on specific machines. The available commands, with the appropriate image type in parenthesis, are: getseeing (OBJECT), getfocus (FOCUS) and mkjpeg (OBJECT). The elixir.grab function has been deprecated.

getseeing : this process calculates the image quality and the sky level for chip 03, and sends the results to the elixir display tool 'edisp' by writing the seeing value in a specific file read by edisp. It also sends the result to the QSO database.

getfocus : this process analyses a focus image and creates a plot of the focus vs image quality for four specified chip (01, 04, 07, 10). The plot is made available to edisp for display. getfocus depends on a functioning Xvnc display server at the summit (XHOST.SUMMIT = wekiu).

mkjpeg : this process generates a greyscale image of the current frame, and makes it available to edisp. mkjpeg depends on a functioning Xvnc display server at the summit (XHOST.SUMMIT = wekiu).

skyprobed : skyprobed is daemon based on the elixir 'nightd' daemon and controls the skyprobe camera. Like all 'nightd' daemons, it has functions defined for the start of the night, for the end of the night, and repeated functions for the middle of the night. At the start of the night, is issues a command which cools the camera to a specified temperature. During the night, once every minute, it takes an image which is saved in a file with a name based on the time and date; the file is then passed to the elixir processing system. At the end of the night, it sends a command to let the camera warm up.

relevant functions:
 - sp_expose
 - sp_ccdcontrol
 - /cfht/bin/tcsh
 - /cfht/bin/loggerh
 - spphot

Waimea to Summit

The Elixir system receives images from CFH12K, CFHT-IR (and eventually other cameras) via the archive system. The archive system copies the images to data partitions in Waimea, ensures that the image is written to tape, and distributes the image to a variety of systems, including Elixir. For Elixir, a link to the image is placed in a specific directory. Elixir is responsible for identifying new links, creating a reference of its own, and removing the link.

In Waimea

The bulk of the Elixir analysis and data quality control occurs on the cluster in Waimea. During a camera run, there are a variety of processes which happen in semi-real time. In order for these systems to run, ert : the Elixir RealTime daemon, ert is based on the 'nightd' daemon and runs a variety of systems on a regular basis. There is a sequence of programs executed at the beginning of each night. These programs define the camera and runid for the current night and initialize the various directories and files if needed. During the night, ert runs certain functions on a regular basis to update the elixir plots, or to

sequence of events:
mkrun At the beginning of the night, ert runs a process (el_plots init) which initializes the elixir plotting system. In practice this simply checks if the Xvnc is running and writes an error to the logfile if not. In addition, ert runs a process (elixir.reload) which tells the imstats and sextract elixir systems to reload their configuration files. If these processes are not running, the command starts up these elixirs. During the night, ert runs three main functions once every 6 minutes. First, it runs the 'gettemps' function which extracts specific probes from the data logger for the current night. Second, it runs the elixir plotter system which generates several plots based on the current night's image statistics. Third, it runs the elixir.link system, which searches the archive link directory and identifies new images for the Elixir system. At the end of the night, ert launches the mkdetrend auto run system to generate the latest detrend report. It also launches the end-of-night routine for the plotting system, which currently does nothing, but could copy the plots to an archive, for example.

relevant functions:
 - gettemps
 - el_plots
 - elixir.link
 - elixir.reload
 - elixir.launch

srt : the Skyprobe RealTime daemon, src is based on the 'nightd' daemon and generates the plots for skyprobe during the night. At the start of the night, it tests the Xvnc. Every 300 seconds during the night, it generates the standard skyprobe plot of the night and past few hours of data. At the end of the night, it saves the plot in the archive directory.

Xvnc : there are Xvnc daemons running on a machine at the summit (wekiu) and in Waimea (koa) which provide a guaranteed 16bit X server to processes which need an X server. The vnc is running as user 'cfh12k'. Test that a particular Xvnc is running with the command 'xdpyinfo':
 xdpyinfo -display wekiu:1
 [lots of stuff ending with:]
     visual id:    0x22
     class:    TrueColor
     depth:    16 planes
     available colormap entries:    64 per subfield
     red, green, blue masks:    0xf800, 0x7e0, 0x1f
     significant bits in color specification:    8 bits
If a vnc crashes, log into the relevant machine as user cfh12k, and issue the command 'vncstart'. This will kill off the existing vnc, if it is hung, remove the lock files, and start a new vnc:
 random: rsh -l cfh12k wekiu
 [cfh12k@wekiu:~/] vncstart
 Killing Xvnc process ID 548
 Couldn't start Xvnc; trying default font path.
 Please set correct fontPath in the vncserver script.
 New 'X' desktop is wekiu.cfht.hawaii.edu:1
 Starting applications specified in /h/cfh12k/.vnc/xstartup
 Log file is /h/cfh12k/.vnc/wekiu.cfht.hawaii.edu:1.log
Note that the fontPath error is not a problem.

apache : the apache web server is used as a interface to the elixir detrend & fringe creation systems. The server runs on koa.