The SNA Print service included with Host Integration Server 2000, 2004, and 2006 defaults to a maximum of 500 concurrent active 3270 print sessions. It helps to define what is considered an “active” 3270 print session. An “active” 3270 print session is one that has received a BID (or Begin Bracket) to start a print job. This session will count against the MaxConcurrentSessions limit until the session is unbound. The session is not released from session count just because it is idle. 3270 print sessions that are activated and show a status of “Active” are not included the count of maximum concurrent active sessions. If the MaxConcurrentSessions limit is reached, the following event will be logged in the application event log:

Event ID: 24
Source: SNA Print Server
Description:
The 3270 Print Provider logged the following warning:

Reached max concurrent sessions - queue message for <internal print session pointer>.

The Host Print service was designed with recommended and hard-coded limits around the number of concurrent active 3270 sessions going all the way back to SNA Server 3.0/4.0 when running on Windows NT 3.5/4.0. In fact, for SNA print sessions configured to use GDI, the limit was and is 240 when running on Windows NT 4.0 SP4. The reason was due to the limited GDI resources on earlier versions of Windows NT.

The following KB articles discussed this in relation to a few customer issues that came up because of this:

239861 SNA Server Host Print service supports 1,024 3270 print sessions
http://support.microsoft.com/default.aspx?scid=kb;EN-US;239861

247816 Some SNA Print Sessions May Remain Pending when Autostarted
http://support.microsoft.com/default.aspx?scid=kb;EN-US;247816

With HIS 2000, a change to the threading model used by the SNA Print Service for 3270 sessions was implemented. The Host Print service was designed to use IO Completion Ports as the threading model. The MaxConcurrentSessions registry parameter was also added at that time to allow customers to go past the 500 concurrent active 3270 print session recommendation if their environments required it. This was not a new concept as the Host Print service previously had a registry parameter called MaxGDISessions as described in the following Knowledge Base article:

180864 Print Sessions Stop with Host Print Service
http://support.microsoft.com/default.aspx?scid=kb;EN-US;180864

In HIS 2000, MaxGDISessions was replaced with MaxConcurrentSessions. This change was made because it was decided to not tie this limit to only print sessions configured to use GDI. In HIS 2000 and later, print sessions that are configured to use PDT files also use GDI resources temporarily because they call CreateDC to get required information from the print driver/device. The device context is released once the information is obtained, so the GDI usage is limited.

With HIS 2000 and later, the maximum number of concurrent active 3270 print sessions is based on the underlying operating system if the MaxConcurrentSessions registry parameter is not explicitly defined. The limit is 240 if HIS is running on Windows NT 4.0 SP4 and 500 if HIS is running on Windows 2000 or later.

If you need to change the default value for MaxConcurrentSessions, you need to add a registry as described here:

Important: This posting contains information about how to modify the registry. Make sure to back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows registry

1. Start Registry Editor (Regedit.exe).

2. Locate and highlight the following key in the registry:

HKEY_LOCAL__MACHINE\System\CurrentControlSet\Services\SnaPrint\Parameters

3. On the Edit menu, click New, and then click DWORD Value and type MaxConcurrentSessions for the value name.

4. Double-click MaxConcurrentSessions, click Decimal for the Base, and then enter the number of MaxConcurrentSessions that you need.

Note: Only enter a value equivalent to the number of print sessions that may be printing concurrently. If the Event ID 24 message is never logged, you should not add this registry entry to change the default value.

5. Click OK.

6. Quit Registry Editor.

The change will take effect the next time the Host Print service (snaprint.exe) is started.