Menu

Very high cpu resources used by process xrdp!

xrdp
2010-05-12
2013-06-05
  • randolf carter

    randolf carter - 2010-05-12

    Hi,

    First, thanks to all involved for fix the problem about reusing vnc connections. Anyway, I usually do a cvs sincro with the repo to test the latest fixes. Well, I've observed that the lastest CVS source code, hangs process xrdp and uses the 100% of the cpu time.
    The system is centos 5.4 x86_64, ¿Do you want me send you more info?

    Best Regards.

     
  • Giovanni

    Giovanni - 2010-05-13

    Hi,

    same things for me, only with windows client.
    some info:

    pcpanco ~ # ps -f -p 15133
    UID        PID  PPID  C STIME TTY          TIME CMD
    root     15133     1 91 10:51 pts/0    00:11:08 /usr/local/sbin/xrdp

    pcpanco ~ # strace -f -p 15133
    Process 15133 attached with 2 threads - interrupt to quit
    select(7, , , NULL, NULL <unfinished …>
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0
    recv(7, "", 4, 0)           = 0

    pcpanco ~ # lsof -p 15133 -n
    COMMAND   PID USER   FD   TYPE     DEVICE SIZE/OFF    NODE NAME
    xrdp    15133 root  cwd    DIR       8,10    12288   37007 /root
    xrdp    15133 root  rtd    DIR       8,10     4096       2 /
    xrdp    15133 root  txt    REG      254,0   250735  127053 /usr/local/sbin/xrdp
    xrdp    15133 root  mem    REG       8,10   122472   53560 /lib/ld-2.10.1.so
    xrdp    15133 root  mem    REG       8,10  1338832   53582 /lib/libc-2.10.1.so
    xrdp    15133 root  mem    REG       8,10    11256   53656 /lib/libdl-2.10.1.so
    xrdp    15133 root  mem    REG       8,10   125558   53708 /lib/libpthread-2.10.1.so
    xrdp    15133 root  mem    REG       8,10    70760   53713 /lib/libz.so.1.2.3
    xrdp    15133 root  mem    REG      254,0  1293568  281087 /usr/lib/libcrypto.so.0.9.8
    xrdp    15133 root  mem    REG      254,0   210789  127048 /usr/local/lib/xrdp/libxrdp.so.0.0.0
    xrdp    15133 root  mem    REG      254,0   126750  126415 /usr/local/lib/xrdp/libcommon.so.0.0.0
    xrdp    15133 root    0u   CHR        1,3      0t0      90 /dev/null
    xrdp    15133 root    1u   CHR        1,3      0t0      90 /dev/null
    xrdp    15133 root    2u   CHR        1,3      0t0      90 /dev/null
    xrdp    15133 root    3u  unix 0xf2b28780      0t0 1362025 /tmp/xrdp_00003b1d_listen_pro_done_event
    xrdp    15133 root    4u  unix 0xf2b28180      0t0 1362027 /tmp/xrdp_00003b1d_main_term
    xrdp    15133 root    5u  unix 0xf2b28580      0t0 1362029 /tmp/xrdp_00003b1d_main_sync
    xrdp    15133 root    6u  IPv4    1362031      0t0     TCP *:3389 (LISTEN)
    xrdp    15133 root    7u  IPv4    1363391      0t0     TCP 10.8.16.18:3389->10.8.16.22:4033 (CLOSE_WAIT)
    xrdp    15133 root    8u  unix 0xf1d2a880      0t0 1363392 /tmp/xrdp_00003b1d_process_self_term_event_00000002

    best regards

     
  • Thomas Mueller

    Thomas Mueller - 2010-06-09

    Hello,

    i see the same problem on the linux client "rdesktop", also.
    After some hours and login and logout sessions a unused xrdp process takes a lot of cpu time.
    I'm using the cvs xrpd version from 2010-06-09 on debian 5.0. An older version of my pc, works well.

    best regards,

    Thomas M.

     
  • Jörg Schneider

    Jörg Schneider - 2010-06-10

    The following patch solves the problem for me:

    $ diff -u xrdp-0.5.0~20100610cvs/common/trans.c trans.c
    --- xrdp-0.5.0~20100610cvs/common/trans.c       2010-05-04 09:37:22.000000000 +0200
    +++ trans.c     2010-06-10 17:07:59.000000000 +0200
    @@ -214,6 +214,7 @@
             /* error */
             self->status = TRANS_STATUS_DOWN;
             rv = 1;
    +        break;
           }
         }
         else if (rcvd == 0)
    @@ -221,6 +222,7 @@
           /* error */
           self->status = TRANS_STATUS_DOWN;
           rv = 1;
    +      break;
         }
         else
         {
    
     
  • Giovanni

    Giovanni - 2010-06-11

    for me too.

    thanks a lot.

    bye.

     
  • nicolar

    nicolar - 2010-06-14

    Why not fix also trans_force_write_s?

    --- trunk/prjVari/xrdp/common/trans.c   2010/06/11 09:26:10 2680
    +++ trunk/prjVari/xrdp/common/trans.c   2010/06/11 13:26:55 2686
    @@ -273,6 +273,7 @@
             /* error */
             self->status = TRANS_STATUS_DOWN;
             rv = 1;
    +   break;
           }
         }
         else if (sent == 0)
    @@ -280,6 +281,7 @@
           /* error */
           self->status = TRANS_STATUS_DOWN;
           rv = 1;
    +      break;
         }
         else
         {
    
     
  • Jörg Schneider

    Jörg Schneider - 2010-06-15

    Good point.
    I'll update the patch in the bug tracker.

     

Log in to post a comment.