Bug 1225947

Summary: Bug in rhnreg_ks in line 25
Product: [Community] Spacewalk Reporter: xybal <xybal>
Component: ClientsAssignee: Tomáš Kašpárek <tkasparek>
Status: CLOSED NEXTRELEASE QA Contact: Red Hat Satellite QA List <satqe-list>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 2.3CC: pascalpascher, phil.ingram, tlestach, xybal
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-13 16:17:32 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1484117    

Description xybal 2015-05-28 14:04:58 UTC
Description of problem:

Cannot register the client (CentOS 7.0) on the spacewalk server 2.3 installed on a CentOS 7.0 too.


How reproducible:
each time i try to register the client. I re kickstarted the client via SpaceWalk but always the same bug appear.
I verified the certificate RHN-ORG-TRUSTED-SSL-CERT is OK on the right place on the sever, and the key is OK and this is the right one.

Steps to Reproduce:
1. rhnreg_ks --serverUrl=https://192.168.0.115/XMLRPC --sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT --activationkey=1-6961fa767bbbf20cd964be5558980eb0

I tried with the resolved hosname for 192.168.0.115 but his is the same thing.


Actual results:

Traceback (most recent call last):
  File "/usr/sbin/rhnreg_ks", line 25, in <module>
    from rhn.connections import idn_puny_to_unicode
ImportError: cannot import name idn_puny_to_unicode



Expected results:


Additional info:

Comment 1 Tomáš Kašpárek 2015-05-28 14:19:07 UTC
could you please provide version of rhn-setup and rhn-client tools are you using? (rpm -q)
I've saw this bug before but I'd definitely say we've already fixed that.

Comment 2 xybal 2015-05-28 14:38:34 UTC
(In reply to Tomáš Kašpárek from comment #1)
> could you please provide version of rhn-setup and rhn-client tools are you
> using? (rpm -q)
> I've saw this bug before but I'd definitely say we've already fixed that.

I'm using these versions :

rhn-setup-2.3.16-1.el7.noarch
rhn-client-tools-2.3.16-1.el7.noarch

Any idea with these infos ?

Comment 3 xybal 2015-06-01 08:13:34 UTC
I've tried to replay te scenario fro a new kickstated machine with the same result, really no idea to solve this bug ?
Thx by advance

Comment 4 Marco Mauritsch 2015-06-23 12:28:30 UTC
Same problem here with fresh installation on Fedora22 :

[root@test01 ~]# rhnreg_ks
Traceback (most recent call last):
  File "/usr/sbin/rhnreg_ks", line 25, in <module>
    from rhn.connections import idn_puny_to_unicode
ImportError: cannot import name idn_puny_to_unicode



[root@test01 ~]# rpm -qa | grep -i rhn
rhn-setup-2.4.5-1.fc22.noarch
rhn-check-2.4.5-1.fc22.noarch
rhnlib-2.5.72-1.fc22.noarch
rhn-client-tools-2.4.5-1.fc22.noarch
rhnsd-5.0.14-3.fc22.x86_64
yum-rhn-plugin-2.2.7-1.fc22.noarch
rhn-org-trusted-ssl-cert-1.0-1.noarch

Comment 5 Pascal Pascher 2015-06-27 16:13:08 UTC
I just got started using centos and spacewalk and ran into the same error when registering my first client in centos 7.

When I looked at "/usr/lib/python2.7/site-packages/rhn/connections.py" I noticed the definitions where named "idn_pune_to_unicode" and "idn_ascii_to_pune" instead of "idn_puny_to_unicode" and "idn_ascii_to_puny" as rhnreg_ks was looking for. Changing the names fixed the issue.

Comment 6 Phil 2015-06-28 12:12:16 UTC
I can confirm that the fix in comment 5 "fixes" the issue on Fedora 22 using the in distro packages - the external repo (yum.spacewalkproject.org) doesn't have F22 packages.

Comment 7 Tomas Lestach 2015-07-13 15:25:23 UTC
I just tried to register a RHEL7 server to a Spacewalk machine with:
* client packages from RHEL7:
 rhn-setup-2.0.2-6.el7.noarch
 rhn-client-tools-2.0.2-6.el7.noarch
* client packages from spacewalk 2.3 client repo:
 rhn-setup-2.3.16-1.el7.noarch
 rhn-client-tools-2.3.16-1.el7.noarch

I experienced no issues.

Comment 8 Tomas Lestach 2015-07-13 16:13:21 UTC
I was also able to register a fedora22 machine to a Spacewalk server with:
* client packages from spacewalk nightly client repo:
 rhn-setup-2.4.6-1.fc22.noarch
 rhn-client-tools-2.4.6-1.fc22.noarch

Registration with client packages from Fedora22:
 rhn-setup-2.4.5-1.fc22.noarch
 rhn-client-tools-2.4.5-1.fc22.noarch
FAILED with:
Traceback (most recent call last):
  File "/usr/sbin/rhnreg_ks", line 25, in <module>
    from rhn.connections import idn_puny_to_unicode
ImportError: cannot import name idn_puny_to_unicode
To get this fixed, please open a BZ for Fedora - rhn-client-tools component, as the issue was most probably fixed in upstream, but not in fedora yet.

Comment 9 Tomas Lestach 2015-07-13 16:17:32 UTC
As I do not see any misbehavior in Spacewalk (client) packages, I'm closing this bug as NEXTRELEASE (as Spacewalk client packages for fedora22 were not part of any Spacewalk release yet, only available in nightly repo). Feel free to re-open, in case I overlooked something. Thank you.

Comment 10 Tomas Lestach 2015-07-20 13:08:21 UTC
> Registration with client packages from Fedora22:
>  rhn-setup-2.4.5-1.fc22.noarch
>  rhn-client-tools-2.4.5-1.fc22.noarch
> FAILED with:
> Traceback (most recent call last):
>   File "/usr/sbin/rhnreg_ks", line 25, in <module>
>     from rhn.connections import idn_puny_to_unicode
> ImportError: cannot import name idn_puny_to_unicode
> To get this fixed, please open a BZ for Fedora - rhn-client-tools component,
> as the issue was most probably fixed in upstream, but not in fedora yet.

There is already Bug 1235574 opened, that should address the issue in Fedora22.

Comment 11 Eric Herget 2017-09-28 18:06:59 UTC
This BZ closed some time during 2.5, 2.6 or 2.7.  Adding to 2.7 tracking bug.