Craig's /mdisw/bin Programs --------------------------- ----------------------------------------------------------------------------- LOGGING ROUTINES add2log Main input routine for the ops log. Digests its input and sends it to the EGSE and to the local opslog. Supports remote-host logging via the mail gateway. opslog Prints out the last few days' worth of operators' log. add2log.email (I think SDW wrote this) Version of add2log that accepts email rather than normal log messages. I think mail2log is used instead. gselog Prints out GSE log messages on the standard output (not to be confused with "opslog", which prints only operator log messages). mail2log Front end for add2log for incoming mail messages. ----------------------------------------------------------------------------- GENERAL FILE MANAGEMENT UTILITIES bailey Directory watcher. Useful for watching a directory periodically to see if anything changes. Used by pavlov and dinnerbell. ("Bailey" was the name of my neighbors' rather barky dog). This gets used by lots of items that need to do something when a file gets put in a magic place. pavlov Bailey's trainer. Watches a directory and executes a command on each new file. Like bailey, pavlov is a polling program -- you call it once in a while and it does anything that needs doing, then exits. monthly-archive Moves old files from a directory into monthly subdirectories. Used to keep the opslogs (and some other bunches of files) orderly. Often invoked by cron; can be useful from the command line too. ---------------------------------------------------------------------------- CRON TASKS dinnerbell Invokes pavlov to do processing of ftp'ed files from the ECS. Some telemetry comes over a socket straight into the egse; other stuff gets sent in as ftp'ed files. Dinnerbell manages the whole telemetry ingestion process. qproc Manage a list of jobs, running them one at a time till they're done. Used for the mdi cron jobs. ----------------------------------------------------------------------------- CFL FILE MANAGEMENT certify Obsolete. Certify a command file as ready for uplink. freeze Puts version numbers on a CFL file -- checks it into the /mdisw/cfl tree. Easy in concept, very complex to implement, because I figured it should be smart enough to know when anything changes, and should not increment version numbers unless something did change. Mons's first request was for an option to force a new version number, obviating about three weeks' worth of my time... unfreeze Copies (and unversions) a set of files from the main CFL workspace into a local development hierarchy purge Clean out old versions of files from a CFL directory. This vacuums up all the old and obsolete versions and sticks them in the directory called +old+. It takes a while, because it has a somewhat conservative definition of "obsolete". If foo_v02 is the latest foo version, and foo_v02 calls bar_v01, then bar_v01 is current even if bar_v02 exists. sync_cfl Synchronizes CFL trees. Run by cron, but can also be useful from the command line. Designed to be rather conservative, sync_cfl generally just tells you what it wants to do, rather than just doing it. cfl_cp Just like the UNIX cp, but for fascist-file-manager directories. You can use it on regular files too. cfl_mv Just like the UNIX mv, but for fascist-file-manager directories. This file should be identical to cfl_cp. cfl_online This was Mons-code, designed to thwart the protocol we worked out for the freeze/certify regimen. Mons preferred to shoot from the hip, freezing and certifying a piece of code in one swell foop. Now it just calls freeze, because certify is retired. fix-source-line Each .src file contains a "source" line that seems to be meant to point to the file itself but in practice points off in some random place. You say "fix-source-line foo" and foo's source line gets fixed to point to foo itself. ----------------------------------------------------------------------------- COMMANDING UTILITIES checkpoint This is the basic EGSE-program-fixer-upper, designed to use the queueing support that rogerc wrote in to EGSE. Without checkpoint, command loads take between 2 and 10 times longer to run. You run "checkpoint ..." and get out q_file1, q_file2, etc. latest Given the name of a CFL file (without version number), returns the latest version of the file. For example, "latest runstr". nrt-est Estimates the amount of time it will take a CFL file to run. (eg "nrt-est runstr" or "nrt-est q_runstr"). opend Causes a new decommed-160kb telemetry file to be opened. This is the same as typing "open d" to the EGSE. make_loads Wrapper around make_load. More user-friendly. Used to convert CFL files into delayed or background-queue command loads. cmdct Count the number of commands in a CFL source file. Sometimes the FOT wants to know. Recursively descends into called source files, so you get the real number of commands. whatcmds Like cmdct whatpcmds Like cmdct, but for TSTOL procedures whatsrc Prints out the calling hierarchy of a CFL command file (eg "whatsrc q_runstr_v09") ----------------------------------------------------------------------------- SCHEDULING UTILITIES contacts Quick hack to use the /mdisw/plan/ecs files -- you say, eg, "contacts 9905" and the routine spits out a list of all the time intervals during May, 1999 in which we'll be in contact. inls Produce a listing of current or recent instances. This is actually useful at the command line. It's usually invoked by the cgi scripts in the planning page. inci Check in an instance (the instance comes in on the standard input). Used by ined, but accessible by command-line (if you want to). inrgen Regenerate the instance registry, in case it get corrupted. This will take a while -- inrgen pages through the entire filesystem containing old instances, generating a new registry line for each instance. innewno Returns a unique instance number. This is not useful from the command line -- it's called from the ined CGI editor. retrieve-dsn Gets the latest DSN schedule information from the official ftp site. Called by update-dsn-schedule. update-dsn-schedule Front end for retrieve-dsn. Called by cron; can be useful from the command line too. digestify-dsn Ingest a DSN style contacts file in to the /mdisw/plan/ecs contact-time database digestify-ecs Ingest an ECS style contacts file into the /mdisw/plan/ecs contact-time database. ftper This routine gets called by /usr/lib/aliases when an FTP error message from the ECS get sent to the ecs-ftp alias. It tries to retrieve the file "manually", and sends an error message to mdi-ops if it can't. getkaps Retrieves KAPs from the ECS. This was used for qdiap, the precursor to makeiap. I don't know whether Chris ended up using it or not. ----------------------------------------------------------------------------- MONITORING UTILITIES monseq Monitors the sequence-ID field coming down the HK TM stream; tells you what the DEP thinks it's doing. xmonsci5k Fire up a window that monitors the sci5k screen and displays the latest LOI images. xmonseq Fire up a window with monseq in it. xmonlog Fire up a window that monitors the last few days of opslog, continuously. ----------------------------------------------------------------------------- GENERAL UTILITIES xutc Fires up a digital local/utc timeclock clctl clctl and CLCTL reverse the order of the CAPS-LOCK and CLCTL CTRL keys on the keyboard. They're identical -- it's just that, when you accidentally hit CAPS-LOCK you're more likely to type CLCTL than clctl! This is to solve the problem that the SGIs and the NCDs have opposite layouts -- that confuses a touchtypist like me. rxt Fire up a new window with a shell session on another machine. Stands for "Remote X Terminal". Uses ssh, telnet, or direct rsh. Example: "rxt urania" xalert Print some text in a brightly-colored window, and wait until it gets deleted. This is useful for getting a message to someone using an X screen somewhere else.