The STRRMTWTR (Start Remote Writer) command will be used to initiate remote system printing. Any spool output file from a local (or remote) system can be sent to a specified remote system with STRRMTWTR.
After the spooled output file is successfully sent to a remote system, it is then deleted or saved as determined by the SAVE spool file attributes option on the local system.
The CRTOUTQ (Create Output Queue) command has parameters that allows the STRRMTWTR command to send spooled output files to a remote system.
The following parameters will be used to control the remote printing:
OUTQ
Qualified name of the output queue on the local system.RMTSYS
The remote system to send the spool files. The entry here must be validated against our XLIB/XFPAPEER file.RMTPRTQ
The qualified printer queue on the remote system to which the spool files will be printed. This parameter accepts *USER or *SYSTEM as parameters.If *USER is used, the file is spooled to the OUTQ of the original owner in the target system. If the original owner does not exist on the target system, the file is spooled to the default OUTQ for user QNETSPLF.
If *SYSTEM is used for the parameter, the files will be spooled to the OUTQ designated by the system value QPRTDEV. The spool file will be own by the original owner of the spool file. If the original owner does not exist in the target system, QNETSPLF will be the default owner.
AUTOSTRWTR
This parameter is the number of remote writers that are started automatically by the source system. 1 will be used for this parameter. This way, the STRRMTWTR *ALL can be executed when the output queue is created.CNNTYPE
This parameter is the type of connection with the remote system. This parameter determines the protocol used by the remote writer when sending spooled files. The default parameter *SNA will be used as the spool files are sent using SNADS.DESTTYPE
This parameter determines the type of remote system. The default *OS400 will be used for this parameter.
The parameters mentioned above will exist in the new file that will replace the old XFPTFROQ (Spool file attributes) file. The CRTOUTQ command for remote printing shall only be executed through the WRKRMTWTR command. If any of the parameters for the remote output queue needs to be changed, all modification must be done through this command. The new output queue will be owned by the group profile QPGMR.
The STRRMTWTR command will be executed immediately following CRTOUTQ command (for new remote output queues). An option will also be available on the screen to start the output queues for remote printing.
TSSOQN | 10 | A | Source Output Queue Name |
TSSOQL | 10 | A | Source Output Queue Library |
TSSOQT | 50 | A | Source Output Queue Description |
TSTGTM | 10 | A | Target (Remote) Machine |
TSTOQN | 10 | A | Target Output Queue Name |
TSTOQL | 10 | A | Target Output Queue Library |
TSRMOQ will reside on all machines. The fields will contain the parameters that drive the creation of the remote output queue.
This screen will be used to show the overall status of each of the remote output queues in the system, whether they are either started or ended. This display will use TCRMOQ to view all the remote output queues added.
An option number can be entered next to one or more source output queues. When Enter is pressed, the function associated with the option is performed for each of the selected output queues (e.g. 1=Start, 2=Edit, 3=Hold, 4=End, 5=Work with OUTQ, 6=Release, 13=Delete).
1=Start
To Start the Remote Writer
(STRRMTWTR), enter this option next to the source output queue to
start.
Starting an output queue that is already started will not cause an abnormal termination. Instead, a warning message will be sent to inform the user that the writer has already been started.
If the start remote writer is successful, a completion message will be displayed at the bottom of the screen informing you that the "Reader or writer is submitted to job queue QSPL". Press F5 to update the status on the list.
2=Edit
Enter this option to change the description or target information
for the source output queue. Another window screen will be
display to allow the user to change the description & target
information. The source output queue & library name cannot be
changed.
In order to change the target information for the source output queue, the source output queue writer status must be ended (status is *NA for Not Attached). If the status is STR (Started), when you press Enter from the window display, a warning message will be displayed to press F12 and end the writer first.
3=Hold
This option holds the active writer. The writer status must be
started (STR) for this option to work.
This option holds the writer. The writer status changes from STR status to HLD status. When the writer is on Hold status, non of the spool output files get transmitted to the remote output queue. This is very useful if you wish to change the spool file attributes of the spool files residing in the source output queue.
4=End
This option will end the writer immediately. The writer status
changes from STR (Started) to *NA (Not Attached) once the command
is successful. A completion message will also be displayed at the
bottom of the screen that says "Writer in the process of
ending".
If you selected this option on a source output queue whose writer status is *NA, a warning message will be displayed at the bottom of the screen that says "Writer not active nor in the job queue".
5=Work with
This option executes the Work with Output Queue (WRKOUTQ) command
for the source output queue. The WRKOUTQ screen enables the user
to change the attributes of the spool files within the output
queue.
If the writer status for the source output queue is *NA, you may take option 5 to work with the source output queue. Within the WRKOUTQ screen, you can change the spool file attributes by taking option 2 right next to the spool files you wish to change.
If the writer status for the source output queue is STR, you may take option 5 to work with the source output queue. All the spool files will be sent automatically to the remote output queue that you have assigned. The status for each spool file becomes SND (sending). In order to save the spool file in the source output queue, you must change the spool attributes to SAVE(*YES). Otherwise, once the spool file is sent to the remote system, the spool file is removed from the source output queue.
6=Release
This option releases the held writer. The writer status must be
in Hold (HLD) status for this option to work. The writer status
changes from HLD status to STR status.
13=Delete
This option deletes the source output queue entry from the TSRMOQ
file. This also deletes the output queue device from the source
machine, and it deletes the output queue device from the target
machine.
If the source output queue writer status is STR, the Delete Output Queue window will display a message informing you that "You cannot delete the output queue, press F12 and end the writer first". You can only delete the output queue if the writer status is *NA.
17=Disconnect
This option enables us to remove the connection between the local
output queue and the remote output queue.
If the source output queue writer status is STR, the Disconnect Output Queue window will display a message informing you that "Writer cannot be disconnected, press F12 and end the writer first". You can only disconnect the output queue if the writer status is *NA.
F3=Exit
Press this function key to exit the program
F5=Refresh
This key will refresh (reload) the entire list of source output
queues. The writer status will be checked again for each source
output queue. This key is recommended after the user request to
Start or End the writer since when these options are requested,
the STRRMTWTR & ENDWTR command are OS/400 requests that are
submitted to batch.
This key will only be displayed when source output queue exist in the TSRMOQ file.
F9=Add
This key will bring up another window screen to add new source
output queue.
F11=Desciption
Press this key to toggle the list to display between the source
output queue description or the Target Output Queue information.
This key will only be displayed when source output queue exist in the TSRMOQ file.
The WRKRMTWTR comprises 2 modules: TS0010R (RPGMOD) and TS0011C (CLMOD). It also uses the UT0010C (CLP) to handle the message subfile display on the screen. TS0010R must be created using the CRTRPGMOD (Create RPG Module) command with the parameter of DBGVIEW(*SOURCE). TS0011C must be created using the CRTCLMOD (Create CL Module) command with the same parameter DBGVIEW(*SOURCE).
When both modules are created, create the program TS0010R using the command:
CRTPGM PGM(TS0010R) MODULE(TS0010R TS0011C)
You must also create the command WRKRMTWTR (Work with Remote Writers) using TS0010R for the CPP.
Enter WRKRMTWTR on a command line to start maintenance. Your initial screen should not have any source output queue listed.
Adding new source output queue
When the Update Local & Remote OUTQ window is displayed, 2 processes happen:
- It checks first whether the source output queue exist or not. It will create the output queue if it does not exist. The target machine and the target output queue name will be attached to the source output queue (RMTSYS and RMTPRTQ parameters respectively on the CRTOUTQ or CHGOUTQ command). The source output queue is started automatically (based on the AUTOSTRWTR(1) parameter).
- It creates the target output queue in the target machine. The create will be ignored if the target output queue already exist in the target machine.
- Messages at the bottom of the screen appear informing the user that the output queues are created.
Changing the Source Output Queue Description
You may change the source output queue description regardless of the writer status (STR or *NA).
- You cannot change any of the target information. If you do, an error message appears at the bottom of the screen "Target info cannot be changed. F12 and end the writer first".
Changing the Source Output Queue Target Information
The writer status for the source output queue must be ended first (Wtr Sts = *NA for Not Attached).
The Update Local & Remote OUTQ window appears. 3 processes happen:
- It ends the writer for the source output queue first. The source output queue must be detached in order to change the output queue information (CHGOUTQ).
- The CHGOUTQ command is executed. The RMTSYS and RMTPRTQ parameters are changed to point to the new Target Machine and Target Output Queue Name respectively.
- It creates the target output queue in the target machine. The create will be ignored if the target output queue already exist in the target machine.
Ending / Detaching Source Output Queue
The writer status for the source output queue must be STR (Started / Attached to a Remote OUTQ) to end the writer.
Deleting Source or/and Target Output Queue
The writer status for the source output queue must be STR (Started / Attached to a Remote OUTQ) to delete the output queue.
- Enter B to delete both the source output queue and the target output queue. The source output record in TSRMOQ will be deleted.
- Enter S to delete the source output queue in the local system. The target output queue in the target machine is not deleted. The source output record in TSRMOQ will be deleted.
- Enter T to delete the target output queue in the target system. The source output queue in the local system is not deleted. The source output record in TSRMOQ will be updated initializing all the target information with blanks.
- If the user requested B or S in step 3, the source output queue is removed from the list.
- If the user requested T in step 3, the source output queue stays on the list but the target information is initialized to blanks. The writer status has a *NA status.
- The actual source output queue device have been changed to have *NONE for the remote system and remote printer queue set to *USER. You cannot start (STRRMTWTR) remote writer to this source output queue. You must change (option 2=Edit from the list) the source output queue to include the new target information to be able to start the remote writer again.
This page hosted by Get your own
Free
Home Page