Strovent SystemsSign in
Reference

Attn and SysReq over TN3270: why the key does nothing

Over TN3270E, Attn is sent as Telnet IP and SysReq as Telnet AO. Both need an SNA-backed server, and SysReq also needs the SYSREQ function agreed.

Attn and SysReq are not ordinary 3270 keys. Enter, Clear, the PF keys and the PA keys travel in the normal 3270 data stream as AID keys (see AID keys (Enter, PF, PA, Clear)). Attn and SysReq come from SNA, where they are signals outside the data stream. Over Telnet, each one has to be carried a special way, and that only works when both ends agree on it.

What each key sends

Classic TN3270 (no "E"). It has no agreed way to send either key. RFC 2355 lists patchy Attn and SysReq support as one of the gaps TN3270E was written to close. Some clients and servers made their own arrangements, so results vary.

TN3270E (RFC 2355):

  • Attn is sent as the Telnet Interrupt Process command (IAC IP, bytes FF F4). A server that represents an SNA terminal passes it to the host application as an SNA SIGNAL, which the application sees as the attention key. A server that represents a non-SNA terminal ignores it.
  • SysReq is sent as the Telnet Abort Output command (IAC AO, bytes FF F5), but only if client and server agreed on the SYSREQ function when the session started. A server that did not agree ignores it. The function is defined only for servers that represent SNA devices.

What SysReq does on the host

In SNA, the keyboard normally talks to the application (the PLU-SLU session). SysReq switches it to the session with VTAM (the SSCP-LU session), where you can type commands from the site's USS table. The one most people use is LOGOFF, to end a hung application session. The same USS table runs the welcome screen; see LOGON APPLID(TSO): the mainframe welcome screen and USS messages.

Over TN3270E it works like this:

  • After the first SysReq, the application can no longer write to your screen.
  • If the server can pass USS commands to VTAM, you talk to VTAM directly.
  • If it cannot, the server handles only LOGOFF (any case), which ends the application session. Anything else gets COMMAND UNRECOGNIZED.
  • Press SysReq again to return to the application. The application is told its screen image may be lost, so expect it to redraw.

Attn is not PA1

They are different keys. PA1 is an AID key: it sends a short message through the normal data stream. Attn is the out-of-band signal described above. In TSO/E, PA1 is documented as the attention interrupt key on a 3270, which is why PA1 stops a looping command there (see Stop a looping TSO command or REXX exec (PA1, IRX0920I)). Other applications may treat the two keys differently, or ignore one of them.

Why the key does nothing

  • The session is classic TN3270. Check whether your client negotiated TN3270E. If the server refused TN3270E, the session may fall back to classic TN3270, and Attn and SysReq have no agreed meaning. See TN3270E and TN3270E negotiation errors.
  • The server is non-SNA. Attn is ignored by design, and the SYSREQ function is not offered.
  • SYSREQ was not agreed. The server did not accept the function during negotiation, so it ignores IAC AO.
  • The application ignores it. Attn reaches the application only as a signal. What happens next is its choice.
  • The client maps the key somewhere else. Many emulators put Attn on Esc and SysReq on a key combination. Check the key map before blaming the host.

On IBM i (5250)

5250 handles both keys differently: the Telnet record header has an ATN bit for Attention and an SRQ bit for System Request, so no Telnet command is needed. On IBM i, System Request opens the System Request menu. See The IBM i System Request menu.

Sources

Spotted a mistake? Email [email protected].