.C~WHO.BCKWWHO.BCKBACK *.* [-]WHO.BCK/SAV SYSTEM 9khV5.3 _RTODTO::  _$1$DUA7: V5.3 ~  *[SRC.UPLOAD]ARGS.C;1+,!./ 4M-0123KPWO56@kxwG7Yjh89GHJ./*5 * ARGS.C - command line argument processing for WHO.6 * Copyright (C) Nick Brown 1991. All rights reserved. */#include climsgdef#include descrip#include jpidef#include ssdef#include syidef#include stdio#include "who.h"/*F * For the following structures, see the definition of LIB$LOOKUP_KEY. */typedef struct { char count; char string [31];} COUNTED_STRING;'#define counted(x) { (sizeof(x)-1), x }/*K * We make an array of the following structures for each qualifier keyword,) * with one element per qualifier value.J * The zeroth element contains a dummy first longword; the second longwordM * of this element is later filled in with the number of longwords remainingI * (= 2 * number of keywords). This calculation is done by counting fromH * the first element until another is found with a zero address for theL * counted_string element. The address of the second longword of the zerothD * element is passed to LIB$LOOKUP_KEY as the address of the table. */typedef struct {! COUNTED_STRING *counted_string; int value;} KEYWORD_VALUE;.static COUNTED_STRING cs_all = counted("ALL");8static COUNTED_STRING cs_authpriv = counted("AUTHPRIV");Bstatic COUNTED_STRING cs_base_priority = counted("BASE_PRIORITY");>static COUNTED_STRING cs_buffered_io = counted("BUFFERED_IO");@static COUNTED_STRING cs_connect_time = counted("CONNECT_TIME");8static COUNTED_STRING cs_cpu_time = counted("CPU_TIME");6static COUNTED_STRING cs_curpriv = counted("CURPRIV");6static COUNTED_STRING cs_defpriv = counted("DEFPRIV");:static COUNTED_STRING cs_direct_io = counted("DIRECT_IO");4static COUNTED_STRING cs_extent = counted("EXTENT");4static COUNTED_STRING cs_faults = counted("FAULTS");8static COUNTED_STRING cs_g_memory = counted("G_MEMORY");<static COUNTED_STRING cs_image_name = counted("IMAGE_NAME");,static COUNTED_STRING cs_io = counted("IO");Jstatic COUNTED_STRING cs_job_pagefilequota = counted("JOB_PAGEFILEQUOTA");4static COUNTED_STRING cs_memory = counted("MEMORY");0static COUNTED_STRING cs_mode = counted("MODE");8static COUNTED_STRING cs_nodename = counted("NODENAME");Bstatic COUNTED_STRING cs_pagefile_left = counted("PAGEFILE_LEFT");.static COUNTED_STRING cs_pid = counted("PID");@static COUNTED_STRING cs_process_name = counted("PROCESS_NAME");8static COUNTED_STRING cs_p_memory = counted("P_MEMORY");2static COUNTED_STRING cs_quota = counted("QUOTA");>static COUNTED_STRING cs_remote_port = counted("REMOTE_PORT");2static COUNTED_STRING cs_state = counted("STATE");8static COUNTED_STRING cs_terminal = counted("TERMINAL");8static COUNTED_STRING cs_username = counted("USERNAME");4static COUNTED_STRING cs_wssize = counted("WSSIZE");2static COUNTED_STRING cs_batch = counted("BATCH");8static COUNTED_STRING cs_detached = counted("DETACHED");4static COUNTED_STRING cs_dialup = counted("DIALUP");2static COUNTED_STRING cs_local = counted("LOCAL");6static COUNTED_STRING cs_network = counted("NETWORK");4static COUNTED_STRING cs_remote = counted("REMOTE");>static COUNTED_STRING cs_interactive = counted("INTERACTIVE");2static COUNTED_STRING cs_other = counted("OTHER");*static KEYWORD_VALUE field_keywords [] = { { 0, 0 }, { &cs_all, -1 }, { &cs_authpriv, f_authpriv }, { &cs_base_priority, f_prib }, { &cs_buffered_io, f_bufio },! { &cs_connect_time, f_x_conn }, { &cs_cpu_time, f_cputim }, { &cs_curpriv, f_curpriv }, { &cs_defpriv, f_defpriv }, { &cs_direct_io, f_dirio }, { &cs_extent, f_extent }, { &cs_faults, f_pageflts }, { &cs_g_memory, f_gpgcnt }, { &cs_image_name, f_x_image }, { &cs_io, f_x_io },) { &cs_job_pagefilequota, f_pgflquota }, { &cs_memory, f_x_mem }, { &cs_mode, f_mode }, { &cs_nodename, f_nodename },% { &cs_pagefile_left, f_pagfilcnt }, { &cs_pid, f_pid },! { &cs_process_name, f_prcnam }, { &cs_p_memory, f_ppgcnt }, { &cs_quota, f_quota }, { &cs_remote_port, f_remote }, { &cs_state, f_state }, { &cs_terminal, f_terminal }, { &cs_username, f_username }, { &cs_wssize, f_wssize }, { 0, 0 }};,static KEYWORD_VALUE jobtype_keywords [] = { { 0, 0 },# { &cs_all, ( (1 << JPI$K_BATCH) |& (1 << JPI$K_DETACHED) |$ (1 << JPI$K_DIALUP) |# (1 << JPI$K_LOCAL) |% (1 << JPI$K_NETWORK) |" (1 << JPI$K_REMOTE) ) },$ { &cs_batch, (1 << JPI$K_BATCH) },* { &cs_detached, (1 << JPI$K_DETACHED) },& { &cs_dialup, (1 << JPI$K_DIALUP) },$ { &cs_local, (1 << JPI$K_LOCAL) },( { &cs_network, (1 << JPI$K_NETWORK) },& { &cs_remote, (1 << JPI$K_REMOTE) }, { 0, 0 }};)static KEYWORD_VALUE mode_keywords [] = { { 0, 0 },# { &cs_all, ( (1 << JPI$K_BATCH) |) (1 << JPI$K_INTERACTIVE) |% (1 << JPI$K_NETWORK) |! (1 << JPI$K_OTHER) ) },$ { &cs_batch, (1 << JPI$K_BATCH) },0 { &cs_interactive, (1 << JPI$K_INTERACTIVE) },( { &cs_network, (1 << JPI$K_NETWORK) },$ { &cs_other, (1 << JPI$K_OTHER) }, { 0, 0 }};)static KEYWORD_VALUE sort_keywords [] = { { 0, 0 },! { &cs_connect_time, f_x_conn }, { &cs_cpu_time, f_cputim }, { &cs_faults, f_pageflts }, { &cs_image_name, f_x_image }, { &cs_io, f_x_io }, { &cs_pid, f_pid }, { &cs_username, f_username }, { 0, 0 }};C#define FIELD_NUMBER(value) (keyword_number(value, field_keywords))G#define JOBTYPE_NUMBER(value) (keyword_number(value, jobtype_keywords))A#define MODE_NUMBER(value) (keyword_number(value, mode_keywords))A#define SORT_NUMBER(value) (keyword_number(value, sort_keywords))/*; * Parse the command line arguments for the requested data. */get_args (request, report) REQUEST *request; REPORT *report;{ char value [80]; char *cp; request->nprocs = 256;4 if (my_present("MAX_PROCESSES") == CLI$_PRESENT) {= if (my_get_value("MAX_PROCESSES", value) != SS$_NORMAL) {5 panic("get_args: problem with /MAX_PROCESSES"); }* sscanf(value, "%d", &request->nprocs);/*I * If this value is too small we can get problems seeing the last record. */ if (request->nprocs < 2) { request->nprocs = 2; } }7 request->full = (my_present("FULL") == CLI$_PRESENT); request->jobtype = 0;: while (my_get_value("JOBTYPES", value) != CLI$_ABSENT) {. request->jobtype |= JOBTYPE_NUMBER(value); } request->mode = 0;7 while (my_get_value("MODES", value) != CLI$_ABSENT) {( request->mode |= MODE_NUMBER(value); } report->nfields = 0;8 while (my_get_value("FIELDS", value) != CLI$_ABSENT) {< report->fields[report->nfields++] = FIELD_NUMBER(value); }/*< * Remove any explicitly stated values from SUBTRACT_FIELDS. */A while (my_get_value("SUBTRACT_FIELDS", value) != CLI$_ABSENT) { int i; int fn; fn = FIELD_NUMBER(value);+ for (i = 0; i < report->nfields; i++) {$ if (report->fields[i] == fn) {' while (++i < report->nfields) {2 report->fields[i-1] = report->fields[i]; } --report->nfields; break; } } }/*7 * Add in any explicitly stated values from ADD_FIELDS. */< while (my_get_value("ADD_FIELDS", value) != CLI$_ABSENT) {< report->fields[report->nfields++] = FIELD_NUMBER(value); } report->highlight = 0;; while (my_get_value("HIGHLIGHT", value) != CLI$_ABSENT) {- int mask_or_number = FIELD_NUMBER(value); if (mask_or_number == -1) {) report->highlight = mask_or_number; } else {1 report->highlight |= (1 << mask_or_number); } } report->sort = 0;7 if (my_get_value("SORT_KEY", value) != CLI$_ABSENT) {& report->sort = SORT_NUMBER(value); } cp = request->username;7 if (my_get_value("USERNAME", value) != CLI$_ABSENT) { char *sp = value; while (*sp) { *cp++ = toupper(*sp++); } } *cp = '\0'; cp = request->imagename;9 if (my_get_value("IMAGE_NAME", value) != CLI$_ABSENT) { char *sp = value; while (*sp) { *cp++ = toupper(*sp++); } } *cp = '\0'; cp = request->remote;: if (my_get_value("REMOTE_PORT", value) != CLI$_ABSENT) { char *sp = value; while (*sp) { *cp++ = toupper(*sp++); } } *cp = '\0';}/*3 * Convert a keyword name to a number, via a table. */keyword_number (keyword, table) char *keyword; KEYWORD_VALUE table [];{ int key_value; $DESCRIPTOR(keyword_des, ""); int result; int count; KEYWORD_VALUE *kv;& keyword_des.dsc$a_pointer = keyword;- keyword_des.dsc$w_length = strlen(keyword);/*K * See how long the table is by counting the items with a non-zero pointer. table[0].value = 0;2 for (kv = &table[1]; kv->counted_string; kv++) { table[0].value += 2; } */ if (table[0].value == 0) {4 for (kv = &table[1]; kv->counted_string; kv++) { table[0].value += 2; } }K result = lib$lookup_key(&keyword_des, &table[0].value, &key_value, 0, 0); if (result != SS$_NORMAL) {7 panic("keyword_number: bad keyword value", result); } return key_value;}/*1 * Return the next node to be looked at, or NULL.D * If a wildcard appears, simulate the appearance of all node names. */char * get_node (){ static char value [80]; static int wild_seen = 0; static NODENAME *namep;4 if (my_get_value("NODES", value) != CLI$_ABSENT) { if (!strcmp(value, "*")) {$ static NODENAME nodename [96];& static ITEMLIST syi_items [] = {. sizeof(NODENAME), SYI$_NODENAME, 0, 0, 0, 0, 0, 0 }; if (wild_seen == 0) { NODENAME *np; int status = SS$_NORMAL; int csidadr = -1; wild_seen = 1; np = &nodename[0]; while (1) {+ syi_items[0].bufaddr = (np++)->n;C status = sys$getsyiw(0, &csidadr, 0, syi_items, 0, 0, 0);) if (status == SS$_NOMORENODE) { break; }* else if (status != SS$_NORMAL) {C panic("get_node: problem getting system info", status); } }/*$ * Finish list with an empty string. */ np->n[0] = '\0';/*H * Point static pointer behind array, as it will be incremented shortly. */! namep = &nodename[0] - 1; } }/*% * If not a wildcard, just return it. */ else { return value; } } if (wild_seen) { ++namep;+ return (namep->n[0] ? namep->n : NULL); } else { return NULL; }}/*C * Function to call cli$get_value with valid descriptor parameters. */staticmy_get_value (qualifier, value) char *qualifier; char *value;{! $DESCRIPTOR(qualifier_des, ""); $DESCRIPTOR(value_des, ""); int result; short retlen;* qualifier_des.dsc$a_pointer = qualifier;1 qualifier_des.dsc$w_length = strlen(qualifier);" value_des.dsc$a_pointer = value; value_des.dsc$w_length = 80;> result = cli$get_value(&qualifier_des, &value_des, &retlen); if (result & 1) { value[retlen] = '\0'; } return result;}/*B * Function to call cli$present with a valid descriptor parameter. */staticmy_present (qualifier) char *qualifier;{! $DESCRIPTOR(qualifier_des, ""); int result;* qualifier_des.dsc$a_pointer = qualifier;1 qualifier_des.dsc$w_length = strlen(qualifier);' result = cli$present(&qualifier_des); return result;}*[SRC.UPLOAD]IO.C;1+,./ 4F@-0123KPWO56` KlG7@jh89GHJ /* * IO.C - I/O routines for WHO.6 * Copyright (C) Nick Brown 1991. All rights reserved. */#include descrip#include iodef#include ssdef#include "who.h"/*) * Get N bytes of data from channel to P. */get_data (chan, flag, p, n) int chan; int flag; int *p; int n;{ int status; IOSB iosb;: status = sys$qiow(flag, chan, IO$_READVBLK, &iosb, 0, 0,& p, n, 0, 0, 0, 0); if (status != SS$_NORMAL) {0 panic("get_data: problem with QIO", status); }" if (iosb.status != SS$_NORMAL) {> panic("get_data: bad QIO completion status", iosb.status); }}/*F * Assign a channel to a named device (etc) and return channel number. */assign_chan (name) char *name;{ int status; int chan = 0;# static $DESCRIPTOR(name_dsc, "");@ name_dsc.dsc$w_length = strlen(name_dsc.dsc$a_pointer = name);. status = sys$assign(&name_dsc, &chan, 0, 0);9 if ((status != SS$_NORMAL) && (status != SS$_REMOTE)) {< panic("assign_chan: problem assigning channel", status); } return chan;}/*: * Send process and system data to the requesting process.B * Last process is the sysinfo and has the field x_last set to -1. */)send_info (info, request, np, chan, flag) INFO info []; REQUEST *request; int np; short chan; int flag;{ int i; SYSINFO *s; for (i = 0; i < np; i++) { PROCESS *p = &info[i]; p->x_last = 0;. send_data(chan, flag, p, sizeof(PROCESS)); } s = &info[np]; s->x_last = -1;, send_data(chan, flag, s, sizeof(SYSINFO));}/*2 * Send N bytes of data to channel, starting at P. */send_data (chan, flag, p, n) short chan; int flag; int *p; int n;{ int status; IOSB iosb;; status = sys$qiow(flag, chan, IO$_WRITEVBLK, &iosb, 0, 0,& p, n, 0, 0, 0, 0); if (status != SS$_NORMAL) {1 panic("send_data: problem with QIO", status); }" if (iosb.status != SS$_NORMAL) {? panic("send_data: bad QIO completion status", iosb.status); }}*[SRC.UPLOAD]JPI.C;1+,./ 4P-0123KPWO56`Ќy~G7 Ljh89GHJ6/*/ * JPI.C - get job/process information for WHO.6 * Copyright (C) Nick Brown 1991. All rights reserved. */#include descrip#include jpidef#include ssdef#include stdio#include syidef#include "who.h"#include "myjpidef.h"#include "pscandef.h"'#define NOT(mask) (0xffffffff ^ (mask))/*P * Update process and system data structures - returns number of processes seen.M * The number of records used is therefore 1 greater, because of system info.> * If node is non-NULL, it is for another node in the cluster. */,get_local_info (info, request, node, report) INFO info []; REQUEST *request; char *node; REPORT *report;{ int i; int context = -1; QUADWORD now; QUADWORD diff; int junk;- static int divisor = 60 * 10 * 1000 * 1000;$ static $DESCRIPTOR(node_desc, "");! struct dsc$descriptor_s *descp; int status; JPI_IOSB iosb; static PROCESS process; static short user_len; static short prcnam_len; static short imagname_len; static short term_len; static QUADWORD login_time; static char imagname [64];/*H * The next itemlist is a hack; in V5.2 and higher, we specify it as theA * GETJPI item list, and JPI "falls through" into the full list.I * This relies on VAX C putting the static lists in the same order in the * object code (ugh). */ static int mask_v52;& static ITEMLIST jpi_items_v52 [] = {/ 4, JPI$_GETJPI_CONTROL_FLAGS, &mask_v52, 0,5 REMOTE_LEN, JPI$_TT_ACCPORNAM, process.remote, 0,6 NODENAME_LEN, JPI$_NODENAME, process.nodename.n, 0 };" static ITEMLIST jpi_items [] = {3 sizeof(process.pid), JPI$_PID, &process.pid, 0,= USERNAME_LEN, JPI$_USERNAME, process.username, &user_len,: PRCNAM_LEN, JPI$_PRCNAM, &process.prcnam, &prcnam_len,6 sizeof(process.mode), JPI$_MODE, &process.mode, 0,6 sizeof(process.prib), JPI$_PRIB, &process.prib, 0,= sizeof(imagname), JPI$_IMAGNAME, imagname, &imagname_len,< sizeof(process.ppgcnt), JPI$_PPGCNT, &process.ppgcnt, 0,< sizeof(process.gpgcnt), JPI$_GPGCNT, &process.gpgcnt, 0,9 sizeof(process.bufio), JPI$_BUFIO, &process.bufio, 0,9 sizeof(process.dirio), JPI$_DIRIO, &process.dirio, 0,B sizeof(process.pageflts), JPI$_PAGEFLTS, &process.pageflts, 0,E sizeof(process.pagfilcnt), JPI$_PAGFILCNT, &process.pagfilcnt, 0,E sizeof(process.pgflquota), JPI$_PGFLQUOTA, &process.pgflquota, 0,> TERMINAL_LEN, JPI$_TERMINAL, &process.terminal, &term_len,< sizeof(process.cputim), JPI$_CPUTIM, &process.cputim, 0,< sizeof(process.wssize), JPI$_WSSIZE, &process.wssize, 0,; sizeof(process.quota), JPI$_WSQUOTA, &process.quota, 0,> sizeof(process.extent), JPI$_WSEXTENT, &process.extent, 0,? sizeof(process.jobtype), JPI$_JOBTYPE, &process.jobtype, 0,9 sizeof(process.state), JPI$_STATE, &process.state, 0,B sizeof(process.authpriv), JPI$_AUTHPRIV, &process.authpriv, 0,? sizeof(process.curpriv), JPI$_CURPRIV, &process.curpriv, 0,@ sizeof(process.defpriv), JPI$_PROCPRIV, &process.defpriv, 0,6 sizeof(login_time), JPI$_LOGINTIM, &login_time, 0, 0, 0, 0, 0 }; static SYSINFO sysinfo; static short hw_name_len;" static ITEMLIST syi_items [] = {N sizeof(sysinfo.hw_name), SYI$_NODE_HWTYPE, &sysinfo.hw_name, &hw_name_len, 0, 0, 0, 0 }; static short version_len;( static ITEMLIST syi_items_local [] = {< sizeof(sysinfo.defpri), SYI$_DEFPRI, &sysinfo.defpri, 0,K sizeof(sysinfo.swpoutpgcnt), SYI$_SWPOUTPGCNT, &sysinfo.swpoutpgcnt, 0,J sizeof(sysinfo.version), SYI$_VERSION, &sysinfo.version, &version_len, 0, 0, 0, 0 };- static ITEMLIST syi_items_local_only [] = {B sizeof(sysinfo.boottime), SYI$_BOOTTIME, &sysinfo.boottime, 0, 0, 0, 0, 0 }; ITEMLIST *jpi_item_ptr;#ifndef SYI$_HW_NAME#define SYI$_HW_NAME 4362#endif% static ITEMLIST syi_items_v5 [] = {J sizeof(sysinfo.hw_name), SYI$_HW_NAME, &sysinfo.hw_name, &hw_name_len, 0, 0, 0, 0 };2 sysinfo.boottime.lw1 = sysinfo.boottime.lw2 = 0; status = sys$gettim(&now); if (status != SS$_NORMAL) {: panic("get_local_info: problem getting time", status); }/* * First get the system info. */ if (node != NULL) {D node_desc.dsc$w_length = strlen(node_desc.dsc$a_pointer = node); descp = &node_desc; } else { descp = NULL; }/*8 * Get the info that is available for all cluster nodes. */8 status = sys$getsyiw(0, 0, descp, syi_items, 0, 0, 0); if (status != SS$_NORMAL) {A panic("get_local_info: problem getting system info", status); }/*? * Get the info that is available for the local node, but worth * collecting for all nodes. */: status = sys$getsyiw(0, 0, 0, syi_items_local, 0, 0, 0); if (status != SS$_NORMAL) {I panic("get_local_info: problem getting system info (local)", status); }/*C * Get the info that is available for the local node, but NOT worth * collecting for all nodes. */ if (descp == NULL) {A status = sys$getsyiw(0, 0, 0, syi_items_local_only, 0, 0, 0); if (status != SS$_NORMAL) {P panic("get_local_info: problem getting system info (local_only)", status); } }/*N * If we are running VMS V5 or later, get a better version of the system type. */ if (vms_vernum >= 50) {= status = sys$getsyiw(0, 0, descp, syi_items_v5, 0, 0, 0); if (status != SS$_NORMAL) {H panic("get_local_info: problem getting system info (v5)", status); } }& sysinfo.hw_name[hw_name_len] = '\0'; do {* sysinfo.version[version_len--] = '\0';0 } while (sysinfo.version[version_len] <= ' ');/*L * If we are running VMS V5.2 or later, use PROCESS_SCAN to speed things up.9 * Also specify flag to see how much we effort we put in. */ if (vms_vernum >= 52) {) context = get_context(request, node);! jpi_item_ptr = jpi_items_v52;" mask_v52 = request->jpi_flags; } else { jpi_item_ptr = jpi_items; }/*; * Remote port string is zero-terminated by system service;O * the next line just makes sure that it is terminated if it fills our buffer. */$ process.remote[REMOTE_LEN] = '\0'; i = 0; while (i < request->nprocs) {D status = sys$getjpiw(0, &context, 0, jpi_item_ptr, &iosb, 0, 0); if (status == SS$_NORMAL) { status = iosb.status; }# if (status == SS$_NOMOREPROC) { break; }' else if (status == SS$_SUSPENDED) { continue; }$ else if (status == SS$_NORMAL) {( process.username[user_len] = '\0';( process.prcnam[prcnam_len] = '\0';$ imagname[imagname_len] = '\0';B strncpy(process.x_image, filename(imagname), IMAGENAME_LEN);( process.terminal[term_len] = '\0';- if (login_time.lw1 || login_time.lw2) {8 status = lib$subx(&now, &login_time, &diff, &2);# if (status != SS$_NORMAL) {E panic("get_local_info: problem subtracting times", status); }C status = lib$ediv(&divisor, &diff, &process.x_conn, &junk);# if (status != SS$_NORMAL) {G panic("get_local_info: problem dividing difference", status); } } else { process.x_conn = -1; }) if (ok_to_use(&process, request)) {6 memcpy(&info[i++], &process, sizeof(PROCESS)); } } else {5 panic("get_local_info: GETJPI status", status); } }/*. * System info is last item to be passed back. */. memcpy(&info[i], &sysinfo, sizeof(SYSINFO)); return i;}#define FSCN$_NAME 6/*N * Return the filename component from a string (string is damaged by routine). */static filename (s) char *s;{ static char empty = '\0'; struct filelist { short length; short code; char *address; };$ static struct filelist list [] = { 0, FSCN$_NAME, 0, 0, 0, 0 }; int flags; int status;+ static struct dsc$descriptor_sd descrip =, { 0, DSC$K_DTYPE_T, DSC$K_CLASS_S, "" };; descrip.dsc$w_length = strlen(descrip.dsc$a_pointer = s);1 status = sys$filescan(&descrip, &list, &flags); if (status != SS$_NORMAL) {7 panic("filename: problem in sys$filescan", status); } if (list[0].length == 0) { list[0].address = ∅ } else {+ list[0].address[list[0].length] = '\0'; } return list[0].address;}/*< * Find out if execution mode of current process is NETWORK. */mode_is_network (){ static int mode;" static ITEMLIST jpi_items [] = {& sizeof(mode), JPI$_MODE, &mode, 0, 0, 0, 0, 0 }; int status; JPI_IOSB iosb;9 status = sys$getjpiw(0, &0, 0, jpi_items, &iosb, 0, 0); if (status == SS$_NORMAL) { status = iosb.status; } if (status == SS$_NORMAL) {# return (mode == JPI$K_NETWORK); } else { exit(status); }}#define STR$_NOMATCH 2392584#define STR$_MATCH 2393113/*7 * Return 1 if it's ok to show data about this process. */staticok_to_use (p, request) PROCESS *p; REQUEST *request;{ int i; int status;! static $DESCRIPTOR(string, "");" static $DESCRIPTOR(pattern, "");. if ((request->mode & (1 << p->mode)) == 0) { return 0; }4 if ((request->jobtype & (1 << p->jobtype)) == 0) { return 0; }/*: * If a user is specified, make sure this user matches it.L * There may be trailing spaces in the username - ignore them in the search.8 * Skip this check for VMS V5.2 and later, to save time. */4 if ((vms_vernum < 52) && (request->username[0])) { char c;' string.dsc$a_pointer = p->username;C for (i = 0; (c = string.dsc$a_pointer[i]) && (c != ' '); i++) { ;/* count non-spaces */ } string.dsc$w_length = i;M pattern.dsc$w_length = strlen(pattern.dsc$a_pointer = request->username);/ status = str$match_wild(&string, &pattern); if (status != STR$_MATCH) { return 0; } }/*@ * If an image was specified, make sure this process matches it. */ if (request->imagename[0]) {D string.dsc$w_length = strlen(string.dsc$a_pointer = p->x_image);N pattern.dsc$w_length = strlen(pattern.dsc$a_pointer = request->imagename);/ status = str$match_wild(&string, &pattern); if (status != STR$_MATCH) { return 0; } }/*E * If a remote port was specified, make sure this process matches it. */2 if ((vms_vernum > 52) && (request->remote[0])) {C string.dsc$w_length = strlen(string.dsc$a_pointer = p->remote);K pattern.dsc$w_length = strlen(pattern.dsc$a_pointer = request->remote);/ status = str$match_wild(&string, &pattern); if (status != STR$_MATCH) { return 0; } } return 1;}/** * Return PROCESS_SCAN context for search. */staticget_context (request, node) REQUEST *request; char *node;{ int i; int context;# static ITEMLIST pscan_items [40]; ITEMLIST *pip; int any; int mode; int jobtype; int status; pip = &pscan_items[0];/*" * Set up large buffer for GETJPI. */ pip->buflen = 0;( pip->code = PSCAN$_GETJPI_BUFFER_SIZE; pip->bufaddr = 2048; pip->retlen = 0;/*' * If node is specified, state it here. */ if (node != NULL) { ++pip;. pip->buflen = strlen(pip->bufaddr = node); pip->code = PSCAN$_NODENAME; pip->retlen = 0; }/*= * See which modes were specified; wind each bit out in turn. */ any = 0;< for (i = 0, mode = request->mode; mode; i++, mode >>= 1) { if (mode & 1) { any = 1; ++pip; pip->buflen = 0; pip->code = PSCAN$_MODE; pip->bufaddr = i; pip->retlen = PSCAN$M_OR; } }/* * Remove the last OR flag. */ if (any) {# pip->retlen &= NOT(PSCAN$M_OR); }/*@ * See which jobtypes were specified; wind each bit out in turn. */ any = 0;H for (i = 0, jobtype = request->jobtype; jobtype; i++, jobtype >>= 1) { if (jobtype & 1) { any = 1; ++pip; pip->buflen = 0;! pip->code = PSCAN$_JOBTYPE; pip->bufaddr = i; pip->retlen = PSCAN$M_OR; } }/* * Remove the last OR flag. */ if (any) {# pip->retlen &= NOT(PSCAN$M_OR); }/*3 * Refine the search to match a specified username.F * Since GETJPI treats the trailing spaces on usernames as significantF * characters when matching wildcards (eg, *M will not match SYSTEM),C * any wildcard has to be extended with " *" to match the trailingH * spaces. If usernames allowed embedded spaces, this would not work ! */ if (request->username[0]) {% char username [USERNAME_LEN + 3]; ++pip;( strcpy(username, request->username);2 pip->buflen = strlen(pip->bufaddr = username); pip->code = PSCAN$_USERNAME;% pip->retlen = PSCAN$M_CASE_BLIND;> if (strcspn(pip->bufaddr, "*%") != strlen(pip->bufaddr)) {& pip->retlen |= PSCAN$M_WILDCARD; strcat(username, " *"); pip->buflen += 2; } } ++pip; pip->buflen = pip->code = 0;3 status = sys$process_scan(&context, pscan_items); if (status != SS$_NORMAL) { exit(status); } return context;}*[SRC.UPLOAD]MYJPIDEF.H;1+,./ 4$~-0123KPWO56釦^G7,jh89GHJ/* * New VMS V5.2 JPI flags. */$#define JPI$_GETJPI_CONTROL_FLAGS -2 #define JPI$M_NO_TARGET_INSWAP 1#define JPI$M_NO_TARGET_AST 2$#define JPI$M_IGNORE_TARGET_STATUS 4#define JPI$_CPU_ID 807#define JPI$_STS2 808#define JPI$_NODENAME 809#define JPI$_NODE_CSID 810#define JPI$_NODE_VERSION 811#define JPI$_TT_PHYDEVNAM 812#define JPI$_TT_ACCPORNAM 813*[SRC.UPLOAD]MYPRVDEF.H;1+,./ 4-0123KPWO56@ZѬ7 jh89GHJ#define PRV$M_CMKRNL 1#define PRV$M_CMEXEC 2#define PRV$M_SYSNAM 4#define PRV$M_GRPNAM 8#define PRV$M_ALLSPOOL 16#define PRV$M_DETACH 32#define PRV$M_DIAGNOSE 64#define PRV$M_LOG_IO 128#define PRV$M_GROUP 256#define PRV$M_NOACNT 512#define PRV$M_PRMCEB 1024#define PRV$M_PRMMBX 2048#define PRV$M_PSWAPM 4096#define PRV$M_SETPRI 8192#define PRV$M_SETPRV 16384#define PRV$M_TMPMBX 32768#define PRV$M_WORLD 65536#define PRV$M_MOUNT 131072#define PRV$M_OPER 262144#define PRV$M_EXQUOTA 524288#define PRV$M_NETMBX 1048576#define PRV$M_VOLPRO 2097152#define PRV$M_PHY_IO 4194304#define PRV$M_BUGCHK 8388608#define PRV$M_PRMGBL 16777216#define PRV$M_SYSGBL 33554432#define PRV$M_PFNMAP 67108864#define PRV$M_SHMEM 134217728#define PRV$M_SYSPRV 268435456#define PRV$M_BYPASS 536870912#define PRV$M_SYSLCK 1073741824#define PRV$M_SHARE -2147483648#define PRV$M_ACNT 512#define PRV$M_ALTPRI 8192#define PRV$S_PRVDEF 5#define PRV$V_CMKRNL 0#define PRV$V_CMEXEC 1#define PRV$V_SYSNAM 2#define PRV$V_GRPNAM 3#define PRV$V_ALLSPOOL 4#define PRV$V_DETACH 5#define PRV$V_DIAGNOSE 6#define PRV$V_LOG_IO 7#define PRV$V_GROUP 8#define PRV$V_NOACNT 9#define PRV$V_PRMCEB 10#define PRV$V_PRMMBX 11#define PRV$V_PSWAPM 12#define PRV$V_SETPRI 13#define PRV$V_SETPRV 14#define PRV$V_TMPMBX 15#define PRV$V_WORLD 16#define PRV$V_MOUNT 17#define PRV$V_OPER 18#define PRV$V_EXQUOTA 19#define PRV$V_NETMBX 20#define PRV$V_VO~WHO.BCK[SRC.UPLOAD]MYPRVDEF.H;1LPRO 21#define PRV$V_PHY_IO 22#define PRV$V_BUGCHK 23#define PRV$V_PRMGBL 24#define PRV$V_SYSGBL 25#define PRV$V_PFNMAP 26#define PRV$V_SHMEM 27#define PRV$V_SYSPRV 28#define PRV$V_BYPASS 29#define PRV$V_SYSLCK 30#define PRV$V_SHARE 31#define PRV$V_UPGRADE 32#define PRV$V_DOWNGRADE 33#define PRV$V_GRPPRV 34#define PRV$V_READALL 35#define PRV$V_SECURITY 38#define PRV$V_ACNT 9#define PRV$V_ALTPRI 13*[SRC.UPLOAD]PSCANDEF.H;1+, ./ 4%j-0123KPWO565CA7.jh89GHJ#define PSCAN$_BEGIN 0#define PSCAN$_ACCOUNT 1#define PSCAN$_AUTHPRI 2#define PSCAN$_CURPRIV 3#define PSCAN$_GRP 4#define PSCAN$_HW_MODEL 5#define PSCAN$_HW_NAME 6#define PSCAN$_JOBPRCCNT 7#define PSCAN$_JOBTYPE 8#define PSCAN$_MASTER_PID 9#define PSCAN$_MEM 10#define PSCAN$_MODE 11#define PSCAN$_NODE_CSID 12#define PSCAN$_NODENAME 13#define PSCAN$_OWNER 14#define PSCAN$_PRCCNT 15#define PSCAN$_PRCNAM 16#define PSCAN$_PRI 17#define PSCAN$_PRIB 18#define PSCAN$_STATE 19#define PSCAN$_STS 20#define PSCAN$_TERMINAL 21#define PSCAN$_UIC 22#define PSCAN$_USERNAME 23$#define PSCAN$_GETJPI_BUFFER_SIZE 24#define PSCAN$_END 25#define PSCAN$k_type 129#define PSCAN$M_OR 1#define PSCAN$M_BIT_ALL 2#define PSCAN$M_BIT_ANY 4#define PSCAN$M_GEQ 8#define PSCAN$M_GTR 16#define PSCAN$M_LEQ 32#define PSCAN$M_LSS 64 #define PSCAN$M_PREFIX_MATCH 128#define PSCAN$M_WILDCARD 256#define PSCAN$M_CASE_BLIND 512#define PSCAN$M_EQL 1024#define PSCAN$M_NEQ 2048%#define PSCAN$S_ITEM_SPECIFIC_FLAGS 2#define PSCAN$V_OR 0#define PSCAN$V_BIT_ALL 1#define PSCAN$V_BIT_ANY 2#define PSCAN$V_GEQ 3#define PSCAN$V_GTR 4#define PSCAN$V_LEQ 5#define PSCAN$V_LSS 6#define PSCAN$V_PREFIX_MATCH 7#define PSCAN$V_WILDCARD 8#define PSCAN$V_CASE_BLIND 9#define PSCAN$V_EQL 10#define PSCAN$V_NEQ 11*[SRC.UPLOAD]PSTATE.H;1+,./ 46-0123KPWO56 ]A7/jh89GHJ/*, * PSTATE.H - process state definitions WHO.6 * Copyright (C) Nick Brown 1991. All rights reserved. *//*! * Definitions of process states. */#define SCH$C_COLPG 1#define SCH$C_MWAIT 2#define SCH$C_CEF 3#define SCH$C_PFW 4#define SCH$C_LEF 5#define SCH$C_LEFO 6#define SCH$C_HIB 7#define SCH$C_HIBO 8#define SCH$C_SUSP 9#define SCH$C_SUSPO 10#define SCH$C_FPG 11#define SCH$C_COM 12#define SCH$C_COMO 13#define SCH$C_CUR 14*[SRC.UPLOAD]REPORT.C;1+,./ 4Nj-0123KPWO56 }G7jh89GHJ</* * REPORT - report for WHO.6 * Copyright (C) Nick Brown 1991. All rights reserved. */#include descrip#include jpidef#include ssdef#include "who.h"#include "myprvdef.h"#include "pstate.h"#define ASCENDING 0#define DESCENDING 1%static char ascii_state [] = "XXXXX";!static char ascii_mode [] = "XX";)static char ascii_authpriv [] = "XXXXXX";(static char ascii_curpriv [] = "XXXXXX";(static char ascii_defpriv [] = "XXXXXX";extern char *state_string ();extern char *mode_string ();extern char *priv_string ();static PROCESS master;typedef struct { int number; int ptr; int *data; char *format; char *title;} FIELD;/*E * This data structure enables us to print any combination of fields.A * It contains, for each item in a PROCESS record, the following:8 * - the item number (items do not have to be in order);J * - an indication of whether the data is a (char) pointer or (int) value;E * - the address of the data (usually in a copy of a PROCESS record);6 * - the printf format string used to output the data; * - the title of the field. */static FIELD fields [] = {A f_username, 1, master.username, "%-12s", "Username ",D f_prcnam, 1, master.prcnam, "%-15s", "Process name ",= f_pid, 0, &master.pid, "%08x", " PID",8 f_prib, 0, &master.prib, "%3d", "Pri",= f_terminal, 1, master.terminal, "%-8s", "Terminal",? f_x_image, 1, &master.x_image, "%-10.10s", "Image name",E f_remote, 1, &master.remote, "%-16.16s", "Remote port ",; f_nodename, 1, &master.nodename, "%-6.6s", "Node ",9 f_ppgcnt, 0, &master.ppgcnt, "%4d", "Ppgs",9 f_gpgcnt, 0, &master.gpgcnt, "%4d", "Gpgs",: f_bufio, 0, &master.bufio, "%5d", " BIO",: f_dirio, 0, &master.dirio, "%5d", " DIO",; f_pageflts, 0, &master.pageflts, "%6d", "Faults",; f_pagfilcnt, 0, &master.pagfilcnt, "%6d", "PFleft",; f_pgflquota, 0, &master.pgflquota, "%6d", " PFquo",#define MAXCPUTIM 999999; f_cputim, 0, &master.cputim, "%6d", " CPU",9 f_wssize, 0, &master.wssize, "%4d", "WSet",9 f_quota, 0, &master.quota, "%4d", "WSQu",9 f_extent, 0, &master.extent, "%4d", "WSEx",: f_state, 1, &ascii_state, "%-5s", "State",9 f_mode, 1, &ascii_mode, "%-4s", "Mode",; f_authpriv, 1, &ascii_authpriv, "%-6s", "AutPrv",; f_curpriv, 1, &ascii_curpriv, "%-6s", "CurPrv",; f_defpriv, 1, &ascii_defpriv, "%-6s", "DefPrv",9 f_x_mem, 0, &master.x_mem, "%4d", "Tpgs",: f_x_io, 0, &master.x_io, "%5d", " IO",#define MAXCONN 99999: f_x_conn, 0, &master.x_conn, "%5d", "ConnT",2 -1, 0, 0, 0, 0 };#define BOLD "\033[1m"#define UNDER "\033[4m"#define BLINK "\033[5m"#define INVERSE "\033[7m"#define RESET "\033[0m"#define m_BOLD 1#define m_UNDER 2#define m_BLINK 4#define m_INVERSE 8/* * Produce the report. */"do_report (info, report, np, node) INFO info []; REPORT *report; int np; char *node;{ int i; int p; FIELD *fp; char line [160]; char item [80]; char *cp; int highlight_mask; int nodename_in_report; static int put_headers = 1;G SYSINFO *sysinfo = &info[np]; /* last entry in list is system info *//*B * Produce the header line, with node name, CPU type, VMS version,! * and boot time (if available).< * This is suppressed if the nodename is part of the report. */ nodename_in_report = 0;) for (i = 0; i < report->nfields; i++) {* if (report->fields[i] == f_nodename) { nodename_in_report = 1; break; } } if (!nodename_in_report) { if (node[0]) {< static char ascii_time [] = "22-JUN-1989 18:00:00.00";- static $DESCRIPTOR(timbuf, ascii_time); short timlen; int status; strcpy(line, "Node "); strcat(line, node);J sprintf(item, " - %s / VMS %s", sysinfo->hw_name, sysinfo->version); strcat(line, item);? if ((sysinfo->boottime.lw1) || (sysinfo->boottime.lw2)) {E status = sys$asctim(&timlen, &timbuf, &sysinfo->boottime, 0);# if (status != SS$_NORMAL) {> panic("do_report: problem converting time", status); }5 ascii_time[17] = '\0'; /* end with minutes */ strcat(line, " since ");! strcat(line, ascii_time); } puts(line); } if (np < 1) {$ puts("No processes selected"); return; } }/*H * Extract the item titles, only once if nodename is required in report. */ if (put_headers) { line[0] = '\0';+ for (i = 0; i < report->nfields; i++) {) fp = get_fields(report->fields[i]); if (i > 0) { strcat(line, " "); } strcat(line, fp->title); } puts(line); if (nodename_in_report) { put_headers = 0; } }/*M * Massage the data (generate total fields, convert seconds to minutes, etc).6 * Do this here in case we sort on these fields later. */ for (p = 0; p < np; p++) {# PROCESS *ip = &info[p].process; ip->cputim /= 100;! if (ip->cputim > MAXCPUTIM) { ip->cputim = MAXCPUTIM; } if (ip->x_conn > MAXCONN) { ip->x_conn = MAXCONN; }( ip->x_mem = ip->ppgcnt + ip->gpgcnt;% ip->x_io = ip->bufio + ip->dirio; }/*3 * Sort the records according to the specified key. */ if (report->sort) {! sort(info, np, report->sort); }/*" * Now output each record in turn. */ for (p = 0; p < np; p++) {/ memcpy(&master, &info[p], sizeof(PROCESS)); line[0] = '\0';+ for (i = 0; i < report->nfields; i++) {) fp = get_fields(report->fields[i]); if (i) { strcat(line, " "); }" switch (report->fields[i]) { case f_state: {: strcpy(ascii_state, state_string(master.state)); break; } case f_mode: {G strcpy(ascii_mode, mode_string(master.jobtype, master.mode)); break; } case f_authpriv: {@ strcpy(ascii_authpriv, priv_string(&master.authpriv)); break; } case f_curpriv: {> strcpy(ascii_curpriv, priv_string(&master.curpriv)); break; } case f_defpriv: {> strcpy(ascii_defpriv, priv_string(&master.defpriv)); break; } }/*) * Deal with fields we need to highlight. */ highlight_mask = 0;; if ((report->highlight) & (1 << report->fields[i])) {$ switch (report->fields[i]) { case f_prib: {3 if (master.mode == JPI$K_INTERACTIVE) {2 if (master.prib > sysinfo->defpri) {, highlight_mask |= m_INVERSE; }7 else if (master.prib < sysinfo->defpri) {* highlight_mask |= m_UNDER; } } break; } case f_wssize: {8 if (master.wssize == sysinfo->swpoutpgcnt) {' highlight_mask |= m_BOLD; } break; } }& if (highlight_mask & m_BOLD) { strcat(line, BOLD); }' if (highlight_mask & m_UNDER) { strcat(line, UNDER); }) if (highlight_mask & m_INVERSE) { strcat(line, INVERSE); } }K sprintf(item, fp->format, (fp->ptr ? (int)(fp->data) : *(fp->data))); strcat(line, item); if (highlight_mask) { strcat(line, RESET); } }/* * Strip trailing blanks. */D for (cp = &line[strlen(line)] - 1; (*cp) && (*cp <= 32); cp--) { *cp = 0; }/*) * Now we can actually output the line... */ puts(line); }}staticget_fields (f) int f;{ FIELD *fp;, for (fp = fields; fp->number >= 0; fp++) { if (fp->number == f) { return fp; } }9 panic("get_fields: unable to find specified field", 4);}/*1 * Convert a state number into a mnemonic string. */staticchar *state_string (state) int state;{ switch (state) {% case SCH$C_COLPG: return "COLPG";% case SCH$C_MWAIT: return "MWAIT";! case SCH$C_CEF: return "CEF";! case SCH$C_PFW: return "PFW";! case SCH$C_LEF: return "LEF";# case SCH$C_LEFO: return "LEFO";! case SCH$C_HIB: return "HIB";# case SCH$C_HIBO: return "HIBO";# case SCH$C_SUSP: return "SUSP";% case SCH$C_SUSPO: return "SUSPO";! case SCH$C_FPG: return "FPG";! case SCH$C_COM: return "COM";# case SCH$C_COMO: return "COMO";! case SCH$C_CUR: return "CUR";1 default: panic("state_string: bad state", 4); }}/*= * Convert a process jobtype and mode into a mnemonic string. */staticchar *mode_string (jobtype, mode) int jobtype; int mode;{ static char reply [] = " "; switch (jobtype) {/ case JPI$K_DETACHED: reply[0] = 'D'; break;. case JPI$K_NETWORK: reply[0] = 'N'; break;, case JPI$K_BATCH: reply[0] = 'B'; break;, case JPI$K_LOCAL: reply[0] = 'L'; break;- case JPI$K_DIALUP: reply[0] = 'M'; break;- case JPI$K_REMOTE: reply[0] = 'R'; break;2 default: panic("mode_string: bad jobtype", 4); } switch (mode) {. case JPI$K_NETWORK: reply[1] = 'N'; break;2 case JPI$K_INTERACTIVE: reply[1] = 'I'; break;, case JPI$K_BATCH: reply[1] = 'B'; break;, case JPI$K_OTHER: reply[1] = 'O'; break;2 default: panic("mode_string: bad jobtype", 4); } return reply;}/* * Sort the process records. */staticsort (p, np, key) PROCESS p []; int np; int key;{ int status; int i;2 static short key_buffer [5] = { 1, 0, 0, 0, 0 }; if (key == f_pid) {# key_buffer[1] = DSC$K_DTYPE_LU; key_buffer[2] = ASCENDING;8 key_buffer[3] = (char*)&master.pid - (char*)&master;' key_buffer[4] = sizeof(master.pid); } else if (key == f_pageflts) {# key_buffer[1] = DSC$K_DTYPE_LU; key_buffer[2] = DESCENDING;= key_buffer[3] = (char*)&master.pageflts - (char*)&master;, key_buffer[4] = sizeof(master.pageflts); } else if (key == f_cputim) {# key_buffer[1] = DSC$K_DTYPE_LU; key_buffer[2] = DESCENDING;; key_buffer[3] = (char*)&master.cputim - (char*)&master;* key_buffer[4] = sizeof(master.cputim); } else if (key == f_username) {" key_buffer[1] = DSC$K_DTYPE_T; key_buffer[2] = ASCENDING;5 key_buffer[3] = master.username - (char*)&master;! key_buffer[4] = USERNAME_LEN; } else if (key == f_x_image) {" key_buffer[1] = DSC$K_DTYPE_T; key_buffer[2] = ASCENDING;4 key_buffer[3] = master.x_image - (char*)&master;" key_buffer[4] = IMAGENAME_LEN; } else if (key == f_x_conn) {# key_buffer[1] = DSC$K_DTYPE_LU; key_buffer[2] = DESCENDING;; key_buffer[3] = (char*)&master.x_conn - (char*)&master;* key_buffer[4] = sizeof(master.x_conn); } else if (key == f_x_io) {# key_buffer[1] = DSC$K_DTYPE_LU; key_buffer[2] = DESCENDING;9 key_buffer[3] = (char*)&master.x_io - (char*)&master;( key_buffer[4] = sizeof(master.x_io); } else { panic("sort: bad key", 4); }M status = sor$begin_sort(key_buffer, &sizeof(PROCESS), 0, 0, 0, 0, 0, 0, 0); if (status != SS$_NORMAL) {5 panic("sort: problem in sor$begin_sort", status); } for (i = 0; i < np; i++) {3 status = sor$release_rec(recdescrip(&p[i]), 0); if (status != SS$_NORMAL) {8 panic("sort: problem in sor$release_rec", status); } } status = sor$sort_merge(0); if (status != SS$_NORMAL) {5 panic("sort: problem in sor$sort_merge", status); } for (i = 0; i < np; i++) {5 status = sor$return_rec(recdescrip(&p[i]), 0, 0); if (status != SS$_NORMAL) {7 panic("sort: problem in sor$return_rec", status); } } status = sor$end_sort(0); if (status != SS$_NORMAL) {3 panic("sort: problem in sor$end_sort", status); }}/*< * Return a descriptor from a record (for sorting purposes).! * This routine is non-reentrant. */staticrecdescrip (p) PROCESS *p;{N static struct dsc$descriptor_sd d = { 0, DSC$K_DTYPE_T, DSC$K_CLASS_S, "" };# d.dsc$w_length = sizeof(PROCESS); d.dsc$a_pointer = p; return &d;}/*L * Return 1 if a given quadword privilege mask contains the given privilege. */staticpriv_in_mask (mask, priv) QUADWORD *mask; int priv;{ if (priv >= 32) {, return (mask->lw2) & (1 << (32 - priv)); } else {% return (mask->lw1) & (1 << priv); }}/*M * Return 1 if a given quadword privilege mask contains one of the privileges) * in the input list (terminated by -1). */staticprivlist_in_mask (mask, privs) QUADWORD *mask; int *privs;{ while (*privs >= 0) {% if (priv_in_mask(mask, *privs)) { return 1; } ++privs; } return 0;}/*J * Return a string corresponding to the privilege group of the given mask. */staticchar *priv_string (mask) QUADWORD *mask;{ static int all_privs [] = {; PRV$V_BYPASS, PRV$V_CMEXEC, PRV$V_CMKRNL, PRV$V_DETACH,< PRV$V_LOG_IO, PRV$V_PFNMAP, PRV$V_PHY_IO, PRV$V_READALL,0 PRV$V_SETPRV, PRV$V_SYSNAM, PRV$V_SYSPRV, -1 }; static int files_privs [] = {2 PRV$V_DIAGNOSE, PRV$V_SYSGBL, PRV$V_VOLPRO, -1 }; static int system_privs [] = {8 PRV$V_ALTPRI, PRV$V_OPER, PRV$V_PSWAPM, PRV$V_WORLD,1 PRV$V_SECURITY, PRV$V_SHARE, PRV$V_SYSLCK, -1 }; static int devour_privs [] = {< PRV$V_ACNT, PRV$V_ALLSPOOL, PRV$V_BUGCHK, PRV$V_EXQUOTA,; PRV$V_GRPNAM, PRV$V_PRMCEB, PRV$V_PRMGBL, PRV$V_PRMMBX, PRV$V_SHMEM, -1 }; static int group_privs [] = {! PRV$V_GROUP, PRV$V_GRPPRV, -1 }; static int normal_privs [] = {/ PRV$V_MOUNT, PRV$V_NETMBX, PRV$V_TMPMBX, -1 }; typedef struct { int *privs; char *string; } PRIVS_AND_STRING;1 static PRIVS_AND_STRING privs_and_string [] = { all_privs, "All", files_privs, "Files", system_privs, "System", devour_privs, "Devour", group_privs, "Group", normal_privs, "Normal", 0, "None", };* PRIVS_AND_STRING *ps = privs_and_string; while (ps->privs) {, if (privlist_in_mask(mask, ps->privs)) { break; } ++ps; } return ps->string;}*[SRC.UPLOAD]WHO.C;1+,. / 4P -0123KPWO 56wG7 jh89GHJ/*4 * WHO - process information, possibly network-wide.6 * Copyright (C) Nick Brown 1991. All rights reserved. */#include descrip#include stdio#include ssdef#include syidef#include "who.h"#include "myjpidef.h"#define QIO_FLAG 1/* * VMS version (4.7 == 47, etc). */int vms_vernum = 0;main (){ int i; int np; int status; INFO *info; REQUEST request; REPORT report;#define VERSION_LEN 16( static char version [VERSION_LEN + 1]; static NODENAME nodename; static short version_len; static short nodename_len;" static ITEMLIST syi_items [] = {5 VERSION_LEN, SYI$_VERSION, version, &version_len,; NODENAME_LEN, SYI$_NODENAME, nodename.n, &nodename_len, 0, 0, 0, 0 };/*. * Get our system version number and nodename. */4 status = sys$getsyiw(0, 0, 0, syi_items, 0, 0, 0); if (status != SS$_NORMAL) {7 panic("main: problem getting system info", status); }< vms_vernum = (version[1] - '0') * 10 + (version[3] - '0');/*8 * We might be invoked from DCL, or as a network object. */ if (mode_is_network()) {* int net_chan = assign_chan("SYS$NET");2 waitfor_request(&request, REQ_DATA, net_chan);7 info = malloc(sizeof(INFO) * (request.nprocs + 1));. np = get_local_info(info, &request, NULL);6 send_info(info, &request, np, net_chan, QIO_FLAG);7 waitfor_request(&request, REQ_CLOSEDOWN, net_chan); } else { int n_nodes; n_nodes = 0; get_args(&request, &report);7 info = malloc(sizeof(INFO) * (request.nprocs + 1));/*M * If we are running VMS V5.2 or later, specify how much we effort we put in.J * We need not deliver an AST unless we are interested in fields which are+ * only in the process' own address space. */ if (vms_vernum >= 52) { if (request.full) {7 request.jpi_flags = JPI$M_IGNORE_TARGET_STATUS; } else { int i;0 request.jpi_flags = JPI$M_NO_TARGET_AST;. for (i = 0; i < report.nfields; i++) {1 if ( (report.fields[i] == f_defpriv)1 || (report.fields[i] == f_x_image)0 || (report.fields[i] == f_x_conn) ) {7 request.jpi_flags = JPI$M_NO_TARGET_INSWAP; break; } } } }/*> * Loop for all specified nodes; if none, use local node only. */ while (1) { char *node; int this_node;( if ((node = get_node()) == NULL) { if (n_nodes > 0) { break; } else { node = nodename.n; } } ++n_nodes;H this_node = ((!strcmp(node, nodename.n)) || (!strcmp(node, "0"))); if ( (this_node)< || ((vms_vernum >= 52) && (cluster_member(node))) ) { request.type = REQ_DATA;G np = get_local_info(info, &request, (this_node ? NULL : node)); } else { int remote_chan; char task [80]; strcpy(task, node);' strcat(task, "::\"TASK=WHO\"");( remote_chan = assign_chan(task); request.type = REQ_DATA;D send_data(remote_chan, QIO_FLAG, &request, sizeof(REQUEST));0 np = get_remote_info(info, remote_chan);% request.type = REQ_CLOSEDOWN;D send_data(remote_chan, QIO_FLAG, &request, sizeof(REQUEST)); }) do_report(info, &report, np, node); } }}/*6 * Wait for a particular request from another process. */%waitfor_request (request, type, chan) REQUEST *request; int type; int chan;{5 get_data(chan, QIO_FLAG, request, sizeof(REQUEST)); if (request->type != type) {2 panic("waitfor_request: bad request type", 4); }}/*P * Get data about processes and system on a remote node - returns process count.A * Assumes DECnet channel is already opened, and request is sent. */static#get_remote_info (info, remote_chan) INFO info []; int remote_chan;{ int np; for (np = 0; ; np++) { PROCESS *p = &info[np];5 get_data(remote_chan, QIO_FLAG, p, sizeof(INFO)); if (p->x_last) { break; } } return np;}/* * General crash routine. */ panic (s, i) char *s; int i;{) fprintf(stderr, "who: panic: %s\n", s); exit(i);}/*7 * Return 1 if node is a member of the current cluster. */cluster_member (node){ static char member;$ static $DESCRIPTOR(node_desc, ""); static short member_len;" static ITEMLIST syi_items [] = {> sizeof(member), SYI$_CLUSTER_MEMBER, &member, &member_len, 0, 0, 0, 0 }; int status;B node_desc.dsc$w_length = strlen(node_desc.dsc$a_pointer = node);= status = sys$getsyiw(0, 0, &node_desc, syi_items, 0, 0, 0);! if (status == SS$_NOSUCHNODE) { member = 0; }" else if (status != SS$_NORMAL) {A panic("cluster_member: problem getting system info", status); } return (member & 1);}*[SRC.UPLOAD]WHO.CLD;1+,./ 47-0123KPWO56$#wG7`Ɂjh89GHJ DEFINE VERB WHO IMAGE "WHO" QUALIFIER MAX_PROCESSES NONNEGATABLE$ VALUE (TYPE=$NUMBER) QUALIFIER FULL# QUALIFIER JOBTYPES, DEFAULT+ VALUE (TYPE=JOB_TYPE, LIST) QUALIFIER MODES, DEFAULT, VALUE (TYPE=MODE_TYPE, LIST)! QUALIFIER FIELDS, DEFAULT7 VALUE (TYPE=FIELD_TYPE, LIST, REQUIRED) QUALIFIER ADD_FIELDS7 VALUE (TYPE=FIELD_TYPE, LIST, REQUIRED)! QUALIFIER SUBTRACT_FIELDS7 VALUE (TYPE=FIELD_TYPE, LIST, REQUIRED) QUALIFIER HIGHLIGHT1 VALUE (TYPE=HIGHLIGHT_TYPE, LIST)# QUALIFIER SORT_KEY, DEFAULT& VALUE (TYPE=SORT_TYPE) QUALIFIER USERNAME VALUE (REQUIRED) QUALIFIER IMAGE_NAME VALUE (REQUIRED) QUALIFIER REMOTE_PORT VALUE (REQUIRED) QUALIFIER NODES VALUE (LIST)DEFINE TYPE JOB_TYPE KEYWORD DETACHED KEYWORD NETWORK KEYWORD BATCH KEYWORD LOCAL KEYWORD DIALUP KEYWORD REMOTE KEYWORD ALL, DEFAULTDEFINE TYPE MODE_TYPE KEYWORD OTHER KEYWORD NETWORK KEYWORD BATCH$ KEYWORD INTERACTIVE, DEFAULT KEYWORD ALLDEFINE TYPE FIELD_TYPE! KEYWORD USERNAME, DEFAULT% KEYWORD PROCESS_NAME, DEFAULT KEYWORD PID, DEFAULT& KEYWORD BASE_PRIORITY, DEFAULT! KEYWORD TERMINAL, DEFAULT KEYWORD MEMORY KEYWORD P_MEMORY KEYWORD G_MEMORY KEYWORD IO KEYWORD BUFFERED_IO KEYWORD DIRECT_IO KEYWORD FAULTS! KEYWORD CPU_TIME, DEFAULT KEYWORD CONNECT_TIME KEYWORD WSSIZE, DEFAULT KEYWORD QUOTA KEYWORD EXTENT KEYWORD STATE# KEYWORD IMAGE_NAME, DEFAULT! KEYWORD JOB_PAGEFILEQUOTA KEYWORD PAGEFILE_LEFT KEYWORD REMOTE_PORT KEYWORD NODENAME KEYWORD MODE KEYWORD AUTHPRIV KEYWORD CURPRIV KEYWORD DEFPRIVDEFINE TYPE HIGHLIGHT_TYPE KEYWORD ALL, DEFAULT KEYWORD BASE_PRIORITY KEYWORD WSSIZEDEFINE TYPE SORT_TYPE! KEYWORD USERNAME, DEFAULT KEYWORD PID KEYWORD FAULTS KEYWORD CPU_TIME KEYWORD CONNECT_TIME KEYWORD IO KEYWORD IMAGE_NAME*[SRC.UPLOAD]WHO.EXE;1+,.$/ 4$$-0123 KPWO$56aG7jh89GHJ0DX0205(ZGB WHOV1.0eZG05-05! " ? ! VAXCRTL_001! LIBRTL_001! MTHRTL_001 b! SORTSHR_001 ;!  LIBRTL2_001main: problem getting system infoSYS$NET0::"TASK=WHO"waitfor_request: bad request typewho: panic: %s cluster_member: problem getting system infoMAX_PROCESSESMAX_PROCESSESget_args: problem with /MAX_PROCESSES%dFULLJOBTYPESMODESFIELDSSUBTRACT_FIELDSADD_FIELDSHIGHLIGHTSORT_KEYUSERNAMEIMAGE_NAMEREMOTE_PORTkeyword_number: bad keyword valueNODES*get_node: problem getting system info%-12sUsername %-15sProcess name %08x PID%3dPri%-8sTerminal%-10.10sImage name%-16.16sRemote port %-6.6sNode %4dPpgs%4dGpgs%5d BIO%5d DIO%6dFaults%6dPFleft%6d PFquo%6d CPU%4dWSet%4dWSQu%4dWSEx%-5sState%-4sMode%-6sAutPrv%-6sCurPrv%-6sDefPrv%4dTpgs%5d IO%5dConnTNode - %s / VMS %sdo_report: problem converting time since No processes selected get_fields: unable to find specified fieldCOLPGMWAITCEFPFWLEFLEFOHIBHIBOSUSPSUSPOFPGCOMCOMOCURstate_string: bad statemode_string: bad jobtypemode_string: bad jobtypesort: bad keysort: problem in sor$begin_sortsort: problem in sor$release_recsort: problem in sor$sort_mergesort: problem in sor$return_recsort: problem in sor$end_sortAllFilesSystemDevourGroupNormalNoneget_data: problem with QIOget_data: bad QIO completion statusassign_chan: problem assigning channelsend_data: problem with QIOsend_data: bad QIO completion statusget_local_info: problem getting timeget_local_info: problem getting system infoget_local_info: problem getting system info (local)get_local_info: problem getting system info (local_only)get_local_info: problem getting system info (v5)get_local_info: problem subtracting timesget_local_info: problem dividing differenceget_local_info: GETJPI statusfilename: problem in sys$filescan*% * B 1 D kj t ALLAUTHPRIV BASE_PRIORITY BUFFERED_IO CONNECT_TIMECPU_TIMECURPRIVDEFPRIV DIRECT_IOEXTENTFAULTSG_MEMORY IMAGE_NAMEIOJOB_PAGEFILEQUOTAMEMORYMODENODENAME PAGEFILE_LEFTPID PROCESS_NAMEP_MEMORYQUOTA REMOTE_PORTSTATETERMINALUSERNAMEWSSIZEBATCHDETACHEDDIALUPLOCALNETWORKREMOTE INTERACTIVEOTHER    0 P p    0 P p     0 P p      ? 0 P p        0  0   RX~WHO.B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+,. / 4L -0123KPWO56 4^~G7?kjh89GHJ/*- * WHO.H - layout of data structures for WHO.6 * Copyright (C) Nick Brown 1991. All rights reserved. */#define NODENAME_LEN 15#define IMAGENAME_LEN 16#define PRCNAM_LEN 16#define REMOTE_LEN 16#define TERMINAL_LEN 10#define USERNAME_LEN 12typedef struct { int lw1; int lw2; } QUADWORD;typedef struct { char n [NODENAME_LEN + 1]; } NODENAME;/*6 * Information that may be gathered about one process.L * Fields beginning with x_ are derived, not obtained directly from $GETJPI. */typedef struct {; int x_last; /* flag for transmission */ int pid; int mode; int jobtype;# char username [USERNAME_LEN + 1]; char prcnam [PRCNAM_LEN]; int prib; int ppgcnt; int gpgcnt; int bufio; int dirio; int pageflts; int pagfilcnt; int pgflquota; char terminal [TERMINAL_LEN]; int cputim; int wssize; int quota; int extent; int state; QUADWORD authpriv; QUADWORD curpriv; QUADWORD defpriv;6 char remote [REMOTE_LEN + 1]; /* remote port name */ NODENAME nodename;J char x_image [IMAGENAME_LEN + 1]; /* filename part only of image name */F int x_mem; /* working set size (ppgcnt+gpgcnt) */= int x_io; /* total IOs (bufio+dirio) */2 int x_conn; /* connect time */ } PROCESS;/*C * Information gathered about the system, sent after all processes. */typedef struct {; int x_last; /* flag for transmission */ int defpri; int swpoutpgcnt; char version [9]; char hw_name [32]; QUADWORD boottime; } SYSINFO;typedef union { PROCESS process; SYSINFO sysinfo;} INFO;/*/ * Request codes for data from network partner. */#define REQ_DATA 110#define REQ_CLOSEDOWN 111typedef struct { int type; int jobtype; int mode; int nprocs; int full; int jpi_flags;# char username [USERNAME_LEN + 1];% char imagename [IMAGENAME_LEN + 1]; char remote [REMOTE_LEN + 1]; } REQUEST;/*) * Numbers of requested fields in report. */#define f_username 1#define f_prcnam 2#define f_pid 3#define f_prib 4#define f_terminal 5#define f_ppgcnt 6#define f_gpgcnt 7#define f_bufio 8#define f_dirio 9#define f_pageflts 10#define f_pagfilcnt 11#define f_pgflquota 12#define f_cputim 13#define f_wssize 14#define f_quota 15#define f_extent 16#define f_state 17#define f_mode 18#define f_authpriv 19#define f_curpriv 20#define f_defpriv 21#define f_remote 22#define f_nodename 23#define f_x_image 24#define f_x_mem 25#define f_x_io 26#define f_x_conn 27#define f_SIZE 27typedef struct { int report; int highlight; int sort; int nfields; int fields [f_SIZE]; } REPORT;/* * I/O status block definitions. */typedef struct { short status; short count; int sender;} IOSB;typedef struct { int status; int reserved; } JPI_IOSB;/*@ * Itemlist used for passing parameters to $GETJPI (and others). */typedef struct { short buflen; short code; int bufaddr; int retlen; } ITEMLIST;/* * Global data in WHO.C. */extern int vms_vernum;*[SRC.UPLOAD]WHO.HLP;2+,./ 4M-0123KPWO56@|6 b7J CONNECT_TIME JPI$_LOGINTIM - current time;7 reported in minutes.. AUTHPRIV JPI$_AUTHPRIV- CURPRIV JPI$_CURPRIV. DEFPRIV JPI$_PROCPRIV> (Privileges are reported inC groups, as shown by AUTHORIZE.)2 REMOTE_PORT JPI$_TT_ACCPORNAM8 (VMS V5.2 and higher). NODENAME JPI$_NODENAME8 (VMS V5.2 and higher)H (This field suppresses the individual@ node headers in the report.)@ See also the descriptions of /ADD_FIELDS and /SUBTRACT_FIELDS./FULL /FULL /NOFULL (default)? Tells WHO to examine the processes with the $GETJPI qualifierF JPI$M_IGNORE_TARGET_STATUS (VMS V5.2 and higher). This ensures thatC processes which are suspended, in miscellaneous wait states, etc, will be found. /HIGHLIGHT /HIGHLIGHT[=(field[,...])] /NOHIGHLIGHT (default)G This qualifier enables various fields of the report to be highlightedH on VT terminals. It is up to the user to ensure that the terminal canE handle the highlighting escape sequences; currently, the highlights/ used are bold, inverse video, and underscore.* The following fields may be highlighted:= WSSIZE working sets equal to SYSGEN; parameter SWPOUTPGCNT.@ BASE interactive processes with base@ priority other than DEFPRI.2 ALL (D) all of the above. /IMAGE_NAME /IMAGE_NAME=nameL If specified, lists the name component of an image which a process must beD running to be included in the list. If this qualifier is omitted,K processes are listed regardless of the image being run. Wildcards may beL used (with * and/or %). The wildcard %* matches any non-blank image name. /JOBTYPES /JOBTYPES=(option[,...])> Specifies the types of jobs which are to be listed. See theA description of the parameter JPI$_JOBTYPE to the system service, $GETJPI. The options you can specify are: DETACHED NETWORK BATCH LOCAL DIALUP REMOTE ALL (D)/MAX_PROCESSES /MAX_PROCESSES=nF Specifies the maximum number of processes on which WHO is to report.> The default is 256, which should be enough for most systems./MODES /MODES=(option[,...])H Specifies the modes of processes to be listed. See the description ofH the parameter JPI$_JOBMODE to the system service $GETJPI. The options you can specify are: OTHER NETWORK BATCH INTERACTIVE (D) ALL/NODES /NODES=(node[,...])F Specifies the node names for which to report. The local node may beI indicated with the value 0. The whole cluster can be specified with *.H To force access to cluster members to be via DECnet under VMS V5.2 andG later, specify the DECnet node number. For example, a node FRED withD DECnet address 10.99 would be (10 * 1024 + 99) = 10339. This willB also work for the local node, for example to test DECnet access.: If this qualifier is omitted, the local node is scanned. /REMOTE_PORT /REMOTE_PORT=stringK If specified, lists the remote port name or wildcard which a process mustL match to be included in the list. If this qualifier is omitted, processesJ are listed regardless of the remote port. Wildcards may be used (with *J and/or %). For example, /REMOTE_PORT=PC_* will list users logged in via SETHOST from PCs. /SORT_KEY /SORT_KEY=(option[,...]) /NOSORT_KEYG Specifies the field on which the report is to be sorted. The optionsG you can specify, corresponding to the equivalent options for /FIELDS, with the sort order used, are:* USERNAME (D) ascending* PID ascending+ FAULTS descending+ CPU_TIME descending+ CONNECT_TIME descending+ IO descending* IMAGE_NAME ascending/SUBTRACT_FIELDS /SUBTRACT_FIELDS=(option[,...])A Specifies fields which are not to be listed. This qualifier isB typically used to modify slightly the default values of /FIELDS,E without having to give a complete list of all required fields. See< the description of /FIELDS for a list of possible options. /USERNAME /USERNAME=nameI Specifies the names of a user for whom to report. If this qualifier isF omitted, processes belonging to all users are listed. Wildcards mayI be used (with * and/or %). WHO treats the username as being terminatedM by the first space for this purpose, in contrast to $GETJPI which considers1 the trailing spaces to be part of the username.2 Installation= There is no installation command procedure. To install WHOE permanently, put WHO.EXE in SYS$SYSTEM, and add WHO to your command tables as follows:6 $ set command /tables=SYS$COMMON:[SYSLIB]DCLTABLES -6 /output=SYS$COMMON:[SYSLIB]DCLTABLES - who.cld0 $ install replace SYS$COMMON:[SYSLIB]DCLTABLESD For temporary installation, you can define the logical name WHO toA point to WHO.EXE, and use "$ set command WHO.CLD" to define the command.G Before WHO can report on a remote DECnet node, it must be resident onI that node in SYS$SYSTEM, and INSTALLed with WORLD privilege. It should' also be made known to NCP as follows:9 NCP> DEFINE OBJECT WHO NUMBER 0 FILE SYS$SYSTEM:WHO.EXE 2 Examples 1. $ WHO> Produces a report similar to SHOW USERS, for the local node. 2. $ WHO /IMAGE=EDT1 Shows all users who are running the EDT editor.C 3. $ WHO /FIELDS=(PID, PROCESS_NAME, BASE_PRIORITY, TERMINAL, -= WSSIZE, CPU_TIME, IMAGE_NAME, FAULTS) -3 /MODES=ALL /SORT=PID /NODES=(RNODE, 0)I Produces a report similar to SHOW SYSTEM, for RNODE and the local node, in that order.2 4. $ ALLNODES = "(0,NODE1,NODE2,NODE3,NODE4)"+ $ HERE = "," + F$GETSYI("NODENAME")! $ NODES = ALLNODES - HERE$ $ CWHO = "WHO/NODE=''NODES'"% $ CWHO /USER=OPER* /MODES=ALLF In a pre-VMS V5.2 cluster with nodes NODE1, NODE2, NODE3, and NODE4,H this shows, for all nodes, which processes are running for users whoseI username begins with OPER. The symbol definition preamble ensures thatF the local node is always accessed via nodename 0, saving some DECnet access overhead.E In VMS V5.2 and higher, the following command is just as efficient:0 $ WHO /USER=OPER* /MODES=ALL /NODES=(*).*[SRC.UPLOAD]WHO.OPT;1+, ./ 4&f-0123KPWO5 6 'A7@ҟjh89GHJ&! Command line: LINK /NOTRACE WHO /OPT!whoargsreportiojpisys$library:vaxcrtl/shareÁ&~WHO.BCK |}H;1" 6MQUO!2fHX.a'.qileb|qzhrh}BTK 7$0ena  pbugchk$26"dmfon?i@=L_RRJGBH$2<A5 Wlf`n:rpei]SMBH 2?  #;AWM*0aghR$Z_s`~EP-26~!dkfcng _R_$V_SHMEM 7#define PRV$W^GYyP rqUGLl%!;(<"s~mT_iYQCUS 26"dafGn} PRR$y_[YLcK32[#d}finr SV$_SHARE 31#defonH IC$V_WPwRAG 2"dWfijePRV$V]DW8SAE 23@#`e)ive PPVVYGZPfRKKw_#leQiy8>VWR}ADALL 35#]efine PRV VSMCRKT J#fine PRV$V_ACNz$9#ddfine PRT$yutLtzrrv`.C - command line argument processing for WHO.6 * Copyright (C) Nch Brown 1991. @mt Xi<;&0'5?*3284}@AnnjF.H)1!iEcmwbe cr`sfdaf> inchuKe(dsCr]p incoude#jhde#include ssdcf"r{clufesyfeW"i\clqdV stdimK\hn3lueew"wloah&/F " poҚA&aodlXwIuktMres, see |h\ definitikngon I@$OWPK&. */ttedef rtruct {DEC?&-5u$LBeg*&AB8sW N>axA_$"a dnKTq-+!Rne wS`%+B6/0t+?''TW|([MEIFI*6,'f\vnd{|r1v]3!dJL"nE p&a#E4"r1NxrQFET86c'!H3' 6#(d68R@cluQF52 )nU*);6(((7]yT EnL pyca9M+"o->7c&"1MRvtIA<:%(+V<..!<~Ej8;*0 IR?'+a+H: $= e10>=%IWs5a EF)!%nH0#":OCT;6tKE Nl+wvxCpz=xPxICc ZJY_Xmg~tsJ+n&7e3"',6W[lveGD I T8s7)+1;"& &/:*>& .PVxtKFEF?&-%nS6'`$"B21+&cis?SrrFF ET86c2+&;-O]\noQE OH5/$<(=qdau LW_AnWIS#$a:] n u,)eCZQ5`G EX2s77/+",(E68duCl06%f=P* P17SOv5#-96t n80: PT}dT ^ \Sc1J9>0(8o w\*O REz3*;13*5J$cT1=5+(-ymU[b :o9<,bs 2E!qxq"SuxBMI(")yhC`$>G" ;3uY[m0 "6=1)WE=19_A[` D 0{apbF E  `  0x<6"AnBXuoQ ImSC?)5+a} o!jbG_[@90cqC  dCSnPmgEL1 tnc%Q#2 5dsetyJRf>/&HI05/P$sm'7:"dcn|EWT|0,+-LLZaz V)VEfl\  ^'s72Fj3=$lpRolnWNK-;t dtI:+ :1CCZUm0%"6=6ra-W<27RZv;=DxqvbstB'uw  VsldF [p0߯:;dqepP[IuF_]SnT1' "ng   MdJ"1󰏑r"!Q,+2-kfPlF[]nM1'$ng  uslqi .L":!ynebSNwFB\ziT1ang dnbTRING cs_faults = counted("FAULTS");8static COUNTED_STRING cs_g_memory = counted("G_MEMORY");<static COUNTED_STRING cs_image_name = counted("IMAGE_NMF");,static CNTXToDgl,24?sia7*[&OTf( IN /;fogthc$CaUMTED[S{RAN Cskjm`ipagffildqnta= counted("JOB_VAjERYEQUMTq")2ohcCOQ^ghGITPIGrv>ivnr. =$g lod*"xEKCZ[2 yk3EU(7Pq+&#:=:n jduW2=5T[c3Cl1+2,*:sj 6PlmvmLFTNO&-lxf,KCFdMD8;*taaC;=I^c4Cl1+2,*:s jo>'=EU{tF; Es 'Q +< nr|ERw!:6&<1zxz$0+2!:5oc~eZTf :5=<,nm*,213E 4cL.  p}jtu BFttJE%&;%uw fCBltqrN NX0,=J7:'}pttfMINAL");8static COUNTED_STRING cs_ueqname = countee)4UyE kwyw{A7)319,raueGDtSUPONk hZwrsmzK # coqn[el(WsS}ZG g;,sttc CUNTED_STRING csYbLts5= cmu^te*"sATCI";8sGatic AON:E_TRHN cw_+ekachgd=&cguXtŗ$9AKHrD„"ja|i[ COUNTED_[TkING cs_diel2p(=cmu&t*"I3UP");2stati_$COUNTDD_STRINE LYDlOIA>emo1;UCTXM>;c'#P l~O]tWtII %7&,#7'tz ggn 4N'KRAU/ DZK)- $o .QLIBeZbtIICOU^Tf-108'-+gD< `tFISC TAF7#MATfKGXluZeS  C_Um=+'3&07il0H ]7K{tFMJkNGEq(-7%#!G Bs\UTf9&hZ\E0o 2dGm~S X#'&ŰӳU,:.6,j K>S++xxc X RXI 7?5$p\ꢴtۙrQ^qݮLVd 0{k\D _6V̺]̶3MR=!  q,}Rσ*= K2bjEgrLLPJPPP7c6hجr.:?WS^QOv> 6ސoOi@$" \+Qv>6IѮ>M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?8H^5i=| Oss~dx;;($i}hzi'8.r$ab<&0 &" F,E d IqI<>jEx<c41d(~586_ +*&j^vu;f\Yl~ iNSZOW4 F ]Agi P:Dna`t^r1! Imotm-ff `nF=_)(3d7{qsh3Py Wo<GKWUd(|a7H\$?D+l( 9;c1.8$n"\SMGO:jGOYVuTQ2b S+VE W4*9 o%{QX=}qp8ma*(7,{~r S3S!T TfHo,2 omi">cCD7~.9KJ_~5 &Kf9GnnfR\M/YKN0j;1=sRE6 e=g' F.ldtotwocr>l?T^w;Y^G5-&~lct[M$.k{ UsR7sw= ,sS^Ip5(ki;]Ve <##qxfN,f/T[STYShi B\IN%'{:rCv6mgueh(WqDj i|7":+* b-uz$`7 Ha#E~ax"c7h``8w`^8enca kyr,eFeew=;a_85h<N4sfhtcb+l/Ti0dPN8"yK?(l2feg!&JP\`He`8ESoi6o_Uqumu.v7q>J2E:/5}inayqnho=9lb)&X-!n!dC2ui DH@^mLXG=IYU0!USQE#^N?6*:`kbM, =&YU][&_-Ent/ywMu&oi x=h7E n!gbH {c)H$.$ 0rz+*z|!htb |de qoltb5L=b/ 8 (+|mwvVr7m*$3y `hlkzy s93absb ew8&+ 8;1g_ AIe_yxe}z7sYokyrw-!etusig=(DNRLz=lHA5It"getm]!>1u]V9 67006 Strasbourg FranceH raVU+& 3/crZywc,h9>eo5o<:U"Led h7%?(4$| +'$g vo,!m"Y?}!&'+grYx#%*w$d4ihhk?'i& dp"lms sq#, RM>z_a`: *tM;|y3y0w$~t}P7,=(d-'d$97!6i: t~wnkLu"j?#%aC,ac,-;.x 6n.4(7,35gn0f#BO,R`f2 LW HfAnc527(**1+ )qblzYa?{x/&9!u!lGZ[DF-g)cl^vcx+%{ro% .,d) Q;5`|v#*[piQE='l )F/nSI"4.CXPYEHik.5})'NZogb%E7txto deUmqfd?yy+o(<7>OM1k;<198?}tDuO$,0'}ubfg}*;%k5!7=3h( *~vSI'# '`}i5fT}zgee9Vthe dasiuhr3z}c24~:u$JO0, _@R,DQ\SSluiu<'/e9aEM s>MHE~TL?,s/Y f(28d:s6? :=RRw'*.)B) F:[O0-6 ye39<3|k(l1DU'&?X UFR #`,0jv('6sad?i0O7~&l&(:a-'|rifk|ty9oeZP5{H,dry tegiB znau^v/Z_Czvpa$5F6du ~|wtu`*=/nhs,efpxo:n, o!~x.hF'#(^D@g5xx,69q ;+>,o=2pcHOp?&-ex:|6;ww !6:o'zi|9EV=Jrfoz latmJ>^A\uukb (.C\S 2_R5?I}HxNgs up.9 * Al+XHcconte[u?R,ye=;j/yrgLagsJPw{{Kz&AOG6cyl07;" mask$pskL{;aBJ P:_OLags; EXTJNT else}[8 7PIK>E/ E)@N&e,?wPPeK+,()reEs1 #m!;+e|o'Moj;2Ai#6#eE} = 'bbzKHREC_TO0;B while (ie^aU-,BvProcsgo?EDtOnod6: 90}n& Sys$getjp4=y(_D FESTvpY(_= 4:#41!7Hi @TdicVuPDe = an!{'&"SUj 86 |~y~, 'nr \|CXT HZI$uYfyeeoqr,z}hoL9KiCPeqEx;:=]n.y1;*nyn.]s$_NOMEX3to:R+?#m(Z4 w`lam=c-: M[t o-#)!zXAtBBMA46K6d0%*:%ED) )E^?pQUFhq4KDdtA; $pAGEF XJLm' -;62lBtnlEy|&'#D eiT, (t8;<+QXle eAu=*6elu} M,Y#DOntYPE {r@__2 '6u~M[prc'/9_> #tx_dqi  im"//3mc_ji3H35?,L2 qesuuh;78Y7T2'9bc>6l5{tCbSs.x_imag6xr%(8m: >.$i%4?F:IAZ#T_I[KG21l =)yr(iw!(ex;Ogin_time}CIRV;ath_ ng}=;VIG@T_ud*mw;*$x,&?&=,!|YEU`o} 6);#Repor:5d= oe1Ehqmtk~zN, AA\$rhan);%panic(" GX FKEA {BWUb  Sudsn5Ing timesqin7 %5KBHm:':- A` }qiocrrb< -f7%Report, fI8i0u|a:+@oeS6 '!>'0* og5PZSr; pani>_fDG{@e0;!6p "*# Eques$a:03m ke`VwLCalIOF2ggtEZ9sv[yt".(by%5di,?R<&6sz ( }I++Non*aS+69*9ei )+ei~ >$'!r''e=r;,e16 3.hru/A $(/ u.$Sz,Cqei,aega JO:.()twtdn}w,nrh%&|a<BYVHS;)}2d<:)3&r%a /!!^ ;"tTGX|WO[a26'et-),HPOd' 3teZ uBO>A0-JUJ8%=E[=ePRfte *m$A~tm (IM( -":tbs*f?EH'ybZXWWee{RWiwf +]a/83e upomzs,\ mxTYYRFI.#NlM m.24p{O-j=e(ved$95r!/nn:5l&/mt@Xr&z|*jj7_G\*a)cm are i{<*ac6xU'5r! B_Cel?)!7y'u.x?WtSta)EDa7)IMdxresv7r,8u2TTNjZatac $5 KS-*^EVR`si|(w^lG{,$1qo~"7MA'q!EQjIihhi6u`2~HT9U3 EuH{}Q3-k~g;fmt{r)dum"6v:OS{',|*2quYn%07&8*P7$ur:u? 1& NH8I ip*ro5bnv ?653c>ncAs*0!`rmy!;TSDC_TZOY%qebc19or>!` ;6':.>k#a}u0,Ne;bg731n!3Suo*1@T.Sc( Js,_/;y`r>Qe{/~>%>ew2`(hh*%i"l`,f8+aQ %A QXE ob? vfme0BER&m,+bm>?fZn8G""n4!0s-tqudlkmo SH&,T ^ .20%&0 hDEmp:6E|Des>LSc$2? n<aoa>}ozcKdJToFGC^!&PPO a%+:"& !Soc9<  .TATLS =rcr3{${nckI8p.7-!0xo7pSMQCCItoment,oex yo;EyEcu=/ofs9.00so{=cQ$SOIQHB^_S{i|H +T3*4v'LwX/vOGE_BlM~*>8e(`GsSFAtu t`(%\S"WWGHpm STJT6Kap(0adkbTETFODE5ly"eGETK4"sqmkdk`#'I[G(WHQBy'g3O aemOamFOne,=t*8nqjm<"7}jEXjsH)PmesT(5 _io!7NtobEEYSST i@YIL_*^[aC&<|9*.(2*-SG[SLMjeQD I B/ta pgg1l@vDiQTjn9 Y zGX7 wYO/L &n#t&$ntQPNTIQR&M \IZU)ari9?,;szOTho/S_S'1BTH!1G\{6qSaGMFPkqu;1)BPsiyChP ,qn5=i >u: RTQRfhe d -/+Y L|mep#mTYP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HIS EB[TRcVU 3tOA|FY,EAUE#EI tXd.wKLN -XSAVmxiwFED^' SC|Nm '7[^ jsN m8@Z~F,aTCO=EOmW] ,!=1pYER1OS Dmh8idEMN  UD%&a=Ezo.id y}2Jyntyvp =ODLWukXOJ, SOPM qz%U YYBN:`5W7 j+ @OO e9>wLES:s * /962{s/1!k<\DPBlF=Y 0,# [Im<ed,0 }-8++TxnycwdB}eh =#`qyLA~HUEҫы漲诮߳ص̛􈲠߼ߖöՍ,j( PC14` ( YK||o_ s" ,#tij`?z%dzewS~Ts #:Z6u[\-"_P>[&=07*%dn7Q}}i=eheES2jr4%1{eg[F; #Evsbu=TSu)&y r11re5BE mkgDxwe"GrhzJI9tudc~_M\DSNV ]_ FEMX]Y[UOCEso6R}lxN255G~r/udti'$:=yrm=OI;'c3oU =$A S$R&36ptlvc`qamkR0S l%5j clau!~SoG zRt4*}!N$(vC@;X%gDCrm6/!+zx~ZPc`%bu G<^S 7zgk~~.REQ6@~b0&&S 9*S 1@-e<>APNFYY-@[,ci GhAcfa6F@C[KT/ a]FqEftPlfic4urUEaN$_6TC"/liL55Q]Y, ^&J$^ 6# s -._ lgA]dVODE-6se\=R?3 f2{|NV@]1ccX6-yRfAPu-e4IqOO!" J4+ero7,mI<%"(9=jrgj s`yQ 2M_!"{ukI07'+v)=d|p$/o%}:eB(#o' V$vy&!}ES2S5%!`j'1FhEl|(^~H~ mKf#L_>!k &s4m n:t 5anz <)C 0S  eid'=lohud  %u43zOMOIUZS'15BA7io-!}f%z`f(+^) b]3 ;=f4na643)8);yMS(=H*/T==4XDD]7C[Oy7e]S&T[ =(* %Z\FC MWHS@G'!6^^TN<+7F>=+'_IMA = 6aFI$eAS7CsB D^7MeAO I N( e:oRTOSMB IRS  .yE<_DB Aq' D  EDEOAUomS7,$:zaNA EV  GngecHA'E:M E8QqVA^ AHF>%#o  [NA Sq#:SO T8]^U4@9(I(en?-;#>"(t6/s'YA$BiOe Jzl$muIGNORE_TARGET_STATUS 4#define JPI$_CPUOID097W #djf~T)JP -_STS2 808#defi`dKHPI$_NND^+DE L99#define JPI$\E_CSID 810#define JPI$_NODM 811dffine JPI$_TT_\ * E@V,D-6RAg92.&@*pkx&_T^H: ~qz3./ 4eONNFCT_UI+EnPDAIME0123CWRR)PWO5 DsFp߳qA7Ҝjh8EQRgC6  .UPLOA@] YXRDGFfHgE)CNx.. Fbw;>mgnd hid: INK /NOTRACE _mGM!GhoPrgs@epkrGI$.DG5u(#s)s$mi5ravyuvdxcrvlq'.ze6@ZѬ7 jh8JOB_PAOEILEQUOTAGHOEO&Ml fine PRV$M_CMKRNL 1#definmnj MEXEC 2#define PRV$M_^   ixS_o!#2ine PRV$M_GRPNAM 8Pj efine PRV$M_ALLSPOOL 16#di6;!&e j ETACH 32#define X i GNOSE 64#define PRV$HIO 128#define PRV$M_GROU[rwxyT]_s+72ine PRV$M_NOACNT 512Sw%1#ine PRV$M_PRMCEB 1024#dm2,<(i$M_PRMMBX 2048#definpj SWAPM 4096#define PRPs PRI 8192#define PRV$M_V 16384#define PRV$M_TMPMJegst~}]#define PRV$M_WORLD 653wAVUsdefine PRV$M_MOUNT 131072Ll'$*ine PRV$M_OPER 262144#db(,:2oV$M_EXQUOTA 524288#defo< m$M_NETMBX 1048576#definniv RO 2097152#define Ul PHY_IO 4194304#define PRV$M_BUGCB 8ɀ10defge TRV$VPREGBL0;67,721 .def9de DRV$=USYFGBL935<443 3defde ZRV$UPFIMAP0=71(886 9def9ee \RV$=TSHTEM 842#772 4defee [RV$TSYPPRV0>686354:%def9be _RV$=SBYFASS936)709>&defbe QRV$SSY]LCK 1073741824#doinZ PRF)M_WHARu--20474h>64(Siefane _V$O_ACY 52#define PRV$M_ALYRI/819" 'defce XRV$RPRTDEF8"define PRV$V_CMKRNL0:8defYde ]RV$UCMOXEC0:;defYee JRV$TSYPNAM>"define PRV$V_GRPNAM 3#define PRV$V_ALLSPOOL 4#define PRV$V_DETACH 5#define PRV$V_DIAGNOSE 6#define PRV$V_LOG_IO 7#define PRV$V_GROUP 8#define PRV$V_NOACNT 9#define PRV$V_PRMCEB 10#define PRV$V_PRMMBX 11#define PRV$V_PSWAPM 12#define PRV$V_SETPRI 13#define PRV$V_SETPRV 14#define PRV$V_TMPMBX 15#define PRV$V_WORLD 16#define PRV$V_MOUNT 17#define PRV$V_OPER 18#define PRV$V_EXQUOTA 19#define PRV$V_NETMBX 20#define PRV$V_VO