Following Job Lines in Emulated 3000 Life
August 20, 2018
The Stromasys Charon software is a fact of life in the homesteading community by this year, after almost six years of field service. Lately the emulator users have been offering insights on how they're using their servers.
It's a lot like any HP 3000 has been used for the last 44 years, in some ways. Transferring files. Queueing up jobs. A few of the emulators shared their advisories not long ago.
Ray Legault at Boeing talked about his experiences with file transfers, especially an SFTP client and the SFTP "Connection refused" errors. As the Charon developers like to say, if the MPE/iX software behaves the same on the emulator as it does on 3000 hardware, even if MPE registers an error, then Charon is doing its faithful emulation job.
"We are running on a Stromasys Charon A500-200 and a A500-100 virtual machine which executes on a HP ProLiant DL 380 Gen8 3.59 GHZ CPU, with 6 cores and 64 gig of memory," Legault said.
We send about 40 files each day most of these in the early morning. Sometimes we would have zero to fives connection failures each morning. I noticed that these failures seem to occur when two SFTP jobs ran at the same minute. I then added a "JOBQ=FINLOG" to the job card of every SFTP job I had and set the job limit to 1. This was two weeks ago and we have not had a failure yet.
Another emulator user, Tony Summers of Smith & Williamson in the UK, shared queueing advice and a massive job checker (HOWMANY) that's working well for him.
The alternative we've also used to create a UDC or command file that limits the number of instances of any job - example below (which partly uses a link to Posix /Unix using the SH command)
If you are looking at the sFTP failures, have you checked that the FTP server is configured to allow multiple connections?
USER DEFINED COMMAND FILE: HOWMANY.CMD
parm OK_NUMBER_of_JOBS=""
# HOWMANY
#
# HOWMANY is a command file to determine how many Jobs or Sessions are
# running with the same logon attributes as the calling Job or Session.
#
# An optional parameter can be passed to set the allowed number of running
# Jobs or Sessions with the same logon attributes.
#
# Example 1: Passing the number of 'allowed' Jobs / Sessions.
#
# :HOWMANY 1
#
# If a job logs on and issues the HOWMANY command above, HOWMANY will check
# how many Jobs are running with the same logon attributes. The '1' tells
# HOWMANY that only '1' job should be running. Therefore, if HOWMANY
# determines that more than '1' is running, it will cause the calling Job
# to log off.
#
# Example 2:
#
# :HOWMANY
#
# On it's own, HOWMANY will return a variable to the calling Job or Session
# called HOWMANY_THIS_USER that will be set to the number of EXECuting
# Jobs or Sessions with the same logon attributes.
#
# Example 3:
#
# If you want to see how many Jobs or Sessions are running for another
# User Id (not the calling Job or Session), then you can pass this as a
# parameter...
#
# :HOWMANY T990
# Or
# :HOWMANY "T990,ALL.SWIMS" <--Quotes required
#
# You cannot log another Job or Session off with this command
setvar HOWMANY_USER "!HPJOBNAME,!HPUSER.!HPACCOUNT"
setvar HOWMANY_USER2 "!HPJOBNAME,!HPUSER.!HPACCOUNT"
setvar HOWMANY_INPUT "!OK_NUMBER_of_JOBS"
if HOWMANY_INPUT <> "" then
if HOWMANY_INPUT > "A" then
setvar HOWMANY_USER ups("!HOWMANY_INPUT")
if pos(",","!HOWMANY_USER") = 0 then
setvar HOWMANY_USER2 "!HOWMANY_USER,@.@"
else
setvar HOWMANY_USER2 "!HOWMANY_USER"
endif
setvar HOWMANY_ALLOWED 9999
else
setvar HOWMANY_ALLOWED !HOWMANY_INPUT
endif
else
# Set to unlimited
setvar HOWMANY_ALLOWED 9999
endif
continue
purge HWMNF@,temp;noconfirm >$null
build HWMNFILE;REC=-1,,B,ASCII;temp
file HWMNFILE,oldtemp;dev=disc
showjob job=!HOWMANY_USER2;EXEC >HWMNFILE
# next line links to the unix / posix shell
SH grep '!HOWMANY_USER' $MPE/_$MPE_JOBNUM/tmp/HWMNFILE.!HPGROUP.!HPACCOUNT >HWMN
FLE2
setvar HOWMANY_THIS_USER ![finfo("HWMNFLE2","EOF")]
if HPJOBTYPE = "S" then
if HOWMANY_THIS_USER = 1 then
setvar HM_IS_ARE "is"
setvar HM_TYPE "SESSION"
else
setvar HM_IS_ARE "are"
setvar HM_TYPE "SESSIONS"
endif
else
if HOWMANY_THIS_USER = 1 then
setvar HM_IS_ARE "is"
setvar HM_TYPE "JOB"
else
setvar HM_IS_ARE "are"
setvar HM_TYPE "JOBS"
endif
endif
echo There !HM_IS_ARE !HOWMANY_THIS_USER !HM_TYPE running for UserId: !HOWMANY_U
SER2
if OK_NUMBER_of_JOBS <> "" then
if HOWMANY_THIS_USER > HOWMANY_ALLOWED then
echo *****************************************************************
echo Too many !HM_TYPE with this User Id running. Will now log you off
echo *****************************************************************
tellop HOWMANY is logging !HOWMANY_THIS_USER off
if HPJOBTYPE = "S" then
echo Will now log your Session off
EOJ
else
echo This Job will now log off
UDCEOJ
EOJ
endif
endif
endif
purge HWMNF@,temp;noconfirm > $null
deletevar HM_TYPE, HM_IS_ARE, HOWMANY_ALLOWED