How can I have more than 48 pseudo-ttys?



For Solaris 7 and before, edit /etc/system and add the following line:



* System V pseudo terminals

set pt_cnt = <num>


Halt the system and boot -r.


You can essentially have as many as you like, but you'll probably
run into some other limit somewhere. More than 3000 are supported.
Solaris 2.6 and earlier have telnet/rlogin daemons that do not
support more than 3844 sessions each. That restriction is lifted
in Solaris 7.


Starting with Solaris 8, the number of pseudo terminals grows
dynamically on demand. Setting the "pt_cnt" variable is no longer
needed. The system still imposes internal limit based on available
resources which is, usually, very high. In the rare case when this
limit is still inadequate administrator may set pt_cnt variable to
override it. If pt_cnt is set to anything less than the
system-defined limit, its value is ignored.


If administrators want to explicitly limit the maximum number of
allocated ptys, they should set pt_max_pty variable which specifies
the maximum number of ptys that can be created in the system. The
default value 0 means that the maximum is automatically determined
by the system based on the amount of memory.


There is no need to reboot the system with -r flag after changing
these limit variables on Solaris 8 and later. The changes start
working immediately upon being set, even if they are set on the
running system by adb or some other means.


The pty driver creates entries in the /dev/pts directory as needed
and these entries are never removed automatically, so they do not
indicate the actual amount of ptys allocated by the system.


Some die-hard system administrator myths as well as some Sun
documentation claim that you have to increase "sad_cnt", "sadcnt"
or "nautopush" when adding ptys. There is no truth in this.


In the unlikely event that you run out of BSD-style ptys,
you can increase them as well. The maximum here is currently
176 for pty[p-z][0-9a-f]. This is somewhat less that the BSD
maximum of 256 limited by 8 bit device minor numbers.


BSD ttys are awkward to use and all programs I found support SYSV
ptys without trouble.



* You don't need this. Increasing this value too much usually
* just wastes memory.
* BSD applications never support more than 256 ptys.
* Solaris 2.x supports no more than 176 BSD ptys.

set npty = <num>


But you're not there yet, you also need to edit /etc/iu.ap and
substitute the new value of "npty-1" for the "47" on the following
line, in case you do increase the number of BSD style ptys.



ptsl 0 47 ldterm ttcompat



Halt the system and boot -r.





UNIXguide.net
English to Visayan Cebuano Dictionary
Suggest a Site
Visayan Cebuano to English Dictionary