[winswitch] How data flows through Xpra server and proxy

Antoine Martin antoine at nagafix.co.uk
Fri Nov 18 05:50:53 GMT 2016


Please do not top-post.

On 18/11/16 12:43, Aaditya Shidham via shifter-users wrote:
> When you say, " It connects to the
> X11 server using its unix domain sockets and will use shared memory
> (XShm) if available (it almost always is)."
> 
> Where are these unix domain sockets stored usually in the filesystem and
/tmp/.X11-unix/

> where in the codebase is this socket created and where is the graphics data
> sent / received?
This code lives in the X11 libraries:
https://tronche.com/gui/x/xlib/display/opening.html

> Also where in the source code is the socket located at
> ~/.xpra/ip-XXX-XX-XX-5455 read from / written to?
I'm not sure what you're asking, the code that interacts with the
sockets is in various places, ie:
http://xpra.org/trac/browser/xpra/trunk/src/xpra/platform/dotxpra.py
http://xpra.org/trac/browser/xpra/trunk/src/xpra/scripts/main.py
http://xpra.org/trac/browser/xpra/trunk/src/xpra/scripts/server.py

The actual socket path definitions are per-platform, here's the stub:
http://xpra.org/trac/browser/xpra/trunk/src/xpra/platform/paths.py

If you tell us what you're trying to do, we can give you more specific
pointers.

Cheers
Antoine


> 
> On Thu, Nov 17, 2016 at 8:26 PM, Antoine Martin via shifter-users <
> shifter-users at lists.devloop.org.uk> wrote:
> 
>> On 18/11/16 08:35, Aaditya Shidham via shifter-users wrote:
>>> Hello,
>>>
>>> I have the following invocation of Xpra:
>>> xpra start :5455 --bind-tcp=0.0.0.0:5555 --html=on --no-daemon
>>> And then I can get graphical programs in an Xpra client to load through
>>> DISPLAY=:5455 xeyes
>> Use this instead:
>> xpra (..) --start=xeyes
>> So the application won't be killed if your ssh / xterm dies.
>>
>>> I'm curious how data for the x11 packets go through the Xpra program. It
>>> seems that Xvfb is what handles the xeyes by storing the display in
>> memory.
>>> How does this data then pass to the rest of Xpra? According to (
>>> http://stackoverflow.com/questions/12050021/how-to-
>> make-xvfb-display-visible),
>>> I need to use -fbdir to access this virtual memory, but this isn't used
>>> when Xvfb is invoked by Xpra.
>> xpra is just like any other X11 client application, it connects to the
>> X11 server using its unix domain sockets and will use shared memory
>> (XShm) if available (it almost always is).
>>
>> This does not need "-fbdir" which is specific to Xvfb and serves a
>> different purpose.
>>
>>> Also where is the local Unix socket used? I can see where the local
>> domain
>>> Unix socket is set inside xpra/scripts/server.py, but I don't see where
>> it
>>> is ever used. It seems to be named partially after the :5455
>>> (~/.xpra/ip-XXX-XX-XX-5455), but where are the two connected?
>> That's xpra's socket, which is used for xpra connections, not X11
>> connections.
>> You can find more details on where this is going here:
>> http://xpra.org/trac/ticket/1129#comment:23
>> http://xpra.org/trac/wiki/Network
>>
>> Cheers
>> Antoine
>> _______________________________________________
>> shifter-users mailing list
>> shifter-users at lists.devloop.org.uk
>> http://lists.devloop.org.uk/mailman/listinfo/shifter-users
>>
> _______________________________________________
> shifter-users mailing list
> shifter-users at lists.devloop.org.uk
> http://lists.devloop.org.uk/mailman/listinfo/shifter-users
> 




More information about the shifter-users mailing list