X2Go Bug report logs - #1409
Fwd: [Bug 1754220] New: x2gocleansessions kills user desktop shortly after login (~20 secs)

version graph

Package: x2goserver; Maintainer for x2goserver is X2Go Developers <x2go-dev@lists.x2go.org>; Source for x2goserver is src:x2goserver.

Reported by: Orion Poplawski <orion@nwra.com>

Date: Sun, 22 Sep 2019 22:55:02 UTC

Severity: normal

Tags: patch

Found in version

Full log

🔗 View this message in rfc822 format

X-Loop: owner@bugs.x2go.org
Subject: Bug#1409: Fwd: [Bug 1754220] New: x2gocleansessions kills user desktop shortly after login (~20 secs)
Reply-To: Orion Poplawski <orion@nwra.com>, 1409@bugs.x2go.org
Resent-From: Orion Poplawski <orion@nwra.com>
Resent-To: x2go-dev@lists.x2go.org
Resent-CC: X2Go Developers <x2go-dev@lists.x2go.org>
X-Loop: owner@bugs.x2go.org
Resent-Date: Sun, 22 Sep 2019 22:55:02 +0000
Resent-Message-ID: <handler.1409.B.15691927246842@bugs.x2go.org>
Resent-Sender: owner@bugs.x2go.org
X-X2Go-PR-Message: report 1409
X-X2Go-PR-Package: x2goserver
X-X2Go-PR-Keywords: patch
Received: via spool by submit@bugs.x2go.org id=B.15691927246842
          (code B); Sun, 22 Sep 2019 22:55:02 +0000
Received: (at submit) by bugs.x2go.org; 22 Sep 2019 22:52:04 +0000
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
X-Spam-Status: No, score=-1.9 required=3.0 tests=BAYES_00,SPF_HELO_NONE,
	URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2
Received: from mail.nwra.com (mail.nwra.com [])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTPS id 455B35DAC1
	for <submit@bugs.x2go.org>; Mon, 23 Sep 2019 00:51:56 +0200 (CEST)
Received: from rufous.cora.nwra.com (c-67-166-25-97.hsd1.co.comcast.net [])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client did not present a certificate)
	by mail.nwra.com (Postfix) with ESMTPSA id B2DFA3403AF
	for <submit@bugs.x2go.org>; Sun, 22 Sep 2019 15:51:54 -0700 (PDT)
To: submit@bugs.x2go.org
From: Orion Poplawski <orion@nwra.com>
Organization: NorthWest Research Associates
X-Forwarded-Message-Id: <bug-1754220-140047@https.bugzilla.redhat.com/>
Message-ID: <5935c822-366f-dbbf-2c34-10160529c2b5@nwra.com>
Date: Sun, 22 Sep 2019 16:51:51 -0600
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101
MIME-Version: 1.0
In-Reply-To: <bug-1754220-140047@https.bugzilla.redhat.com/>
Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-256; boundary="------------ms000008030400000905090002"
[Message part 1 (text/plain, inline)]
Package: x2goserver
Tags: patch

-------- Forwarded Message --------
Subject: [Bug 1754220] New: x2gocleansessions kills user desktop shortly 
after login (~20 secs)
Date: Sat, 21 Sep 2019 22:07:05 +0000
From: bugzilla@redhat.com
To: orion@nwra.com


            Bug ID: 1754220
           Summary: x2gocleansessions kills user desktop shortly after
                    login (~20 secs)
           Product: Fedora
           Version: 30
            Status: NEW
         Component: x2goserver
          Assignee: orion@nwra.com
          Reporter: gregory.lee.bartholomew@gmail.com
        QA Contact: extras-qa@fedoraproject.org
                CC: orion@nwra.com
  Target Milestone: ---
    Classification: Fedora

Description of problem:

Randomly, user sessions are booted after logging in. Usually a stable
connection can be acquired after a few retries.

Version-Release number of selected component (if applicable):

# rpm -q x2goserver

How reproducible:


Steps to Reproduce:

1. Login and wait 20 to 30 seconds (I was using LXDE and occasionally 
"sudo -i" in a terminal, but I don't think that is necessary to trigger the

Actual results:

Session killed shortly after logging in.

Expected results:

Session should not be killed.

Additional info:

To troubleshoot this issue, I did the following:

# mkdir /etc/systemd/system/x2gocleansessions.service.d
# cat << END > /etc/systemd/system/x2gocleansessions.service.d/override.conf
ExecStart=/usr/sbin/x2gocleansessions -d
# systemctl daemon-reload
# systemctl restart x2gocleansessions.service

After sprinkling /usr/sbin/x2gocleansessions with printf statements and
x2gocleansessions.service a few times, I eventually traced the problem 
down to
check_pid() being called with a NULL value for $pid (not sure why; seems 
to be
some sort of race condition). The following patch seems to resolve the 

--- x2gocleansessions.a 2019-09-21 16:46:53.327948763 -0500
+++ x2gocleansessions.b 2019-09-21 16:46:10.076184475 -0500
@@ -62,7 +62,7 @@
        my $pid=shift;
        my $sess=shift;
        my $sec=shift;
-       if ($sec < 30)
+       if (!$pid || $sec < 30)
                return 1;

You are receiving this mail because:
You are on the CC list for the bug.
You are the assignee for the bug.

[smime.p7s (application/pkcs7-signature, attachment)]

Send a report that this bug log contains spam.

X2Go Developers <owner@bugs.x2go.org>. Last modified: Wed Aug 10 11:43:15 2022; Machine Name: ymir.das-netzwerkteam.de

X2Go Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.