xpra icon
Bug tracker and wiki

This bug tracker and wiki are being discontinued
please use https://github.com/Xpra-org/xpra instead.

Opened 4 years ago

Closed 4 years ago

Last modified 16 months ago

#1698 closed defect (fixed)

server fails when logging to ~/.xpra/

Reported by: Boruch Owned by: Antoine Martin
Priority: minor Milestone: 2.2
Component: server Version: trunk
Keywords: configuration log-dir logging Cc:

Description (last modified by Antoine Martin)

The parsing for option 'log-dir' does not seem to be expanding shell variables, such as ~, $HOME, or $USER, and causes the server to fail when the 'log-dir' option is set with those variables.


When changing option log-dir in file /etc/xpra/60_server.conf from its default "auto" to "~/.xpra", the xpra server fails to launch. The alternative "~/.xpra" is provided for in the comments for the config file. The entire STDERR output is

Warning: cannot use the system proxy for 'start' subcommand,
 failed to connect to '/run/xpra/system':
 [Errno 111] Connection refused
InitException: cannot open log file '~/.xpra/S9585.log': [Errno 2] No such file or directory: '~/.xpra/S9585.log'
xpra initialization error:
 cannot open log file '~/.xpra/S9585.log': [Errno 2] No such file or directory: '~/.xpra/S9585.log'

However, the directory does exist, with adequate permissions, and xpra does create two files there (a commented-out 'xpra.conf', and a 'run-xpra' executable).

When reverting the log-dir option to its default, 'auto', the server does start, but the log file, at /run/user/$UID/xpra/:1.log includes:

failed to rename Xorg log file from '/run/user/1007/xpra/Xorg.S13030.log' to '/run/user/1007/xpra/Xorg.:1.log'
 [Errno 2] No such file or directory
-- END---------------

The log files that do exist are: :1.log and Xorg.S13030.log.old


Experimenting with the option on both the command-line and in the config file showed that the server WOULD succeed when the explicit path to ~/.xpra was used, ie. /home/.../.xpra, and would fail with the same output as above for $HOME/.xpra and /home/$USER/.xpra

Change History (4)

comment:1 Changed 4 years ago by Antoine Martin

Description: modified (diff)
Status: newassigned

failed to rename Xorg...

This one is not a bug in xpra but a bug in the Xorg server: #1192.
There is a patch, which is languishing upstream. I think they need a nudge.

As for the rest, I will take a look.
Please always include full OS version, as this may be relevant when debugging.

comment:2 Changed 4 years ago by Boruch


Version: Xpra gtk2 client version 2.1.3-r17247 64-bit
Platform: Debian Stretch / Devuan Ascii
Kernel: Linux 4.9.0-3-amd64 [Debian version: 4.9.30-2+deb9u5 (2017-09-19)]

comment:3 Changed 4 years ago by Antoine Martin

Resolution: fixed
Status: assignedclosed

Fixed in r17502. (I will have to come up with a more concise fix for older branches)

comment:4 Changed 16 months ago by migration script

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1698

Note: See TracTickets for help on using tickets.