Bug 1025785

Summary: /usr/share/lxc/templates/lxc-fedora has bad fedora-release version
Product: [Fedora] Fedora Reporter: Joel Uckelman <uckelman>
Component: lxcAssignee: Thomas Moschny <thomas.moschny>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 19CC: karlthered, mhw, sagarun, thomas.moschny
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: 2014-06-05 19:25:53 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:

Description Joel Uckelman 2013-11-01 14:58:04 UTC
Description of problem:

/usr/share/lxc/templates/lxc-fedora tries to download "fedora-release-$release-1.noarch.rpm", but the correct RPM for F19 is currently 
fedora-release-19-2.noarch.rpm, not fedora-release-19-1.noarch.rpm. Hence using the template to create a container fails.

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

lxc-templates-0.8.0-2.fc19.x86_64


How reproducible:

Always.




Steps to Reproduce:
1. lxc-create -n foo -t fedora -f /usr/share/doc/lxc/examples/lxc-macvlan.conf

Actual results:

[root@cato ~]# lxc-create -n foo -t fedora -f /usr/share/doc/lxc/examples/lxc-macvlan.conf 
/usr/share/lxc/templates/lxc-fedora is /usr/share/lxc/templates/lxc-fedora
Checking cache download in /var/cache/lxc/fedora/x86_64/19/rootfs ... 
Downloading fedora minimal ...
Fetching from http://fedora.mirror.lstn.net/releases/19/Everything/x86_64/os//Packages/f/fedora-release-19-1.noarch.rpm
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:01 --:--:--     0
curl: (22) The requested URL returned error: 404 Not Found
Failed to download fedora release rpm
Trying again...
Fetching from http://mirror.umd.edu/fedora/linux/releases/19/Everything/x86_64/os//Packages/f/fedora-release-19-1.noarch.rpm
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 404 Not Found
Failed to download fedora release rpm
Trying again...
Fetching from http://mirror.pnl.gov/fedora/linux/releases/19/Everything/x86_64/os//Packages/f/fedora-release-19-1.noarch.rpm
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 404 Not Found
Failed to download fedora release rpm
Aborting
Failed to download 'fedora base'
failed to install fedora
lxc-create: failed to execute template 'fedora'
lxc-create: aborted


Expected results:

The script should pick the right name for the release package.

Comment 1 Joel Uckelman 2013-11-01 15:04:23 UTC
Actually, the current release is 19-4 now. Hard-coding this seems like a bad idea.

Comment 2 Thomas Moschny 2013-12-23 08:48:59 UTC
Does the problem persist with lxc-templates-0.9.0-2?

Comment 3 Joel Uckelman 2014-02-12 21:20:57 UTC
This seems to work now with lxc-templates-0.9.0-2.fc20.x86_64.

Comment 4 Michael H. Warfield 2014-06-04 18:49:26 UTC
This has been fixed in upstream and this can be closed.