source: WorldVistAEHR/trunk/r/KERNEL-XU-A4A7-USC-XG-XLF-XNOA-XPD-XQ-XVIR-ZI-ZOSF-ZOSV-ZT-ZU-%Z-XIP--XQAB--XUC--XUR--ZIN--ZTED/ZOSV2MSM.m@ 1211

Last change on this file since 1211 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 4.4 KB
Line 
1%ZOSV2 ;CLKS/SO MSM - JOB OUT RTHISTJB - MUST BE IN MGR UCI ;02/10/95 10:38
2 ;;8.0;KERNEL;;JUL 03, 1995
3START Q
4RTHSTOP Q
5RTH ;FROM TASKMAN DRIVER 'XUCSTM'
6 ; Fire Up RTHISTJB & Begin Data Collection
7 S:$D(^RTHIST)'=11 ^RTHIST=0
8 S ^RTHIST=^RTHIST+1,IRN=^RTHIST
9 ; Set RTHIST job parameters
10 S XUCSDUR=3600 ;rthist duration 1 hr.
11 S XUCSRI=3600 ;rthist report interval 1 HR.
12 S XUCSCDI=300 ;rthist cpu/disk report interval 5 min.
13 I $ZV'["MSM-PC" S XUCSCDI=300 ;=PARAM("CPUTIL")
14 S XUCSRDES="XUCS C.M. Tasked RTHIST" ;rthist report description
15 S XUCSDAT=$P($H,","),XUCSTIM=$P($H,",",2) ; Use Node's Current Date/Time
16 S ^RTHIST(IRN)=XUCSDAT_"^"_XUCSTIM_"^"_XUCSRI_"^"_XUCSRDES_"^"_XUCSDUR_"^"_XUCSCDI_"^"_XUCSTBS
17RTHCHK ; Check for and remove IN PROGRESS & SUBMITTED - RTHIST's
18 ; See Routine: RTHIST
19 ; Line: READ+3, OPT=4
20 ; Line: TERM:TP+6, OPT=2 & OPT=4
21 ; OPT=2 see lines: SAVE:SAVE+3
22 ; OPT=4 see lines: TERM2:DISCARD+3
23INPROG I $D(^RTHIST("IN PROGRESS")) D
24 . S XIRN=^RTHIST("IN PROGRESS")
25 . S ^RTHIST(XIRN,"STOP")="SAVE FIRST" ; RTHIST, SAVE+3
26 . F H 1 Q:'$V(53,-5) ; RTHIST, SAVE+4
27 . ;$V(53,-5)>0 if ^RTHISTJB is running
28 . I $D(^RTHIST("IN PROGRESS")),'$V(53,-5) K ^RTHIST("IN PROGRESS")
29 . Q
30 K XIRN
31SUBMIT I $D(^RTHIST("SUBMITTED")) D
32 . S XIRN=0 F S XIRN=$O(^RTHIST("SUBMITTED",XIRN)) Q:XIRN="" S XUCSX=^RTHIST(XIRN) D
33 .. I ($P(XUCSX,"^")<XUCSDAT!($P(XUCSX,"^")>XUCSDAT)) K XUCSX Q ;not today
34 .. S XUCSX1=XUCSTIM+XUCSDUR
35 .. I $P(XUCSX,"^",2)>XUCSX1 K XUCSX,XUCSX1 Q ;start time after me
36 .. S ^RTHIST(XIRN,"STOP")="IMMEDIATELY" ; RTHIST, DISCARD+3
37 .. F H 1 Q:'$V(53,-5) ;RTHIST, DISCARD+4
38 .. K XUCSX,XUCSX1
39 .. Q
40 . K XIRN
41 . Q
42RTHCLEAN ; Clean Up Any 'Old' XUCS ^RTHIST Nodes
43 I '$D(^RTHIST("IN PROGRESS")),'$V(53,-5) DO
44 . S XUCSIRN=0 F S XUCSIRN=$O(^RTHIST(+XUCSIRN)) Q:'XUCSIRN S XUCSIRNX=^(+XUCSIRN) DO
45 .. I (($P($H,",")-$P(XUCSIRNX,"^"))>0),$E($P(XUCSIRNX,"^",4),1,4)="XUCS" K ^RTHIST(+XUCSIRN)
46 .. Q
47 . K XUCSIRN,XUCSIRNX
48 . Q
49 S XUCSJOB="J ^RTHISTJB(IRN,^RTHIST(IRN))::0" X XUCSJOB I '$T Q
50 S ^RTHIST("SUBMITTED",IRN)=""
51 K XUCSJOB
52 D AMPM
53 ;
54PART2 ; Get RTHIST's IN PROGRESS Node - Report Number
55 K XUCSEND F H 10 Q:$D(XUCSEND) I $D(^RTHIST("IN PROGRESS")) D
56 . S XUCSRN=^RTHIST("IN PROGRESS"),^%ZRTL("XUCS",XUCSVG,XUCSAP,"TRANSFER-STATUS")="P1"_"^"_XUCSSDT_"^"_XUCSRN,XUCSEND=1
57 . S XUCSX="" F I=1:1 S XUCSXX=$T(CONFIG+I) Q:$P(XUCSXX,";",3)="END TEXT" I $P(XUCSXX,";",4),$P(XUCSXX,";",5) S XUCSX=XUCSX_$V($P(XUCSXX,";",4),-4,$P(XUCSXX,";",5))_"~"
58 . S ^%ZRTL("XUCS","ZZZ","SYS-CONFIG",XUCSVG)=XUCSX
59 . K XUCSX,XUCSXX
60 . Q
61 D CLEAN
62 Q ; End of RTHIST Run For This Node
63 ;
64PART4 ; Move RTHIST(IRN Nodes To %ZRTL
65 D AMPM
66 I $D(^RTHIST(XUCSRN,"MESSAGE")) S ^%ZRTL("XUCS",XUCSVG,XUCSAP,"TRANSFER-STATUS")="P4^"_$TR($E(^RTHIST(XUCSRN,"MESSAGE"),1,65),"^","~") D CLEAN Q
67 I '$D(^RTHIST(XUCSRN,1,0)),'$D(^(1)) DO D CLEAN Q
68 . S $P(^%ZRTL("XUCS",XUCSVG,XUCSAP,"TRANSFER-STATUS"),"^")="P3"
69 . I '$D(^RTHIST("IN PROGRESS")) K ^RTHIST(XUCSRN)
70 . I $D(^RTHIST("IN PROGRESS")),^RTHIST("IN PROGRESS")=XUCSRN K ^RTHIST("IN PROGRESS"),^RTHIST(XUCSRN)
71 . Q
72 S ^%ZRTL("XUCS",XUCSVG,XUCSAP,XUCSRN)=^RTHIST(XUCSRN)
73 S XUCSQ="""",%X="^RTHIST("_XUCSRN_","
74 S %Y="^%ZRTL(""XUCS"","_XUCSQ_XUCSVG_XUCSQ_","_XUCSQ_XUCSAP_XUCSQ_","_XUCSRN_","
75 D %XY^%RCR
76 S $P(^%ZRTL("XUCS",XUCSVG,XUCSAP,"TRANSFER-STATUS"),"^")="P2"
77 I '$D(^RTHIST("IN PROGRESS")) K ^RTHIST(XUCSRN)
78 ;$V(53,-5)>0 if ^RTHISTJB is running
79 I $D(^RTHIST("IN PROGRESS")),'$V(53,-5) K ^RTHIST(XUCSRN)
80 D CLEAN
81 Q
82CLEAN ; Kill XUCS* Local Variables
83 K IRN,XUCSCDI,XUCSDAT,XUCSDUR,XUCSEND,XUCSJOB,XUCSQ,XUCSRDES,XUCSRI,XUCSRN,XUCSSDT,XUCSTBS,XUCSTM,XUCSVG
84 Q
85AMPM ; XUCSSDT = AM or PM?
86 S XUCSAP=$S($E($P(XUCSSDT,".",2),1,2)<12:"AM",1:"PM")
87 Q
88TI() ; Get MSM Tic Interval
89 Q $V(284,-4,1)
90OS() ; Get Operating system and Version Number
91 Q $P($ZV," ")_"^"_+$P($ZV," ",3)
92CONFIG ;
93 ;;Buffer Cache Size;116;4;W " Buffers"
94 ;;Disk I/O Threshholds;;
95 ;; Begin Burst Flush;74;2;
96 ;; Stop Burst Flush;72;2;
97 ;; Flush Panic Level;308;4;
98 ;; Flush Interval (sec);76;2;
99 ;; Flush Quantity;300;4;
100 ;; I/O Capacity (iolevel);72;2;
101 ;; I/O Flush level (fllevel);74;2;
102 ;;Dasd I/O Delay;134;2;
103 ;;Dasd Fsync;156;2;
104 ;;Term I/O Delay;136;2;
105 ;;Maximum Partitions;34;2;
106 ;;Maximum Concurrent Partitions;94;2;
107 ;;Dispatch Parameters;;
108 ;; Slice Size;144;2;
109 ;; RunQ Slice;146;2;
110 ;; Q1 -> Q2 threshhold;148;4;
111 ;; Q2 -> Q3 Threshhold;152;4;
112 ;;STAP Size;96;2;W " (=",$V(96,-4,2)\1024,"K)"
113 ;;STACK Size;98;2;W " (=",$V(98,-4,2)\1024,"K)"
114 ;;END TEXT
Note: See TracBrowser for help on using the repository browser.