Results 1 to 5 of 5

Thread: No more PTYs

  1. #1
    Junior Member Newbie
    Join Date
    Dec 2005
    Posts
    1

    Default No more PTYs

    I keep getting this "No more PTYs" error from screen. In /dev/ I have 356 ptys listed and I now I'm not using that many shells. Does this have anything to do with being on a vps?

  2. #2
    Former Employee Newbie
    Join Date
    Oct 2005
    Posts
    31

    Default

    Hello,

    Our VPS products have a limit in place for the maximum number of PTYs. You can see the current limit vs usage by logging into your VPS as root via ssh and executing the command:

    cat /proc/user_beancounters | egrep 'pty|lim'

    The output should be something similar to :

    Code:
    # cat /proc/user_beancounters | egrep 'pty|lim'
           uid  resource           held    maxheld    barrier      limit    failcnt
                numpty                1          1         16         16          0
    In this instance the maximum number is 16.

    If you need the maximum number of this value increased you may upgrade your VPS to the next product level in your category. To do so, please submit a support ticket via https://www.spry.com/support/myaccount or contact our sales department at sales@spry.com.

    Please let me know if that's not the answer you were looking for or if you have any additional questions.

    Regards,
    Dustin

    Spry Hosting Support
    https://www.spry.com/support/myaccount/
    Last edited by spry_dustin; 12-08-2005 at 11:24 AM.

  3. #3
    Junior Member Newbie
    Join Date
    Apr 2007
    Posts
    23

    Default Same on FC4

    #cat /proc/user_beancounters | egrep 'pty|lim'
    uid resource held maxheld barrier limit failcnt
    numpty 1 1 32 32 0


    As root, 'screen' runs no problem eating up more PTYs, but as any user it complains about no more PTYs available. Any ideas?

  4. #4
    Former Employee Newbie
    Join Date
    Nov 2005
    Posts
    56

    Default

    Quote Originally Posted by portalgod
    #cat /proc/user_beancounters | egrep 'pty|lim'
    uid resource held maxheld barrier limit failcnt
    numpty 1 1 32 32 0


    As root, 'screen' runs no problem eating up more PTYs, but as any user it complains about no more PTYs available. Any ideas?
    Most likely your user account doesn't have the permissions to read or write to the pty devices. Check the permissions on /dev/pty* and see if you are able to access them.

  5. #5
    Junior Member Newbie
    Join Date
    Dec 2006
    Location
    Seattle, WA
    Posts
    8

    Default

    My Spry VPS server did not have all of the devices actually set up. Here is how you can fix that oversight.

    You will probably find something like this.
    Code:
    server> su -
    server# cd /dev
    server# ls
    MAKEDEV  kmem  ptmx   ptyp4  ram0     stdin   ttyp2  ttyp7
    core     log   ptyp0  ptyp5  ram1     stdout  ttyp3  urandom
    fd       mem   ptyp1  ptyp6  ramdisk  tty     ttyp4  vzfs
    full     null  ptyp2  ptyp7  random   ttyp0   ttyp5  zero
    initctl  port  ptyp3  ram    stderr   ttyp1   ttyp6
    Only 8 PTY/TTY pairs have actually been created. We want more!

    You can let MAKEDEV create 256 devices. The ones above 32 will just be useless filesystem clutter though.
    Code:
    server# ./MAKEDEV pty && ./MAKEDEV tty
    To avoid the clutter you can create only the devices you need.
    Code:
    server# ./MAKEDEV ptyp8 && ./MAKEDEV ttyp8
    server# ./MAKEDEV ptyp9 && ./MAKEDEV ttyp9
    server# ./MAKEDEV ptypa && ./MAKEDEV ttypa
    server# ./MAKEDEV ptypb && ./MAKEDEV ttypb
    server# ./MAKEDEV ptypc && ./MAKEDEV ttypc
    server# ./MAKEDEV ptypd && ./MAKEDEV ttypd
    server# ./MAKEDEV ptype && ./MAKEDEV ttype
    server# ./MAKEDEV ptypf && ./MAKEDEV ttypf
    server# ./MAKEDEV ptyq0 && ./MAKEDEV ttyq0
    server# ./MAKEDEV ptyq1 && ./MAKEDEV ttyq1
    server# ./MAKEDEV ptyq2 && ./MAKEDEV ttyq2
    server# ./MAKEDEV ptyq3 && ./MAKEDEV ttyq3
    server# ./MAKEDEV ptyq4 && ./MAKEDEV ttyq4
    server# ./MAKEDEV ptyq5 && ./MAKEDEV ttyq5
    server# ./MAKEDEV ptyq6 && ./MAKEDEV ttyq6
    server# ./MAKEDEV ptyq7 && ./MAKEDEV ttyq7
    server# ./MAKEDEV ptyq8 && ./MAKEDEV ttyq8
    server# ./MAKEDEV ptyq9 && ./MAKEDEV ttyq9
    server# ./MAKEDEV ptyqa && ./MAKEDEV ttyqa
    server# ./MAKEDEV ptyqb && ./MAKEDEV ttyqb
    server# ./MAKEDEV ptyqc && ./MAKEDEV ttyqc
    server# ./MAKEDEV ptyqd && ./MAKEDEV ttyqd
    server# ./MAKEDEV ptyqe && ./MAKEDEV ttyqe
    server# ./MAKEDEV ptyqf && ./MAKEDEV ttyqf
    And that's all there is to it.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •