Changes

Jump to: navigation, search

SHOC

No change in size, 13:35, 22 April 2015
** For information on the script, a logfile is produced that will be in /var/log/<TELESCOPE>DataCopyLog<MMDD>-<NUM> where <TELESCOPE> is 40in or 74in <MMDD> MonthDay <NUM> the Nth time this script has been run
==== Rescuing Data====
 
Under normal operation, the system automatically updates the FITS cube header with supplementary information (filter, external trigger parameters, telescope pointing information etc.) and the moves the cube to the permanent (for the night) storage area. From time to time, it may be necessary to do this manually, using the rescue_data.py tool. In particular, if the system has frozen at the end of an acquisition, but before fixing the header and moving the data file, it will be necessary to perform this procedure. ''This procedure does NOT need to be done when stopping an acquisition, only if the interface hangs and you cannot do anything.''
* The procedure is to open a terminal and find your data in the spool directory on the instrument computer. It's stored in a directory named /data/spool/<CCYYMMDD><index>.<HHMMSS> (where index is the index, CCYYMMDD is the date and HHMMSS is the time the acquisition started). For example, /data/spool/201503250002.141026/ . The procedure is done by using ssh to connect to the SHOC host computer:
ssh shoc74in@shoc74in.suth.saao.ac.za
or
ssh shoc40in@shoc74in.suth.saao.ac.za
When prompted for the password, use the password for the 74in or 40in user. Then go to the directory containing the spooled files:
cd /data/spool
ls -l
cd <CCYYMMDD><index>.<HHMMSS>
ls -l
* There should be files named data.fits and info.txt
* The info.txt file contains the supplementary information.
* Run the rescue utility: type
sudo rescue_data.py
and then answer the questions as prompted. You'll be prompted for a password, use the password for the user you logged in as.
* The telescope is the name of the telescope being used; either 40in or 74in.
* The instrument will be one of shocnawe (SHA) or shocndisbelief (SHD). These are used to create the directory and filename in the /data directory. The directory will be of the form /data/<telescope>/<instrument>/<YYYY>/<MMDD>, and the file of the form <instrument>_<YYYYMMDD>.<index>.fits. From this, the instrument name can be determined. At the moment, SHA is the SHOC instrument mounted on the 74inch and SHD is on the 40in.
* You will be prompted for an index to use. NB: '''make sure there is no existing file with the same index that will be overwritten''' The script will scan the target directory and list the existing files. Choose and index which isn't used(one option is to use an index like 3a , if index 3 exists). In other words, if files such as SHA_20150403.0004.fits and SHA_20150403.0005.fits, choosing either index 4 or 5 will result in that file being overwritten. If you choose as index 4a or 5a, the files will not be overwritten.
====FITS Header Keywords====
*** The filter wheel needs to be reinitialized. Go to the filter wheel tab, click the initialize button under the active wheel(s).esh the camera tab in the browser window
*'''Camera tab is frozen:''' Occasionally (often at the start of the night) the first acquisition causes the camera tab to become unresponsive and 'freeze up'. The solution to this is to restart the services, as described above, then refresh the browser window and try again to restart the camera. This may need to be repeated several times before the camera starts.
==== Rescuing Data====
 
Under normal operation, the system automatically updates the FITS cube header with supplementary information (filter, external trigger parameters, telescope pointing information etc.) and the moves the cube to the permanent (for the night) storage area. From time to time, it may be necessary to do this manually, using the rescue_data.py tool. In particular, if the system has frozen at the end of an acquisition, but before fixing the header and moving the data file, it will be necessary to perform this procedure. ''This procedure does NOT need to be done when stopping an acquisition, only if the interface hangs and you cannot do anything.''
* The procedure is to open a terminal and find your data in the spool directory on the instrument computer. It's stored in a directory named /data/spool/<CCYYMMDD><index>.<HHMMSS> (where index is the index, CCYYMMDD is the date and HHMMSS is the time the acquisition started). For example, /data/spool/201503250002.141026/ . The procedure is done by using ssh to connect to the SHOC host computer:
ssh shoc74in@shoc74in.suth.saao.ac.za
or
ssh shoc40in@shoc74in.suth.saao.ac.za
When prompted for the password, use the password for the 74in or 40in user. Then go to the directory containing the spooled files:
cd /data/spool
ls -l
cd <CCYYMMDD><index>.<HHMMSS>
ls -l
* There should be files named data.fits and info.txt
* The info.txt file contains the supplementary information.
* Run the rescue utility: type
sudo rescue_data.py
and then answer the questions as prompted. You'll be prompted for a password, use the password for the user you logged in as.
* The telescope is the name of the telescope being used; either 40in or 74in.
* The instrument will be one of shocnawe (SHA) or shocndisbelief (SHD). These are used to create the directory and filename in the /data directory. The directory will be of the form /data/<telescope>/<instrument>/<YYYY>/<MMDD>, and the file of the form <instrument>_<YYYYMMDD>.<index>.fits. From this, the instrument name can be determined. At the moment, SHA is the SHOC instrument mounted on the 74inch and SHD is on the 40in.
* You will be prompted for an index to use. NB: '''make sure there is no existing file with the same index that will be overwritten''' The script will scan the target directory and list the existing files. Choose and index which isn't used(one option is to use an index like 3a , if index 3 exists). In other words, if files such as SHA_20150403.0004.fits and SHA_20150403.0005.fits, choosing either index 4 or 5 will result in that file being overwritten. If you choose as index 4a or 5a, the files will not be overwritten.
== Technician's guide ==
214
edits