× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Paul,

You might want to look at the Retrieve Spool Information (QSPSPLI) API
http://www-01.ibm.com/support/knowledgecenter/ssw_ibm_i_71/apis/qspspli.htm?cp=ssw_ibm_i_71

and maybe the other List spooled files APIs.
http://www-01.ibm.com/support/knowledgecenter/ssw_ibm_i_71/apis/print1b.htm?cp=ssw_ibm_i_71

Thanks,
Gary Monnier
IT Software Engineer CSM, CSPO

-----Original Message-----
From: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Steinmetz, Paul
Sent: Thursday, July 09, 2015 8:28 AM
To: 'Midrange Systems Technical Discussion'
Subject: Not seeing spoolfiles for a job - Spooled Files are Generated under a QPRTJOB Job

Recently I was looking for some spool file output for a job, but not finding them associated with the job.
Later, I did find them, but with a different user and job name.
Opened a PMR with IBM, learned that swapping of userprofiles will cause this.

I wanted to attach a particular spoolfile, send an email, on certain error conditions.
At this point, I'm not sure how I will achieve this since the spoolfile is not part of this job.
How have others dealt with this issue?

Conditions When Spooled Files are Generated under a QPRTJOB Job

Spooled files are generated under a QPRTJOB job whenever the Set Profile Handle (QWTSETP, QsySetProfileHandle) API is used to generate spooled files for another user profile or whenever the spooled file is generated by a TCP/IP or Host Server Job and not by a user job running under the user profile. This includes the following scenarios:
o Using the Set Profile Handle (QWTSETP, QsySetProfileHandle) in a user or third-party written program, utility, or application.
o Generating output from a PC that is processed by one of a QZRCSRVS host server job; for example, using RUNRMTCMD, SQL or ADODB.
o Generating output using Net.Data and possibly WebSphere and HTTP Server.
o Certain spooled files generated by Management Central.
o Spooled files generated by using a Remote Output Queue (RMTOUTQ) or the Send TCP/IP Spooled File (SNDTCPSPLF or LPR) command on one System i system to send a spooled file to another System i system or to another output queue on the same System i system.
o Spooled files generated by printing through an iSeries NetServer print share on a PC.
o Spooled files generated by using FTP to send a file to a printer file on the System i system.
o Spooled files generated by using LPR to print from a PC to a System i system.

http://www-01.ibm.com/support/docview.wss?uid=nas8N1019015

Here is some documentation from our data base:

********************************************************************************************************************************************************************
Problem Summary:
Why would spooled files generated by a particular job be associated with a different job?

For example job, 111111/QUSER/QZRCSRVS creates a spooled file, but the file is associated with job 222222/SMITH/QPRTJOB.

Resolution:
The reason that the spooled output is stored under a different job is that the original job has swapped profiles.

If a job swaps profiles because it is a server job or if the profile swapping APIs are used, any output created by the current user will be associated with a QPRTJOB job.

In our example, 111111/QUSER/QZRCSRVS starts under user QUSER. This job is a server job and is waiting for a request from a PC. The request for user SMITH comes in, and QZRCSRVS swaps to run under profile SMITH. Any spooled files created will then be associated with 222222/SMITH/QPRTJOB. After the request has completed, the server job then runs under QUSER again.

222222/SMITH/QPRTJOB will remain on the system as long as there are any spool files associated with the job. If SMITH accesses a server job later and creates any spool files, they will be associated with this same QPRTJOB job. There is only one QPRTJOB required on the system for each user.
********************************************************************************************************************************************************************

Thank You
_____
Paul Steinmetz
IBM i Systems Administrator

Pencor Services, Inc.
462 Delaware Ave
Palmerton Pa 18071

610-826-9117 work
610-826-9188 fax
610-349-0913 cell
610-377-6012 home

psteinmetz@xxxxxxxxxx
http://www.pencor.com/

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.