X2Go Bug report logs - #783
RPM Pre Script fail on Upgrade (Nightly)

version graph

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

Reported by: Schlomo Schapiro <schlomo.schapiro@immobilienscout24.de>

Date: Mon, 9 Feb 2015 12:00:01 UTC

Severity: normal

Found in version 4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6

Done: Mihai Moldovan <ionic@ionic.de>

Bug is archived. No further changes may be made.

Full log


🔗 View this message in rfc822 format

X-Loop: owner@bugs.x2go.org
Subject: Bug#783: RPM Pre Script fail on Upgrade (Nightly)
Reply-To: Schlomo Schapiro <schlomo.schapiro@immobilienscout24.de>, 783@bugs.x2go.org
Resent-From: Schlomo Schapiro <schlomo.schapiro@immobilienscout24.de>
Resent-To: x2go-dev@lists.x2go.org
Resent-CC: X2Go Developers <x2go-dev@lists.x2go.org>
X-Loop: owner@bugs.x2go.org
Resent-Date: Mon, 09 Feb 2015 12:00:01 +0000
Resent-Message-ID: <handler.783.B.142348312928027@bugs.x2go.org>
Resent-Sender: owner@bugs.x2go.org
X-X2Go-PR-Message: report 783
X-X2Go-PR-Package: x2goserver
X-X2Go-PR-Keywords: 
Received: via spool by submit@bugs.x2go.org id=B.142348312928027
          (code B); Mon, 09 Feb 2015 12:00:01 +0000
Received: (at submit) by bugs.x2go.org; 9 Feb 2015 11:58:49 +0000
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on
	ymir.das-netzwerkteam.de
X-Spam-Level: 
X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID,
	URIBL_BLOCKED autolearn=ham version=3.3.2
X-Greylist: delayed 571 seconds by postgrey-1.34 at ymir.das-netzwerkteam.de; Mon, 09 Feb 2015 12:58:47 CET
Received: from mxb.immobilienscout24.de (mxb.immobilienscout24.de [217.111.70.216])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTPS id 396FE5DBCA
	for <submit@bugs.x2go.org>; Mon,  9 Feb 2015 12:58:47 +0100 (CET)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple;
  d=immobilienscout24.de; i=@immobilienscout24.de;
  q=dns/txt; s=is24ci; t=1423483127; x=1455019127;
  h=message-id:date:from:mime-version:to:subject:
   content-transfer-encoding;
  bh=aBR7lGBbrLGQWk8rNmSZxVSrrEAbUhMJUCJkDqp8zMg=;
  b=nLxe0ThEteqtlc/6spWl6z1Kjr49uiSd2zy1bBdx+z8XKUfA7BPL942j
   y70wH+zFqxy3y3BcQpzZnuCC7419/G7UO4oCrOyxYL0fZ3ck6VMQtJ1W5
   cj/zkDNgEro4jEqwlf9StpvYSrlE+QPTtoGIFUzh6+ONogm0h7+Z79f80
   UDB9go82HNWKGBIK1AhZHBwSSLcnKIHJg3/TQaASfCiMKby9p9a/KHjl8
   NPQWEmkOVw1xR8KvCXhRmalTPnrVuuO0UZD0JyxqPmnuQUIhlXbu3OULO
   tJL8iy4pWNTzXiSVqbaOzJSqw0h1PArp57AWyOO+EXz8LbMPHZQl5OJ9f
   w==;
X-IronPort-AV: E=Sophos;i="5.09,543,1418079600"; 
   d="scan'208";a="68839026"
X-CSA-Complaints: whitelist-complaints@eco.de
Received: from isdeblnexca1.iscout.local ([10.0.1.121])
  by mxb.iscout.local with ESMTP/TLS/AES256-SHA; 09 Feb 2015 12:49:16 +0100
Received: from [10.100.162.22] (10.0.1.117) by webmail.immobilienscout24.de
 (10.0.1.121) with Microsoft SMTP Server (TLS) id 14.3.210.2; Mon, 9 Feb 2015
 12:49:16 +0100
Message-ID: <54D89EBC.9050602@immobilienscout24.de>
Date: Mon, 9 Feb 2015 12:49:16 +0100
From: Schlomo Schapiro <schlomo.schapiro@immobilienscout24.de>
Organization: Immobilien Scout GmbH
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0
MIME-Version: 1.0
To: <submit@bugs.x2go.org>
OpenPGP: id=AD1C15F9
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-Originating-IP: [10.0.1.117]
Package: x2goserver
Version: 4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6

RPM Upgrades of existing installations fail because of a broken %pre
script in the x2goserver-common RPM:

Resolving Dependencies
--> Running transaction check
---> Package x2goserver-common.x86_64
0:4.1.0.0-0.0x2go1.0.git20150113.1214.heuler.el6 will be updated
---> Package x2goserver-common.x86_64
0:4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

==============================================================================================================================================
 Package                      Arch             
Version                                                   
Repository                    Size
==============================================================================================================================================
Updating:
 x2goserver-common            x86_64           
4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6            
is24-x2go-nightly            7.2 k

Transaction Summary
==============================================================================================================================================
Upgrade       1 Package(s)

Total download size: 7.2 k
Is this ok [y/N]: y
Downloading Packages:
x2goserver-common-4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6.x86_64.rpm                                           
| 7.2 kB     00:00    
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Error in PREIN scriptlet in rpm package
x2goserver-common-4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6.x86_64
groupadd: group 'x2gouser' already exists
useradd: user 'x2gouser' already exists
error:
%pre(x2goserver-common-4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6.x86_64)
scriptlet failed, exit status 9
error:   install: %pre scriptlet failed (2), skipping
x2goserver-common-4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6
Running post transaction command: report-yum-to-graphite.sh
x2goserver-common-4.1.0.0-0.0x2go1.0.git20150113.1214.heuler.el6.x86_64
was supposed to be removed but is not!
  Verifying  :
x2goserver-common-4.1.0.0-0.0x2go1.0.git20150113.1214.heuler.el6.x86_64                                                   
1/2
  Verifying  :
x2goserver-common-4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6.x86_64                                                   
2/2

Failed:
  x2goserver-common.x86_64
0:4.1.0.0-0.0x2go1.0.git20150113.1214.heuler.el6                                                                  

  x2goserver-common.x86_64
0:4.1.0.0-0.0x2go1.0.git20150201.1236.heuler.el6                                                                  


Complete!

The bad script is this:

if getent group x2gouser 1>/dev/null; then
    groupadd -r x2gouser
fi
if getent passwd x2gouser >/dev/null; then
    useradd -r -g x2gouser -d /var/lib/x2go -s /sbin/nologin \
            -c "x2go" x2gouser
fi

It should have a ! in the if clause to only call groupadd / useradd if the group or user DO NOT EXIST!!

Don't you test upgrades???

Regards,
Schlomo


-- 
Schlomo Schapiro
Systemarchitekt
Open Source Evangelist

Immobilien Scout GmbH      
Andreasstraße 10    
10243 Berlin  
Fon +49 30 24 301-1229
Fax +49 30 24 301-1110
Mobile +49 170 753 72 60        
schlomo.schapiro@immobilienscout24.de
https://plus.google.com/100684964212588500616/about

----------------------------------------------------------
Immobilien Scout GmbH - Ein Unternehmen der Scout24-Gruppe
Geschäftsführer: Gregory Ellis (CEO) und Christian Gisy (CFO)
Handelsregister: Amtsgericht Charlottenburg, HRB 69108
Sitz der Gesellschaft: Berlin
----------------------------------------------------------

http://www.immobilienscout24.de
Der Marktführer:
Die Nr. 1 rund um Immobilien

Send a report that this bug log contains spam.


X2Go Developers <owner@bugs.x2go.org>. Last modified: Thu Nov 21 15:17:22 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.