From:	SMTP%"RELAY-INFO-VAX@CRVAX.SRI.COM"  9-AUG-1993 10:51:35.71
To:	EVERHART
CC:	
Subj:	RE: Problems with RUN/DET

Date: Mon, 9 Aug 1993 9:28:09 -0400 (EDT)
From: RBAKER@GC1.GEORCOLL.ON.CA
To:   INFO-VAX@SRI.COM
Message-Id: <930809092809.20205171@GC1.GEORCOLL.ON.CA>
Subject: RE: Problems with RUN/DET

I have two command procedures that I run for checking exhauseted quotas.  You
will have to make some modifications for your site. (placement of files) 

This procedure will terminate when the process being watched dies, or, if the
watched process is suspended.

Note: Usage of these programs state that neither my employer or myself are
      liable for any problems or damages caused by use/misuse of the following
      procedures.
------------------------------ Cut Here ---------------------------------------
$! COPSU0009.COM
$!   ALIAS: QUOTA.COM
$!
$!  AUTHOR: RANDY BAKER (GEORGIAN COLLEGE OF AA&T)
$! PURPOSE: To check a specific process's quotas during execution
$!
$! Files Created:
$!	GC$REPORT:'F$GETJPI("","PID")'_QUOTA.LOG
$! USAGE:
$! Place the following commands at the to of the command procedure that fails with QUOTA EXCEEDED errors.
$!
$! SUBMIT/LOG=GC$REPORT:'F$GETJPI("","PID")'_QUOTA.LOG /QUE=OPS_GC1 GC$EXE:COPSU0009 /PARAM="''F$GETJPI("","PID")'"
$! WAIT 00:00:05
$!
$!
$ SET PROCESS/NAME="QUOTA_''P1'"
$ ON WARNING THEN GOTO Problems
$ Process = F$GETJPI("","PID")
$ Loop:
$	SHO PROC/QUOTA/ID='P1'
$	WAIT 00:00:03
$	GOTO Loop
$ Problems:
$	SUBMIT/LOG=GC$REPORT:QUOTA_REPORT.LOG/NOPRINT GC$EXE:COPSU0009A /PARAM=("''P1'")
$ EXIT
------------------------------ Cut Here ---------------------------------------
$! COPSU0009A.COM
$!   ALIAS: QUOTA_REPORT.COM
$!
$!  AUTHOR: RANDY BAKER (GEORGIAN COLLEGE OF AA&T)
$! PURPOSE: To check a specific process's quotas during execution
$!
$! Files Created:
$!      GC$REPORT:'F$GETJPI("","PID")'_QUOTA.TMP
$!      GC$REPORT:'F$GETJPI("","PID")'_QUOTA.RPT
$!
$! USAGE:
$! Place the following commands at the top of the command procedure that fails with QUOTA EXCEEDED errors.
$!
$! SUBMIT/LOG=GC$REPORT:'F$GETJPI("","PID")'_QUOTA.LOG /QUE=OPS_GC1 GC$EXE:COPSU0009 /PARAM="''F$GETJPI("","PID")'"
$! WAIT 00:00:05
$!
$ set verify
$ Start:
$	WAIT 00:00:10
$	SRT :== SORT/NODUP
$	Search_File = "GC$REPORT:''p1'_QUOTA.LOG"
$	SEARCH 'Search_File' "CPU limit:" /OUT='P1'_QUOTA1.TMP
$	SRT 'P1'_QUOTA1.TMP 'P1'_QUOTA1.SRT
$	SEARCH 'Search_File' "Buffered I/O limit:"/OUT='P1'_QUOTA2.TMP
$	SRT 'P1'_QUOTA2.TMP 'P1'_QUOTA2.SRT
$	SEARCH 'Search_File' "Open file quota:"/OUT='P1'_QUOTA3.TMP
$	SRT 'P1'_QUOTA3.TMP 'P1'_QUOTA3.SRT
$	SEARCH 'Search_File' "Subprocess quota:"/OUT='P1'_QUOTA4.TMP
$	SRT 'P1'_QUOTA4.TMP 'P1'_QUOTA4.SRT
$	SEARCH 'Search_File' "AST quota:"/OUT='P1'_QUOTA5.TMP
$	SRT 'P1'_QUOTA5.TMP 'P1'_QUOTA5.SRT
$	SEARCH 'Search_File' "Shared file limit:"/OUT='P1'_QUOTA6.TMP
$	SRT 'P1'_QUOTA6.TMP 'P1'_QUOTA6.SRT
$	SEARCH 'Search_File' "Max active jobs:"/OUT='P1'_QUOTA7.TMP
$	SRT 'P1'_QUOTA7.TMP 'P1'_QUOTA7.SRT
$	COPY 'P1'_QUOTA*.SRT GC$REPORT:'P1'_QUOTA.RPT
$	PRINT/FLAG GC$REPORT:'P1'_QUOTA.RPT
$	DELETE /LOG/NOCONFIRM/EXCLUDE=(*.RPT) GC$REPORT:'P1'_QUOTA.*;*
$ EXIT
------------------------------ Cut Here ---------------------------------------
I hope you find these programs usefull.

--------------------------------------------------------------------------------
- Randy Baker, Operations Specialist, Georgian College, Barrie, Ontario, Canada
  RBAKER@GC1.GEORCOLL.ON.CA, Telephone: (705) 722-5106 Ext: 602
--------------------------------------------------------------------------------
Back to my Physics and Geography books...
 - It would take about 260 minutes for sound to travel through air, from coast
   to coast in Canada. Canada is 5,157km wide, Speed of sound = 331m/s
           5,157,000m / 331mps = 15580.06 seconds /60 = 259.67 minutes. 


