X2Go Bug report logs - #1145
x2godbadmin + postgres + non-existent home directory = wrong ownerships

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

Reported by: Stefan Baur <X2Go-ML-1@baur-itcs.de>

Date: Tue, 7 Feb 2017 13:15:02 UTC

Severity: normal

Full log

🔗 View this message in rfc822 format

X-Loop: owner@bugs.x2go.org
Subject: Bug#1145: [X2Go-Dev] Bug#1145: Bug#1145: x2godbadmin + postgres + non-existent home directory = wrong ownerships
Reply-To: Walid MOGHRABI <w.moghrabi@servicemagic.eu>, 1145@bugs.x2go.org
Resent-From: Walid MOGHRABI <w.moghrabi@servicemagic.eu>
Resent-To: x2go-dev@lists.x2go.org
Resent-CC: X2Go Developers <x2go-dev@lists.x2go.org>
X-Loop: owner@bugs.x2go.org
Resent-Date: Wed, 08 Feb 2017 09:00:02 +0000
Resent-Message-ID: <handler.1145.B1145.14865443177336@bugs.x2go.org>
Resent-Sender: owner@bugs.x2go.org
X-X2Go-PR-Message: followup 1145
X-X2Go-PR-Package: x2goserver
Received: via spool by 1145-submit@bugs.x2go.org id=B1145.14865443177336
          (code B ref 1145); Wed, 08 Feb 2017 09:00:02 +0000
Received: (at 1145) by bugs.x2go.org; 8 Feb 2017 08:58:37 +0000
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on
X-Spam-Status: No, score=0.0 required=3.0 tests=BAYES_40,MIME_QP_LONG_LINE,
	URIBL_BLOCKED autolearn=ham version=3.3.2
Received: from localhost (localhost [])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTP id 45A1B5DA49
	for <1145@bugs.x2go.org>; Wed,  8 Feb 2017 09:58:35 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at ymir.das-netzwerkteam.de
Received: from ymir.das-netzwerkteam.de ([])
	by localhost (ymir.das-netzwerkteam.de []) (amavisd-new, port 10024)
	with ESMTP id wcUoyC103F+j for <1145@bugs.x2go.org>;
	Wed,  8 Feb 2017 09:58:28 +0100 (CET)
X-Greylist: delayed 334 seconds by postgrey-1.34 at ymir.das-netzwerkteam.de; Wed, 08 Feb 2017 09:58:28 CET
Received: from zm-01.servicemagic.eu (zm-01.servicemagic.eu [])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTPS id 7552E5DA2D
	for <1145@bugs.x2go.org>; Wed,  8 Feb 2017 09:58:28 +0100 (CET)
Received: from localhost (localhost.localdomain [])
	by zm-01.servicemagic.eu (Postfix) with ESMTP id 284C3812E4E87;
	Wed,  8 Feb 2017 09:52:53 +0100 (CET)
X-Amavis-Modified: Mail body modified (using disclaimer) -
X-Virus-Scanned: amavisd-new at servicemagic.eu
Received: from zm-01.servicemagic.eu ([])
	by localhost (zm-01.servicemagic.eu []) (amavisd-new, port 10024)
	with ESMTP id 08syCk-3EqvS; Wed,  8 Feb 2017 09:52:48 +0100 (CET)
Received: from zm-01.servicemagic.eu (localhost.localdomain [])
	by zm-01.servicemagic.eu (Postfix) with ESMTP id 21A6F8120B961;
	Wed,  8 Feb 2017 09:52:48 +0100 (CET)
Date: Wed, 8 Feb 2017 09:52:48 +0100 (CET)
From: Walid MOGHRABI <w.moghrabi@servicemagic.eu>
To: Nable <nable.maininbox@googlemail.com>, 1145@bugs.x2go.org
Cc: Stefan Baur <X2Go-ML-1@baur-itcs.de>
Message-ID: <385892791.2883907.1486543968090.JavaMail.root@servicemagic.eu>
In-Reply-To: <CALxOYEa2+wW-HKs9QE9X5Bi3uQ0o2n2oT=DOwestqVZm3WHFpw@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Originating-IP: []
X-Mailer: Zimbra 7.2.0_GA_2669 (ZimbraWebClient - GC56 (Linux)/7.2.0_GA_2669)

To add my 2 cents, I workarounded this by creating a small helper script for provisionning my accounts which does the x2godbadmin --adduser stuff + a few other things (provisionning the /etc/skel content, setting right user perms, ...)

I don't think it is mandatory to expand these features inside the script but creating good documentation about those script (and I include scripts such as x2golistsession, x2goterminatesession, ...) and good error reporting would be great because it's very hard o know what they do unless you tap directly inside the code itself (which I did at then end).

Walid Moghrabi


----- Mail original ----- 

De: "Nable" <nable.maininbox@googlemail.com> 
À: "Stefan Baur" <X2Go-ML-1@baur-itcs.de> 
Cc: 1145@bugs.x2go.org 
Envoyé: Mercredi 8 Février 2017 02:32:52 
Objet: [X2Go-Dev] Bug#1145: Bug#1145: x2godbadmin + postgres + non-existent home directory = wrong ownerships 

> Are you aware of anything that does that and that we could call? 
I think that setup with absent homedir && non-configured pam_mkhomedir 
is broken anyway and one can only fail gracefully with a good error 
Other variants (homedir already exists and/or pam_mkhomedir is 
configured) can be covered by calling `su' or `sudo' with appropriate 
options (e.g. su -c /bin/true "${user_to_add}"). 
This would fail if homedir (either existing or not) is located on a 
network or encrypted FS (where local root can't do anything without 
knowing user's password) but this is a separate issue. 

I've also seen posts (e.g.[1]) about `oddjob-mkhomedir' (and I've 
already seen it in Debian repos) but I wonder if this way is 
production-ready. And this way seems to be more complex. 

[1] https://access.redhat.com/discussions/903523 
x2go-dev mailing list 
DISCLAIMER: This e-mail is private and confidential and may contain proprietary or legally privileged information. It is for the intended recipient only. If you have received this email in error, please notify the author by replying to it and then destroy it. If you are not the intended recipient you must not use, disclose, distribute, copy, print or rely on this e-mail or any attachment. Thank you

Send a report that this bug log contains spam.

X2Go Developers <owner@bugs.x2go.org>. Last modified: Tue Apr 16 04:22:05 2024; 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.