Bug 1391603 - Reprovisioning of Fedora 23 is not working, it fails on rhn_check
Summary: Reprovisioning of Fedora 23 is not working, it fails on rhn_check
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Spacewalk
Classification: Community
Component: Clients
Version: 2.5
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Jan Dobes
QA Contact: Red Hat Satellite QA List
URL:
Whiteboard:
Depends On:
Blocks: space28
TreeView+ depends on / blocked
 
Reported: 2016-11-03 15:44 UTC by Patrik Segedy
Modified: 2018-04-20 12:31 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-04-20 12:31:14 UTC
Embargoed:


Attachments (Terms of Use)

Description Patrik Segedy 2016-11-03 15:44:02 UTC
Description of problem:
I am not able to reprovision Fedora23. When I schedule kickstart and then run rhn_check -vv on client I'll get this in output:
D: do_call kickstart.initiate('smqa-x3650-01-vm02.lab.eng.brq.redhat.com', 'spacewalk-koan', ' ', '', 'localhost.localdomain:1', []){'cache_only': None}
D: Attempt to call an unsupported action kickstart.initiate('smqa-x3650-01-vm02.lab.eng.brq.redhat.com', 'spacewalk-koan', ' ', '', 'localhost.localdomain:1', [])
D: Sending back response(6, 'Invalid function call attempted', {})


Version-Release number of selected component (if applicable):
rhn-client-tools-2.5.16-1.fc23.noarch

How reproducible:
always

Steps to Reproduce:
1. Create channel for kickstarting
2. Download fedora-server iso and mount it
3. Push packages from iso to channel
4. Create repository for spacewalk-client-tools with url http://yum.spacewalkproject.org/2.5-client/Fedora/23/x86_64/ and sync this repository to channel
5. Create kickstart distribution from mounted iso
6. Create kickstart profile for created distribution
7. Register client to this channel (using this tutorial https://fedorahosted.org/spacewalk/wiki/RegisteringClients)
8. Schedule kickstart
9. Run rhn_check -vv on client, it wont start the kickstart and there is this in output:
D: do_call kickstart.initiate('smqa-x3650-01-vm02.lab.eng.brq.redhat.com', 'spacewalk-koan', ' ', '', 'localhost.localdomain:1', []){'cache_only': None}
D: Attempt to call an unsupported action kickstart.initiate('smqa-x3650-01-vm02.lab.eng.brq.redhat.com', 'spacewalk-koan', ' ', '', 'localhost.localdomain:1', [])
D: Sending back response(6, 'Invalid function call attempted', {})


Actual results:
Kickstarting will fail on rhn_check

Expected results:
rhn_check will run kickstarting of system


Additional info:
There is no problem with same steps on CentOS7

Comment 1 Ales Dujicek 2017-06-20 14:10:05 UTC
# tail /var/log/up2date
[Tue Jun 20 09:50:08 2017] up2date 
Traceback (most recent call last):
  File "/usr/sbin/rhn_check", line 441, 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/rhn_check", line 111, in main
    self.__run_remote_actions()
  File "/usr/sbin/rhn_check", line 217, in __run_remote_actions
    self.handle_action(action)
  File "/usr/sbin/rhn_check", line 278, in handle_action
    (status, message, data) = CheckCli.__run_action(method, params, {'cache_only': cache_only})
  File "/usr/sbin/rhn_check", line 382, in __run_action
    (status, message, data) = CheckCli.__do_call(method, params, kwargs)
  File "/usr/sbin/rhn_check", line 374, in __do_call
    method = getMethod.getMethod(method, "/usr/share/rhn/", "actions")
  File "/usr/share/rhn/up2date_client/getMethod.py", line 83, in getMethod
    actions = __import__(modulename)
  File "/usr/share/rhn/actions/kickstart.py", line 22, in <module>
    from spacewalkkoan import spacewalkkoan
  File "/usr/share/rhn/spacewalkkoan/spacewalkkoan.py", line 32, in <module>
    from koan.app import Koan
<class 'ImportError'>: No module named 'koan'
(I added raise on few places in /usr/share/rhn/up2date_client/getMethod.py and /usr/sbin/rhn_check to propagate exceptions and to see what really happened)


problem is that python3 runs rhn_check on Fedora
and it cannot import koan because it python2

# head -n1 /usr/sbin/rhn_check
#!/usr/bin/python3

# rpm -q spacewalk-koan koan
spacewalk-koan-2.6.1-1.fc24.noarch
koan-2.8.0-4.fc24.noarch

# python3 /usr/share/rhn/spacewalkkoan/spacewalkkoan.py
Traceback (most recent call last):
  File "/usr/share/rhn/spacewalkkoan/spacewalkkoan.py", line 32, in <module>
    from koan.app import Koan
ImportError: No module named 'koan'

# rpm -ql koan | grep app
/usr/lib/python2.7/site-packages/koan/app.py

Comment 2 Jan Dobes 2017-11-10 15:45:06 UTC
After Python 3 fixes in koan, this (or newer Fedora) should work on Spacewalk nightly.

Comment 3 Jiří Dostál 2018-03-26 12:16:29 UTC
Moving ON_QA

Comment 4 Jiří Dostál 2018-04-20 12:31:14 UTC
Spacewalk 2.8 has been released.
https://github.com/spacewalkproject/spacewalk/wiki/ReleaseNotes28


Note You need to log in before you can comment on or make changes to this bug.