Writing ASP/GASP data to disk

These are Rob's instructions for writing GASP data to disk, specifically for the case of 0737-3039 observations.

GASP INSTRUCTIONS FOR OBSERVING 0737 AND WRITING TO DISK

Basically for gasp recording to disk, it's the same as real time, except a couple of commands are different (and you don't have to worry about polycos). I've put things into scripts, so hopefully it will be a bit more easy-going. Remember to run 'stop_asp' liberally between scans if you like, and make sure the nodes get a couple minutes to relax between scans as well. Also, we will be stopping and starting new scans for each eclipse, and after each eclipse. More on that below.

I will assume you have setup the IFLO already so that gasp has power going to it. But an important thing to remember is that you make sure that the cal is OFF before you setup things up.

First, open maybe 3 xterms.

SET LEVELS ON GASP:

In one of the xterms, run 'ssh -l root cpci' and then run rms. This will show you the power levels for each polarization, as well as the suggested change in attenuator setting to get the levels to an optimal 60-70.

There are 4 columns:

-- the first two correspond to one polarization, controlled by converter rack module 11
-- the second two columns correspond to the other polarization, controlled by converter rack module 15.

You can tell the operator to adjust the attenuator setting in either converter rack module to change the power levels coming to gasp. The goal is to try to get the levels as close to 60-70 as possible. if they're a bit off that's ok, but *most importantly*, get the two polarizations to have approximately the same levels.

Gasp also now has attenuators that can be set from cpci (This can help alleviate the tendency to need very very large attenuator settings in the convertor rack.):

-- check current gain with "read_gain"
-- "set_gain (0/1) (dB)" will set the gain in poln 0/1 to your given number in dB. Range is -18.5 to +25.5 dB.

Now that you have levels set the way you like, onto the data taking.

PLEASE make sure you are in the correct directory for taking data:

go to /home/gasp/data/GBT06B-018/
type 'mkdir '
(see the directories in there to see how I've named them)

This is the directory from which you will be running the datataking routines and scripts.

CAL DATA:

Turn cals ON.
run 'cal_0737_run $freq' or
'cal_1442_off_run $freq' or
'cal_1442_on_run $freq'

Depending on which source you're taking a cal, $freq is 820 or 1400, depending on the reciever you're using.

run 'stat_msg' in another window. this is important: the scan has started once each dataserver has reported back with the MJD. This MJD *must* be precisely the same between all dataservers.

-- If it is, then good, let the scan go.
-- If not, then cancel the scan by typing 'stop_asp' in any gasp xterm, or by ctrl-c'ing the scan in the window you ran the script. ctrl-c out of stat_msg. wait a minute. start scan again, again making sure of the start MJDs.

It is rare that the MJD don't match, but it does happen on occasion.

Again, remember to run all these from the datataking directory.

The scan will produce 2 30-second integrations, then quit.

Turn cals OFF.

0737 WRITE TO DISK:

The config files are in the directory:

/home/gasp/config/GBT06B-018/$freq

where $freq = 820 or 1400.

You will first run a setup script. These scripts are called:

'record_setup_data'
'record_setup_data.cgsr'
'record_setup_data2'
'record_setup_data2.cgsr'

These correspond to the disk you are writing to, /data/ or /data2/, and whether you are including the cgsr nodes as well.

We'll start by taking data on /data, since it corresponds to the most nodes with writeable disks. Once it runs out of space, switch to the /data2 disk. More on that below.

Also, you should start by using the cgsr nodes, and stop once they are full. More on that below, too.

the usage for the script is:

record_setup_data obs freq

obs is the observation number (1 to 8)
freq is the observing frequency (820 or 1400 only for now)

it will not run if # args !=2 or if obs is not between 1-8 and freq is not 820 or 1400.

when you use this, just keep incrementing each time you start a new scan, even if you switch disks. This number will correspond to a subdirectory on the nodes' disks to which this raw data will be written.

Once this script is run, everything is put into place (the config files, etc.) and ready for the actual datataking to begin. To do that, follow the command sequence:

> start_record

wait till it's done, wait a few more seconds, then type

> start_ds

again, wait till it's done, wait a few more seconds, then type

> go

This will write the raw data to the nodes, until you stop it.

Again, run stat_msg in another window to see that (a) the scan has begun and (b) that the MJDs for each dataserver *match*.

So to stop the recording, you type 'stop_asp'. There are two reasons to stop recording (apart from the observing time being over):

(a) you've run out of disk space and need to switch to the other disk
(b) it is time for an eclipse

SWITCHING DISKS:

We'll start by taking data on /data/. Once it runs out of space, switch to the /data2 disk.

To check the disk space situation, type 'node_disks' to check the gasp nodes, and 'cgsr_disks' to check the cgsr disks.

'node_disks' is like a df command on each node. Output is:

----> node1
/dev/hda10 233778740 158121912 75656828 68% /data
/dev/hdc1 241263968 223168396 18095572 93% /data2

----> node2
/dev/hda10 233778740 152857720 80921020 66% /data

----> node3
/dev/hda10 233778740 204021080 29757660 88% /data
/dev/hdc1 241263968 183177524 58086444 76% /data2

...etc...

/data and /data2 are the disks. when any one node gets to 100%, then you need to stop the scan and switch to the 'record_setup_data2' script.

'cgsr_disks' ouput looks like this:

----> cgsr3
/dev/md3 458242392 453114668 472252 100% /data

----> cgsr4
/dev/md3 458296528 396403592 57236904 88% /data

----> cgsr5
/dev/md3 458296528 361881764 91758732 80% /data

...etc...

(we get access to cgsr3 to cgsr20)

We only get one disk on cgsr, so when one of them gets full, you need to stop using cgsr to take data.

ECLIPSES:

You need to start a *new* scan for an eclipse (again, increasing the number in the record_setup_* script). then just let it go till the next eclipse. (or when disk space is an issue)

I will send the eclipse-scan-start-times beforehand.

ERROR CHECKING TIPS:

Only while running the cal (since it is real time), you can also run 'stat_asp' in a separate xterm, to bring up the accumulating signal. It should be an obvious cal signal with 50% duty cycle. If not, either the cals are not ON, or the power levels are too low, or else gasp isn't getting signal at all.

On your stat_msg screen, if there is a data buffer overflow, it will let you know. If this happens, stop the scan and restart it, and remember to increase the number you use in the record_setup_data/record_setup_data2 command.

To emphasize, REMEMBER to increase the obs number in the record_setup_* scripts. Otherwise the data you've taken before will be overwritten...!

I think that about covers it.


Ingrid Stairs
Last modified: Tue Aug 1 14:56:33 PDT 2006