[Spacewalk-list] Antwort: Antwort: Re: Antwort: Problems with Debian jessie main in Spacewalk 2.2

Paschedag.Netlution at swr.de Paschedag.Netlution at swr.de
Fri May 29 13:11:22 UTC 2015


Finally found the error and have a "bad" workaround for it.

See https://bugzilla.redhat.com/show_bug.cgi?id=1226329

Cheers,
Robert

Mit freundlichen Grüßen

Robert Paschedag
Netlution GmbH
Landteilstr. 33
68163 Mannheim

im Auftrag des
SWR
Südwestrundfunk
Informations- und Kommunikationssysteme
Neckarstraße 230
70190 Stuttgart

Telefon +49 (0)711 /929-12654 oder
Telefon +49 (0)711 /929-13714
paschedag.netlution at swr.de

swr.de





Von:	Paschedag.Netlution at swr.de
An:	spacewalk-list at redhat.com
Datum:	28.05.2015 13:21
Betreff:	[Spacewalk-list] Antwort: Re: Antwort: Problems with Debian
            jessie main in Spacewalk 2.2
Gesendet von:	spacewalk-list-bounces at redhat.com



I would really appreciate, if someone could try to reproduce my problem.

Situation

Spacewalk 2.2 (also tried with 2.3)
Client: Debian 8 (jessie)

Created channel for jessie main (binary-amd64) and synced it with the
"spacewalk-debian-sync.pl" script found here

https://github.com/stevemeier/spacewalk-debian-sync

[root@ spacewalk-debian-sync-master]# ./spacewalk-debian-sync.pl --url
http://ftp.de.debian.org/debian/dists/jessie/main/binary-amd64/ --channel
jessie_main --user api --password XXXXX
INFO: Repo URL:
http://ftp.de.debian.org/debian/dists/jessie/main/binary-amd64/
INFO: Debian root is http://ftp.de.debian.org/debian/
INFO: Fetching Packages.gz... done
INFO: Packages in repo:         42271
INFO: Packages already synced:  42271
INFO: Packages to sync:         0
INFO: Sync complete.
[root@ spacewalk-debian-sync-master]#


After I installed a Debian Jessie system and manually installed the
necessary packages, I try to register the system

root at debian-test4:~# rhnreg_ks --activationkey=1-jessie
--serverUrl=https://spacewalk-test/XMLRPC
An error has occurred:
<type 'exceptions.TypeError'>
See /var/log/up2date for more information
root at debian-test4:~#

The log looks like this.

Traceback (most recent call last):
  File "/usr/sbin/rhnreg_ks", line 218, in <module>
    cli.run()
  File "/usr/share/rhn/up2date_client/rhncli.py", line 96, in run
    sys.exit(self.main() or 0)
  File "/usr/sbin/rhnreg_ks", line 90, in main
    rhnreg.getCaps()
  File "/usr/share/rhn/up2date_client/rhnreg.py", line 239, in getCaps
    s.capabilities.validate()
  File "/usr/share/rhn/up2date_client/rhnserver.py", line 172, in
__get_capabilities
    self.registration.welcome_message()
  File "/usr/share/rhn/up2date_client/rhnserver.py", line 63, in __call__
    return rpcServer.doCall(method, *args, **kwargs)
  File "/usr/share/rhn/up2date_client/rpcServer.py", line 203, in doCall
    ret = method(*args, **kwargs)
  File "/usr/lib/python2.7/xmlrpclib.py", line 1233, in __call__
    return self.__send(self.__name, args)
  File "/usr/share/rhn/up2date_client/rpcServer.py", line 38, in _request1
    ret = self._request(methodname, params)
  File "/usr/lib/python2.7/dist-packages/rhn/rpclib.py", line 381, in
_request
    self._handler, request, verbose=self._verbose)
  File "/usr/lib/python2.7/dist-packages/rhn/transports.py", line 167, in
request
    headers, fd = req.send_http(host, handler)
  File "/usr/lib/python2.7/dist-packages/rhn/transports.py", line 698, in
send_http
    self._connection.connect()
  File "/usr/lib/python2.7/dist-packages/rhn/connections.py", line 183, in
connect
    self.sock.init_ssl()
  File "/usr/lib/python2.7/dist-packages/rhn/SSL.py", line 90, in init_ssl
    self._ctx.load_verify_locations(f)
  File "/usr/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 303, in
load_verify_locations
    raise TypeError("cafile must be None or a byte string")
<type 'exceptions.TypeError'>: cafile must be None or a byte string

The simple solution - for me - is to patch the file
"/usr/share/rhn/up2date/config.py"

Here is a bug report of the problem in Debian

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=782157

My patch looks like this

--- config.py.orig      2015-05-20 13:27:28.360531313 +0200
+++ config.py   2015-05-20 13:30:21.768540657 +0200
@@ -99,7 +99,11 @@
                 # or maybe error.
                 continue
             key = split[0].strip()
-            value = unicode(split[1].strip(), 'utf-8')
+            if key == 'sslCACert':
+                # Do not save SSL cert in unicode format
+                value = split[1].strip()
+            else:
+                value = unicode(split[1].strip(), 'utf-8')

             # decode a comment line
             comment = None

I can then successful register the client.

Then update the repos

First run of "apt-get update"

root at debian-test4:/usr/share/rhn/up2date_client# apt-get update
Apt-Spacewalk: Updating sources.list
Ign http://spacewalk-test jessie InRelease
Ign http://spacewalk-test jessie InRelease
Ign http://spacewalk-test jessie Release.gpg
Ign http://spacewalk-test jessie Release.gpg
Get:1 http://spacewalk-test jessie Release [32.5 kB]
Ign http://spacewalk-test jessie Release
Ign http://spacewalk-test jessie/main amd64 Packages/DiffIndex
Get:2 http://spacewalk-test jessie/main Translation-en [1 B]
Get:3 http://spacewalk-test jessie/main Translation-en [1 B]
Ign http://spacewalk-test jessie/spacewalk amd64 Packages/DiffIndex
Get:4 http://spacewalk-test jessie/main amd64 Packages [1 B]
Get:5 http://spacewalk-test jessie/main amd64 Packages [1 B]
Ign http://spacewalk-test jessie/spacewalk Translation-en_US
Ign http://spacewalk-test jessie/spacewalk Translation-en
Hit http://spacewalk-test jessie/spacewalk amd64 Packages
Fetched 1,602 kB in 30s (52.1 kB/s)
Reading package lists... Done
root at debian-test4:/usr/share/rhn/up2date_client#

Right after that, I do it again

oot at debian-test4:/usr/share/rhn/up2date_client# apt-get update
Apt-Spacewalk: Updating sources.list
Ign http://spacewalk-test jessie InRelease
Ign http://spacewalk-test jessie InRelease
Ign http://spacewalk-test jessie Release.gpg
Ign http://spacewalk-test jessie Release.gpg
Get:1 http://spacewalk-test jessie Release [32.5 kB]
Ign http://spacewalk-test jessie Release
Ign http://spacewalk-test jessie/main amd64 Packages/DiffIndex
Get:2 http://spacewalk-test jessie/main Translation-en [593 kB]
Ign http://spacewalk-test jessie/spacewalk amd64 Packages/DiffIndex
Get:3 http://spacewalk-test jessie/main amd64 Packages [976 kB]
Hit http://spacewalk-test jessie/spacewalk amd64 Packages
Ign http://spacewalk-test jessie/spacewalk Translation-en_US
Ign http://spacewalk-test jessie/spacewalk Translation-en
Ign spacewalk://spacewalk-test channels: InRelease
Ign spacewalk://spacewalk-test channels: Release.gpg
Ign spacewalk://spacewalk-test channels: Release
Get:4 spacewalk://spacewalk-test channels:/main amd64 Packages [12.0 MB]
Get:5 spacewalk://spacewalk-test channels:/jessie_security_main amd64
Packages [50.6 kB]
Get:6 spacewalk://spacewalk-test channels:/jessie_updates_main amd64
Packages [3,424 B]
Ign spacewalk://spacewalk-test channels:/jessie_security_main
Translation-en_US
Ign spacewalk://spacewalk-test channels:/jessie_security_main
Translation-en
Ign spacewalk://spacewalk-test channels:/jessie_updates_main
Translation-en_US
Ign spacewalk://spacewalk-test channels:/jessie_updates_main Translation-en
Ign spacewalk://spacewalk-test channels:/main Translation-en_US
Ign spacewalk://spacewalk-test channels:/main Translation-en
Fetched 13.7 MB in 2s (5,922 kB/s)
Reading package lists... Error!
E: Problem parsing dependency Depends
E: Error occurred while processing games-sport (NewVersion2)
E: Problem with
MergeList /var/lib/apt/lists/spacewalk-test_dists_channels:_main_binary-amd64_Packages

E: The package lists or status file could not be parsed or opened.
root at debian-test4:/usr/share/rhn/up2date_client#

I end up with this error. So it looks like an error within the
"Packages.gz" file of my "main channel", that is created by Spacewalk.

Regards,
Robert

Mit freundlichen Grüßen

Robert Paschedag
Netlution GmbH
Landteilstr. 33
68163 Mannheim

im Auftrag des
SWR
Südwestrundfunk
Informations- und Kommunikationssysteme
Neckarstraße 230
70190 Stuttgart

Telefon +49 (0)711 /929-12654 oder
Telefon +49 (0)711 /929-13714
paschedag.netlution at swr.de

swr.de





Von:		 Robert Paschedag <robert.paschedag at web.de>
An:		 spacewalk-list at redhat.com
Datum:		 27.05.2015 23:23
Betreff:		 Re: [Spacewalk-list] Antwort: Problems with Debian
jessie main
            in Spacewalk 2.2
Gesendet von:		 spacewalk-list-bounces at redhat.com



Hi Bernd,

yes, I did. With Debian 7.8 (wheezy), everything works. I see these
problems only with Jessie.

Robert

Am 27.05.2015 16:59 schrieb Bernd Helber <bernd at helber-it-services.com>:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Dear Robert,
>
> have you tried to check out this Link.
>
> Excellent Source as i figured
>
> http://www.devops-blog.net/category/spacewalk
>
> The general stuff should be the same with Jessie
> Kind regards.
>
> Bernd Helber
>
> Am 27.05.15 um 14:34 schrieb Robert Paschedag:
> > Nobody with Debian 8 on Spacewalk?
> >
> > Am 21.05.2015 09:29 schrieb Paschedag.Netlution at swr.de:
> >>
> >> Hmm....does anybody have a Spacewalk 2.3 server with "fresh"
> >> Debian Jessie repos in it and a working Debian Jessie client
> >> running and connected to Spacewalk?
> >>
> >> Regards, Robert
> >>
> >> Mit freundlichen Grüßen
> >>
> >> Robert Paschedag Netlution GmbH Landteilstr. 33 68163 Mannheim
> >>
> >> im Auftrag des SWR Südwestrundfunk Informations- und
> >> Kommunikationssysteme Neckarstraße 230 70190 Stuttgart
> >>
> >> Telefon +49 (0)711 /929-12654 oder Telefon +49 (0)711 /929-13714
> >>  paschedag.netlution at swr.de
> >>
> >> swr.de
> >>
> >>
> >>
> >>
> >>
> >> Von: Paschedag.Netlution at swr.de An: spacewalk-list at redhat.com
> >> Datum: 20.05.2015 15:08 Betreff: [Spacewalk-list] Problems with
> >> Debian jessie main in Spacewalk 2.2 Gesendet von:
> >> spacewalk-list-bounces at redhat.com
> >>
> >>
> >>
> >>
> >> Hi,
> >>
> >> I'm trying to deploy Debian Jessie via Spacewalk. After a few
> >> problems, the deployment works (with small errors) and I can
> >> connect the client to the Spacewalk 2.2 server. (Did not yet
> >> update to 2.3)
> >>
> >> I also pushed all packages from jessie main (binary-amd64) to a
> >> channel and let the client subscribe to it. But know, I get
> >> dependency problems, everytime i try to refresh the repos on the
> >> client
> >>
> >> root at debian-test4:~# apt-get update Apt-Spacewalk: Updating
> >> sources.list Ign http://spacewalk-test jessie InRelease Ign
> >> http://spacewalk-test jessie Release.gpg Ign
> >> http://spacewalk-test jessie Release Holen: 1
> >> http://spacewalk-test jessie/spacewalk amd64 Packages [7.115 B]
> >> Ign http://spacewalk-test jessie/spacewalk Translation-de_DE Ign
> >> http://spacewalk-test jessie/spacewalk Translation-de Ign
> >> spacewalk://spacewalk-test channels: InRelease Ign
> >> spacewalk://spacewalk-test channels: Release.gpg Ign
> >> http://spacewalk-test jessie/spacewalk Translation-en Ign
> >> spacewalk://spacewalk-test channels: Release Holen: 2
> >> spacewalk://spacewalk-test channels:/main amd64 Packages [12,0
> >> MB] Holen: 3 spacewalk://spacewalk-test
> >> channels:/jessie_security_main amd64 Packages [50,6 kB] Holen: 4
> >> spacewalk://spacewalk-test channels:/jessie_updates_main amd64
> >> Packages [3.424 B] Ign spacewalk://spacewalk-test
> >> channels:/jessie_security_main Translation-de_DE Ign
> >> spacewalk://spacewalk-test channels:/jessie_security_main
> >> Translation-de Ign spacewalk://spacewalk-test
> >> channels:/jessie_security_main Translation-en Ign
> >> spacewalk://spacewalk-test channels:/jessie_updates_main
> >> Translation-de_DE Ign spacewalk://spacewalk-test
> >> channels:/jessie_updates_main Translation-de Ign
> >> spacewalk://spacewalk-test channels:/jessie_updates_main
> >> Translation-en Ign spacewalk://spacewalk-test channels:/main
> >> Translation-de_DE Ign spacewalk://spacewalk-test channels:/main
> >> Translation-de Ign spacewalk://spacewalk-test channels:/main
> >> Translation-en Es wurden 12,1 MB in 1 s geholt (6.626 kB/s).
> >> Paketlisten werden gelesen... Fehler! E: Problem parsing
> >> dependency Depends E: Fehler aufgetreten beim Verarbeiten von
> >> games-sport (NewVersion2) E: Problem with MergeList
> >> /var/lib/apt/lists/spacewalk-test_dists_channels:_main_binary-amd64_P
> ackages
> >>
> >>
> >> E: Die Paketliste oder die Statusdatei konnte nicht eingelesen
> >> oder geöffnet werden. root at debian-test4:~#
> >>
> >> Looks like there are depedency problems within the packages but
> >> I'm not sure.
> >>
> >> I already removed old lists under /var/lib/apt/lists but that
> >> didn't help.
> >>
> >> Any help will be appreciated.
> >>
> >> Regards, Robert
> >>
> >>
> >>
> >> Mit freundlichen Grüßen
> >>
> >> Robert Paschedag Netlution GmbH Landteilstr. 33 68163 Mannheim
> >>
> >> im Auftrag des SWR Südwestrundfunk Informations- und
> >> Kommunikationssysteme Neckarstraße 230 70190 Stuttgart
> >>
> >> Telefon +49 (0)711 /929-12654 oder Telefon +49 (0)711 /929-13714
> >>  paschedag.netlution at swr.de
> >>
> >> swr.de
> >>
> >>
> >>
> >> _______________________________________________ Spacewalk-list
> >> mailing list Spacewalk-list at redhat.com
> >> https://www.redhat.com/mailman/listinfo/spacewalk-list
> >>
> >>
> >>
> >>
> >> _______________________________________________ Spacewalk-list
> >> mailing list Spacewalk-list at redhat.com
> >> https://www.redhat.com/mailman/listinfo/spacewalk-list
> >
> > _______________________________________________ Spacewalk-list
> > mailing list Spacewalk-list at redhat.com
> > https://www.redhat.com/mailman/listinfo/spacewalk-list
> >
>
> - --
> with kind regards
>
> Bernd Helber
>
> phone  +49 7331 824189
> mobile +49 177 7494439
>
> Filsstraße 20
> 73329
> Kuchen Fils
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.10 (Darwin)
>
> iQEcBAEBAgAGBQJVZdvvAAoJEHxIkeoL34IfPf8IAI4eSNRxt2ZgHBNpkfnikLZ3
> NZGVHv0tiAxqE2M9FtgFS+tGNHuEPpvaPbKuejXLET5ytEjD5A2hssItHURMpqmm
> FOZmheUgyl0nxyCaYcKdMMcx987cuOZKgnqkSLiu2IlnVtVH85fSrQVN1JulJg6g
> b9mvQukMRdU7L1Rh+SQHbp4Xlod8Ami4ETsxOiQM5s4zo9DquumkTUwdmfdBWhd5
> W9blQPXtF+oc/NgOZwph32hQ6zPKvTC0wa92FI7aN6sodr1VDJ1nWjgRiqS2WTNN
> n8FhHNdjPXsw4Vi5ZWEPBPNRYB/h8PKgRxBMbbMymomqtMIQiGgLNxIjeqljXgI=
> =RRNj
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> Spacewalk-list mailing list
> Spacewalk-list at redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list

_______________________________________________
Spacewalk-list mailing list
Spacewalk-list at redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list



_______________________________________________
Spacewalk-list mailing list
Spacewalk-list at redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list







More information about the Spacewalk-list mailing list