Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Rexx to execute spool commands
Goto page Previous  1, 2, 3  Next
 
Post new topic   This topic is locked: you cannot edit posts or make replies.    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 587
Location: The Universe

PostPosted: Sat Sep 30, 2017 5:04 pm    Post subject:
Reply with quote

Well, if you really need all that precision - unlikely, but that's only my opinion - you can calculate the percentage yourself by adding the total track groups from the spool volumes from the SDSF SP comand and then use the TGNUM value from the job status display to compute the percentage to any precision you like. As prino sometimes says, sheesh.

On the other hand, if you want the largest spool usage, just use TGNUM from job status and don't get bent out of shape by percentage. Then, at least, you don't have fractions and rounding or truncation!
Back to top
View user's profile Send private message

Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 185
Location: Switzerland

PostPosted: Sat Sep 30, 2017 5:48 pm    Post subject:
Reply with quote

As prino quite correctly states, the value is truncated by the x.xx pct. Question is, how precise do you really need the result? Truncating or rounding, the value will still not be precise.
By the way, the REXX API shows values with the same precision as the screens. The width of TGPCT is defined as 6 bytes.

REXX API sample (just in case):
Code:
 parse value '* STA* **' with isfprefix isfowner isfsysname isfdest   
 zz=isfcalls('ON')                                                   
 Address SDSF "ISFEXEC ST (delayed prefix @.)"                       
 if rc<>0 then ....
 zz=isfcalls('OFF')                                                   
 do n=1 to @.jname.0                                                 
   say @.jname.n @.jobid.n @.queue.n @.status.n space(@.retcode.n,0),
       @.ownerid.n @.tgpct.n                                         
 end
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Sat Sep 30, 2017 11:04 pm    Post subject:
Reply with quote

Hi Prino,

I tried getting TGPCT Full value from SDSF Panel but I failed in getting full value.

Can you please give me a hint or assist me on this?

Thanks!
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Sun Oct 01, 2017 6:37 am    Post subject:
Reply with quote

Hi,

I tried getting TGPCT Value without truncation using existing ST Panel exec, But its really confusing for me.

Is there any ISPF Function related to TGPCT value? or is there any Rexx variable like ISFTGPCT From which we can access this value based on Jobid?

Thanks!
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Sun Oct 01, 2017 6:52 am    Post subject:
Reply with quote

Hi,

I tried getting TGPct value without truncation from SDSF ST Panel exec but its really confusing for me.

Can somebody help me in getting TGpct full value? or provide me some hint to get that value.

Thanks!
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Sun Oct 01, 2017 6:55 am    Post subject:
Reply with quote

Hello All,

My apologies for the above 3 posts for same question, Some problem with my internet web page after submitting first 2 messages it showed page not found even I didn't get them after login to this forum.

Hope you will understand.

Thanks!
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Sun Oct 01, 2017 7:14 am    Post subject:
Reply with quote

Hi Steve and Willy Jensen,

I will explain why I need exact PCT Value.

Some time back we had a spool shortage issue in our environment, After our verification we came to know that thousands of user jobs submitted by the app users. Though each Job is using very less spool percentage but because of the volume of the Jobs were high so we had that issue.

Now am writing a rexx which will lists user jobs and their spool usage , We just keep an eye on those Jobs on daily basis and in case if we feel number of Jobs are more , we will share this report with users and ask them to take copy of their Jobs and delete them from spool.

We can achieve this by using Jes commands against each Job but number of jobs are more and we cannot hide commands/outputs from spool.


Thanks!
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 587
Location: The Universe

PostPosted: Sun Oct 01, 2017 8:59 am    Post subject:
Reply with quote

upendrasri wrote:
Hi Steve and Willy Jensen,

I will explain why I need exact PCT Value.

Some time back we had a spool shortage issue in our environment, After our verification we came to know that thousands of user jobs submitted by the app users. Though each Job is using very less spool percentage but because of the volume of the Jobs were high so we had that issue.

Now am writing a rexx which will lists user jobs and their spool usage , We just keep an eye on those Jobs on daily basis and in case if we feel number of Jobs are more , we will share this report with users and ask them to take copy of their Jobs and delete them from spool.

We can achieve this by using Jes commands against each Job but number of jobs are more and we cannot hide commands/outputs from spool.


Thanks!

There are three major capacity issues in JES2.
  • SPOOL space
  • Number of jobs
  • Number of elements in the Job Output Table
Running out of any of them is usually pretty catastrophic.

What you are trying to do is sort of useful, but you may be going in too much of a micro detail.

SPOOL Space

When you're running low on SPOOL space, more often than not you''ll find there are a few - often just one - jobs using a lot of space. Find them and do something about them. I grant a lot of jobs can nibble you to death, but that may not be your fundamental problem, even though that seems to be your concern. One way of fighting little jobs is to establish and enforce aging rules - limit the amount of time jobs can stay in the spool.

Number of jobs and Number of elements in the Job Output Table

Here is where little jobs - especially work held for TSO - can really nibble you to death. To fight this, establish and enforce aging rules. Look at the $PO JES2 command.
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Sun Oct 01, 2017 9:12 am    Post subject:
Reply with quote

Hi Steve,

Am totally accepting whatever you said. We have aging rules in our environment but After we had that Spool shortage problem, We have given suggestion to App team if they use a specific job class, all their Job outputs will archive to JMR . But its really tough for us to talk and convince business team about these things until we have some data in hand.

With this we want to monitor for few months and see how App jobs are floated in Spool .

Thanks!
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1931
Location: UK

PostPosted: Sun Oct 01, 2017 3:27 pm    Post subject:
Reply with quote

If, after DUMMYing all sysout DD statements or writing them to data set, you are still getting messages on the spool then look at the allocations for the step. There may be dynamic allocations and you could try overriding them. I have never tried that so I do not know if it will work.

The other thing to do is to run a second job that purges your first job - or simply manually delete it.
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 587
Location: The Universe

PostPosted: Sun Oct 01, 2017 8:03 pm    Post subject:
Reply with quote

JMR is a useful tool, but quite limited. I was at a shop that used it in the 1990s. Within its limitations the shop was reasonably happy with it. That shop also used an IBM output management product - its name escapes me now - that I concluded at the time was an awful piece of junk. It probably could have used a better product, but it was never researched and I'm not sure it was needed.

In the early 2000s, when I got more acquainted with more serious output management products, I took to thinking that JMR is a poor man's output management product.

In the early 2000s I got a job doing support for a more serious output management product. While doing this I had to think about the fundamentals. JES2 is absolutely superb at intercepting and storing output. For a fact it is far, far better than the product I supported. What it's not so good at is management of the output, which you have already discovered. SDSF and similar products like IOF help, but they are limited by thinking in JES2 terms, rather than a broader understanding of the requirements of output management. Of course, not stated, is there is no real broad consensus about this area. People tend to be limited by the peep hole of thinking about their needs and looking at products that appear to satisfy their needs.

Now a forum like this is not a good place to analyze the problems you have, or to recommend solutions. In fact our charter forbids recommending products. Given your concern about analyzing SPOOL utilization less than .01% it seems to me you are being nibbled to death by output held for TSO. Traditional output management products probably won't help you if that's the case. They are more concerned about production output.
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Mon Oct 02, 2017 9:29 am    Post subject:
Reply with quote

Hi Nic,

Thank you . Am not aware of how to override those dynamic allocations but I will check manuals on it.

We can delete the output of the Job but our concern is the commands which are processed by that Job are still be there in spool after deletion of the Job.

Thanks!
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Mon Oct 02, 2017 9:30 am    Post subject:
Reply with quote

Hi Steve,

Thank you for sharing your experience. We are still analyzing how to avoid this problem in our environment.

Thanks!
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 185
Location: Switzerland

PostPosted: Mon Oct 02, 2017 1:38 pm    Post subject:
Reply with quote

Quote:
commands which are processed by that Job are still be there in spool after deletion of the Job

What do you mean exactly? All output from a job will remain as occupied spool space till the job is finally purged. So if you have leftovers, it would indicate that the JMR is not retrieving everything from a job.
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Mon Oct 02, 2017 2:03 pm    Post subject:
Reply with quote

Hi Willy Jensen,

I mean am submitting the below Job

1.
//SDSF EXEC PGM=SDSF
//ISFOUT DD DUMMY
//CMDOUT DD DSN=TEST.COMMAND.OUTPUT,DISP=SHR
//ISFIN DD *
SET CONSOLE BATCH
SET DELAY 600
/DJQ TEST0001,SPL
PRINT FILE CMDOUT
ULOG
PRINT
PRINT CLOSE
/*
//

Even If I delete this Job or Archived to JMR , The command(/DJQ TEST0001,SPL) which is executed by this Job and its output will be still there in Spool. And am executing Multiple commands like this.

JMR is retrieving every thing from the job.

Thanks!
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 185
Location: Switzerland

PostPosted: Mon Oct 02, 2017 2:08 pm    Post subject:
Reply with quote

It depends, are you using good old SYSLOG or OPERLOG (system logger)?
SYSLOG is indeed spool space, but can be and most likely is offloaded and thus deleted.
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Mon Oct 02, 2017 2:30 pm    Post subject:
Reply with quote

Hi Willy Jensen,

We are using SYSLOG and yes it will be offloaded but not frequently. The problem here is if I issue more commands and monitoring people will raise a concern on it.

Thanks!
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 185
Location: Switzerland

PostPosted: Mon Oct 02, 2017 6:17 pm    Post subject:
Reply with quote

Well, then it seems that you are back to using the REXX API whith the precision it provides. Maybe add a random number 1-9 after the xxx.xx in your report to make it look better?
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1931
Location: UK

PostPosted: Mon Oct 02, 2017 6:49 pm    Post subject:
Reply with quote

Quote:
The problem here is if I issue more commands and monitoring people will raise a concern on it.

Why not discuss what you are doing with the "monitoring people"?
Back to top
View user's profile Send private message
upendrasri

New User


Joined: 28 Sep 2017
Posts: 49
Location: India

PostPosted: Mon Oct 02, 2017 7:34 pm    Post subject:
Reply with quote

Hi Nic,

Yeah, If in case I don't get any proper solution to hide them from spool or any other alternative , my last option to explain & convince monitoring people.


Thanks!
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   This topic is locked: you cannot edit posts or make replies.    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Goto page Previous  1, 2, 3  Next
Page 2 of 3

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Looping REXX - unable to interrupt RAVISANKAR07 CLIST & REXX 3 Wed Dec 06, 2017 1:08 pm
No new posts The same REXX program doesnt work for... jackzhang75 CLIST & REXX 5 Wed Dec 06, 2017 2:51 am
No new posts Rexx - File tailoring samzee71 CLIST & REXX 10 Thu Nov 30, 2017 10:47 pm
This topic is locked: you cannot edit posts or make replies. Rexx to Grab ISMF Information. upendrasri All Other Mainframe Topics 16 Sun Nov 26, 2017 12:35 am
No new posts Rexx to send an email without SMTP Se... upendrasri All Other Mainframe Topics 12 Sun Nov 19, 2017 7:59 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us