SET_SERVER_SBS_ROUTING procedure

The SET_SERVER_SBS_ROUTING procedure provides the ability to configure some servers to utilize alternative subsystems based on the user profile that is establishing the connection. The user profile can be a group profile or a supplemental group profile.

This procedure allows an administrator to reposition specific users into alternate, non-default, subsystems. When configured, new incoming TCP/IP server connections will use the alternate subsystem. If the server is configured to route to a user-specified subsystem by incoming TCP/IP address as well, the job will first route to the subsystem configured for that TCP/IP address and then immediately attempt to route to the subsystem configured for the connecting user profile.

By default, all users for the following servers utilize the same subsystem:
Table 1. Servers and default subsystems
Server Description Server Name Default subsystem
Central server QZSCSRVS QUSRWRK
Database server QZDASOINIT QUSRWRK
Data queue server QZHQSSRV QUSRWRK
DDM QRWTSRVR QUSRWRK
DRDA QRWTSRVR QUSRWRK
File server QPWFSERVSO QSERVER
Network print server QNPSERVS QUSRWRK
Remote command server QZRCSRVS QUSRWRK

For more information on these servers see DRDA and DDM overview and Host servers by function.

Read syntax diagramSkip visual syntax diagramSET_SERVER_SBS_ROUTING( AUTHORIZATION_NAME =>  authorization-name, SERVER_NAME =>  server-name, SUBSYSTEM_NAME =>  subsystem-name,ALLOW_ROLLOVER => allow-rollover)
The schema is QSYS2.
authorization-name
A character or graphic string expression that identifies an existing user or group profile name.
server-name
A character or graphic string expression that identifies the name of the server job that will be rerouted to subsystem-name for authorization-name whenever a connection is initiated to this server job. Valid server-name values are:
  • QNPSERVS
  • QPWFSERVSO
  • QRWTSRVR
  • QZDASOINIT
  • QZHQSSRV
  • QZRCSRVS
  • QZSCSRVS
The special value of *ALL can be used to indicate all of the valid server-name values.
subsystem-name
A character or graphic string expression that identifies the name of the subsystem that will be used for the specified user, instead of the default subsystem, whenever a connection is initiated to the specified server job. No validation is done on subsystem-name to make sure it is a valid and active subsystem.
Specifying the null value will clear the entry for this authorization-name and server-name.
allow-rollover
A character or graphic string expression that indicates the action to take if the specified subsystem is not active. Valid values are:
NO
If the alternate subsystem cannot be used, the connection request will fail.
YES
If the alternate subsystem cannot be used, the connection request will succeed by using a batch immediate job in the default subsystem.
If this parameter is not specified, the default is YES.

Notes

Authorization: The user calling this procedure must have *SECADM special authority. In addition, *OBJMGT and *USE is required to the user profile.

The Prestart Job Entry must specify the subsystem-name.

If, for any reason, the alternate subsystem cannot be used to establish the connection, the connection will run in the default subsystem (or the last subsystem it was successfully routed to) as a batch immediate job. An example of this would be if the authorization-name does not have *USE authority to the subsystem description for subsystem-name.

If routing has been configured for a user profile, the user profile configuration will always be used, regardless of any group profile configuration. A group profile configuration will take precedence over any supplemental group profile configuration.

Examples

  • Set new incoming DRDA and DDM TCP/IP server connections for user profile TIM to route to subsystem TIMSUBSYS.
    CALL QSYS2.SET_SERVER_SBS_ROUTING('TIM','QRWTSRVR','TIMSUBSYS')
  • Reset incoming DRDA and DDM TCP/IP server connections for user profile TIM back to the original default subsystem.
    CALL QSYS2.SET_SERVER_SBS_ROUTING('TIM','QRWTSRVR',NULL)
  • Configure group profile ADMIN to use an alternate subsystem for all of the servers supported by this procedure. Do not permit a connection request to rollover to use QUSRWRK.
    CALL QSYS2.SET_SERVER_SBS_ROUTING('ADMIN','*ALL','ADHOCSBS','NO')
    
  • Set new incoming Database server TCP/IP connections for user profile BOB to route to subsystem BOBSUBSYS.
    CALL QSYS2.SET_SERVER_SBS_ROUTING('BOB','QZDASOINIT','BOBSUBSYS')
  • Construct a subsystem that will constrain the amount of system resources available to users who are known to execute expensive queries.
    CRTSBSD SBSD(QGPL/ADHOCSBS) POOLS((1 *BASE)) TEXT('Adhoc DRDA users SBS')
    
    CRTJOBQ QGPL/ADHOCJOBQ TEXT('Adhoc DRDA users job queue')
    
    ADDJOBQE SBSD(QGPL/ADHOCSBS) JOBQ(QGPL/ADHOCJOBQ) MAXACT(25) SEQNBR(40)
    
    CRTCLS CLS(QGPL/ADHOCCLS) RUNPTY(55) TIMESLICE(100) TEXT('Adhoc DRDA users class')
    
    ADDPJE SBSD(QGPL/ADHOCSBS) PGM(QSYS/QRWTSRVR) JOBD(QGPL/QDFTSVR) CLS(QGPL/ADHOCCLS)
    
    STRSBS SBSD(QGPL/ADHOCSBS)
    
    CALL QSYS2.SET_SERVER_SBS_ROUTING('SLFUSER','QRWTSRVR','ADHOCSBS')