xpra icon
Bug tracker and wiki

Opened 3 weeks ago

Closed 3 weeks ago

Last modified 3 weeks ago

#1948 closed defect (fixed)

shadow server unit test failure caused by RFB

Reported by: Antoine Martin Owned by: Antoine Martin
Priority: blocker Milestone: 2.4
Component: server Version: trunk
Keywords: Cc:

Description

======================================================================
FAIL: test_start_all (__main__.ShadowOptionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./unittests/unit/server/mixins/shadow_option_test.py", line 15, in test_start_all
    self._test_all("shadow")
  File "/home/antoine/projects/Xpra/trunk/src/unittests/unit/server/mixins/server_mixins_option_test_util.py", line 179, in _test_all
    self._test(subcommand, options=options)
  File "/home/antoine/projects/Xpra/trunk/src/unittests/unit/server/mixins/server_mixins_option_test_util.py", line 152, in _test
    self.stop_server(server, "stop", *connect_args)
  File "/home/antoine/projects/Xpra/trunk/src/unittests/unit/server_test_util.py", line 306, in stop_server
    assert pollwait(stopit, STOP_WAIT_TIMEOUT) is not None, "%s command failed to exit" % subcommand
AssertionError: stop command failed to exit

The server ends up servicing the RFB client but nothing after that, all connections end up timing out.

Here are the steps to reproduce on Fedora by running individual commands rather than running through the unit test:

  • run a vfb which will be used by the clients:
    /usr/libexec/Xorg -noreset -novtswitch -nolisten tcp \
       +extension GLX +extension RANDR +extension RENDER \
       -auth $XAUTHORITY -logfile /tmp/Xorg.:100.log \
       -config /etc/xpra/xorg.conf :100
    
  • and another one we're going to shadow:
    /usr/libexec/Xorg -noreset -novtswitch -nolisten tcp \
       +extension GLX +extension RANDR +extension RENDER \
       -auth $XAUTHORITY -logfile /tmp/Xorg.:200.log \
       -config /etc/xpra/xorg.conf :200
    
  • start the shadow server:
    python2 /usr/bin/xpra --pulseaudio=no --start=xterm shadow :200 \
       --no-daemon --readonly=True --bind-tcp=0.0.0.0:10000 \
       -d shadow,rfb
    
  • connect a VNC client:
    DISPLAY=:100 /usr/bin/vncviewer localhost::10000
    

(and wait 5 seconds for it to connect)

  • try to connect any client:
    xpra version :200
    

Change History (1)

comment:1 Changed 3 weeks ago by Antoine Martin

Priority: majorblocker
Resolution: fixed
Status: newclosed

Also reproducible using the local display for the VNC client.
Killing the VNC client leaves the server in this same hung state.
Tried reducing the vfb resolution with DISPLAY=:200 xrandr -s 1280x768.
Reducing the shadow refresh rate does "fix" things:

XPRA_SHADOW_REFRESH_DELAY=200 xpra shadow ...

That's because we can't block on a queue waiting to send packets, r20355 fixes that.

Related improvements and fixes:

  • r20350 usual py3k strings nonsense..
  • r20352 always set keymap
  • r20356 adds a better, non-blocking rate control mechanism
  • r20358 lower default vfb size for tests (1080p - configurable), wait longer for xpra client to settle down
  • r20360 don't try to test RFB connections with --windows=no

Backports will follow, will follow up in #1949.

Last edited 3 weeks ago by Antoine Martin (previous) (diff)
Note: See TracTickets for help on using tickets.