Xpra: Ticket #2741: Autorescue an xpra session

Something happened and my xpra server died (no idea, for some reason xpra start --use-display=true :200 did not save the /run/user/1000/xpra/display-\:200-\$TIMESTAMP.log file before creating it), and I was greeted with this:

$ xpra list
Found the following xpra sessions:
/run/user/1000/xpra:
	LIVE session at :2
	LIVE session at :20
	UNKNOWN session at :200
/run/xpra:
	LIVE session at :2
	LIVE session at :20
	UNKNOWN session at :200
Re-probing unknown sessions in: /run/user/1000/xpra, /run/xpra
^C

Which I interrupted, because something would've happened, and I would have lost my :200 session (from this list or permanently).

I was wondering: can xpra understand if :200 session has an active screen behind it, and auto-salvage the session, similarly to xpra start --use-display=true :200?



Wed, 22 Apr 2020 12:57:31 GMT - stdedos: description changed


Wed, 22 Apr 2020 13:35:05 GMT - Antoine Martin: owner changed

Sounds like a duplicate of #2523.

With v4, you should be able to do:

xpra start --use-display=auto :200

Wed, 22 Apr 2020 13:39:54 GMT - stdedos:

Sounds, but not quite: I am talking explicitly about xpra list

My impression is that xpra list will destroy everything irrevocably.

And, in any case, xpra list will change the state - i.e. having a note that there is/was something in :200. Instead of that, I would like that xpra list would itself re-attach an xpra server, if the DISPLAY is not invalid/empty. Otherwise, just do the cleanup.


Wed, 22 Apr 2020 13:41:52 GMT - Antoine Martin: status changed; resolution set

My impression is that xpra list will destroy everything irrevocably.

It will only remove the socket if the server is dead.

And, in any case, xpra list will change the state - i.e. having a note that there is/was something in :200.

If the server is DEAD, having a dead socket there does not help you.

I would like that xpra list would itself re-attach an xpra server, if the DISPLAY is not invalid/empty. Otherwise, just do the cleanup.

No, sorry, can't be done sanely.

Try comment:2, I suspect it does what you want.


Wed, 22 Apr 2020 13:51:32 GMT - stdedos:

Replying to Antoine Martin:

And, in any case, xpra list will change the state - i.e. having a note that there is/was something in :200.

If the server is DEAD, having a dead socket there does not help you.

That's the thing - I usually have UNKNOWN. I used to think that this meant DEAD instead.


Wed, 22 Apr 2020 14:08:34 GMT - Antoine Martin:

That's the thing - I usually have UNKNOWN. I used to think that this meant DEAD instead.

UNKNOWN sockets are re-probed before being deleted. It usually means that we encountered an error trying to connect to that socket, and that this error is unlikely to be transient. So after trying again, we can be pretty confident that the server is DEAD.


Sat, 23 Jan 2021 05:59:30 GMT - migration script:

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