Bug 1201879 - Koan does not parse version numbers on EL7 correctly and therefore fails.
Summary: Koan does not parse version numbers on EL7 correctly and therefore fails.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: cobbler
Version: epel7
Hardware: All
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: John Eckersberg
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-03-13 17:38 UTC by sapan.ganguly
Modified: 2015-07-27 23:12 UTC (History)
7 users (show)

Fixed In Version: cobbler-2.6.9-1.el7
Clone Of:
Environment:
Last Closed: 2015-07-27 23:12:30 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description sapan.ganguly 2015-03-13 17:38:59 UTC
Description of problem:

koan doesn't support CentOS 7's version numbering, so in os_release function of /usr/lib/python2.7/site-packages/koan/utils.py, replace

      for t in tokens:
         try:
             return (make,float(t))
         except ValueError, ve:
             pass
      raise CX("failed to detect local OS version from /etc/redhat-release")

with

      for t in tokens:
         try:
             match = re.match('^\d+(?:\.\d+)?', t)
             if match:
                 return (make, float(match.group(0)))
         except ValueError, ve:
             pass
      raise CX("failed to detect local OS version from /etc/redhat-release")

Version-Release number of selected component (if applicable):

2.6.7-1.el7

How reproducible:

Everytime koan is used on EL7.

Steps to Reproduce:
1. Build an EL7 machine from Cobbler
2. Try and run koan --replace-self
3. Observe the problem with reading /etc/redhat-release

Actual results:

Error message (sorry, I didn't keep a copy).

Expected results:

After the changes to utils.py mentioned above the koan command is successful, I can then reboot the box and have it re-build.


Additional info:

Comment 1 Orion Poplawski 2015-04-27 22:42:18 UTC
Upstream fix: https://github.com/cobbler/cobbler/pull/1334

Comment 2 Fedora Update System 2015-05-09 02:18:09 UTC
cobbler-2.6.8-1.el7 has been submitted as an update for Fedora EPEL 7.
https://admin.fedoraproject.org/updates/cobbler-2.6.8-1.el7

Comment 3 Fedora Update System 2015-05-11 00:47:03 UTC
Package cobbler-2.6.8-1.el7:
* should fix your issue,
* was pushed to the Fedora EPEL 7 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=epel-testing cobbler-2.6.8-1.el7'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-EPEL-2015-6209/cobbler-2.6.8-1.el7
then log in and leave karma (feedback).

Comment 4 Fedora Update System 2015-06-25 23:56:36 UTC
Package cobbler-2.6.9-1.el7:
* should fix your issue,
* was pushed to the Fedora EPEL 7 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=epel-testing cobbler-2.6.9-1.el7'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-EPEL-2015-6209/cobbler-2.6.9-1.el7
then log in and leave karma (feedback).

Comment 5 Fedora Update System 2015-07-27 23:12:30 UTC
cobbler-2.6.9-1.el7 has been pushed to the Fedora EPEL 7 stable repository.  If problems still persist, please make note of it in this bug report.


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