Bug 790996 - Push Fedora16 fails for EC2
Summary: Push Fedora16 fails for EC2
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: imagefactory
Version: 1
Hardware: Unspecified
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Chris Lalancette
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-02-15 21:41 UTC by Joe Vlcek
Modified: 2013-11-14 15:45 UTC (History)
14 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-11-14 15:45:17 UTC
Type: ---


Attachments (Terms of Use)
TDL passed to aeolus-image build (899 bytes, text/xml)
2012-02-15 21:41 UTC, Joe Vlcek
no flags Details
Imagefactory config file (586 bytes, application/octet-stream)
2012-02-15 21:43 UTC, Joe Vlcek
no flags Details

Description Joe Vlcek 2012-02-15 21:41:38 UTC
Created attachment 562345 [details]
TDL passed to aeolus-image build

- Description of problem:

Attempting to push a Fedora16 image to EC2 fails

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

Using latest bits available on RHEL6.2

% rpm -qa | grep imagefactory
rubygem-imagefactory-console-0.4.0-1.el6.noarch
imagefactory-1.0.0rc4_2_gf16dfc5-1.el6.noarch
imagefactory-jeosconf-ec2-rhel-1.0.0rc4_2_gf16dfc5-1.el6.noarch
imagefactory-jeosconf-ec2-fedora-1.0.0rc4_2_gf16dfc5-1.el6.noarch


- How reproducible:


Steps to Reproduce:
1. Update file:
   /etc/imagefactory/jeos_images/ec2_fedora_jeos_03_OCT_2011.conf
with Fedora 16 AMI as listed at URL:
  http://fedoraproject.org/wiki/Cloud_images

% cat  /etc/imagefactory/jeos_images/ec2_fedora_jeos_03_OCT_2011.conf
ec2:ec2-us-east-1:Fedora:16:i386:ami-5f16d836
ec2:ec2-us-east-1:Fedora:16:x86_64:ami-0316d86a
ec2:ec2-us-west-1:Fedora:16:i386:ami-25e0bc60
ec2:ec2-us-west-1:Fedora:16:x86_64:ami-69e0bc2c
ec2:ec2-us-west-2:Fedora:16:i386:ami-e2f37ed2
ec2:ec2-us-west-2:Fedora:16:x86_64:ami-88f37eb8
ec2:ec2-us-east-1:Fedora:15:x86_64:ami-c31cd8aa
ec2:ec2-us-east-1:Fedora:15:i386:ami-b71cd8de
ec2:ec2-us-east-1:Fedora:14:x86_64:ami-5b1dd932
ec2:ec2-us-east-1:Fedora:14:i386:ami-171dd97e
ec2:ec2-us-west-1:Fedora:15:x86_64:ami-45a9fb00
ec2:ec2-us-west-1:Fedora:15:i386:ami-65a9fb20
ec2:ec2-us-west-1:Fedora:14:x86_64:ami-75a9fb30
ec2:ec2-us-west-1:Fedora:14:i386:ami-73a9fb36


2. Restart aeolus bits including imagefactory 
   /usr/sbin/aeolus-restart-services

3. Build snapshot (TDL and config files attached)
% aeolus-image build --target ec2 --template f16_cs_URL.xml

This succeeds

4. Attempt to push fails.
  % aeolus-image push --account JoeV_EC2 --image \
    4fb38b48-c575-4479-b9e9-abccad97269a


  
- Actual results:

imagefactory.log

2012-02-15 15:53:27,325 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(bdd9d33a) Message: Exception caught in ImageFactory
2012-02-15 15:53:27,684 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(bdd9d33a) Message: Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/imgfac/builders/Fedora_ec2_Builder.py", line 458, in push_image
    credentials)
  File "/usr/lib/python2.6/site-packages/imgfac/builders/Fedora_ec2_Builder.py", line 651, in push_image_snapshot_ec2
    self.guest.do_customize(guestaddr)
  File "/usr/lib/python2.6/site-packages/oz/RedHat.py", line 1100, in do_customize
    self._customize_repos(guestaddr)
  File "/usr/lib/python2.6/site-packages/oz/RedHat.py", line 1091, in _customize_repos
    self.guest_live_upload(guestaddr, localname, remotename)
  File "/usr/lib/python2.6/site-packages/imgfac/builders/Fedora_ec2_Builder.py", line 76, in guest_live_upload
    return super(FedoraRemoteGuest, self).guest_live_upload(guestaddr, file_to_upload, destination, timeout)
  File "/usr/lib/python2.6/site-packages/oz/RedHat.py", line 528, in guest_live_upload
    file_to_upload, destination, timeout)
  File "/usr/lib/python2.6/site-packages/oz/ozutil.py", line 381, in scp_copy_file
    "root@" + guestaddr + ":" + destination])
  File "/usr/lib/python2.6/site-packages/oz/ozutil.py", line 323, in subprocess_check_output
    raise SubprocessException("'%s' failed(%d): %s" % (cmd, retcode, stderr), retcode)
SubprocessException: 'scp -i /tmp/tmp7jhZb2 -F /dev/null -o ServerAliveInterval=30 -o StrictHostKeyChecking=no -o ConnectTimeout=30 -o UserKnownHostsFile=/dev/null -o PasswordAuthentication=no /var/lib/oz/icicletmp/factory-build-bdd9d33a-2bda-4e99-a4bd-d35999ff4ab4/aeolusrepo.repo root.amazonaws.com:/etc/yum.repos.d/aeolusrepo.repo' failed(1): Warning: Permanently added 'ec2-174-129-76-100.compute-1.amazonaws.com,174.129.76.100' (RSA) to the list of known hosts.^M
Please login as the user "ec2-user" rather than the user "root".


2012-02-15 15:53:27,684 DEBUG imgfac.BuildJob.BuildJob thread(bdd9d33a) Message: Builder (bdd9d33a-2bda-4e99-a4bd-d35999ff4ab4) changed status from PUSHING to FAILED
2012-02-15 15:53:27,685 DEBUG imgfac.BuildJob.BuildJob thread(bdd9d33a) Message: bdd9d33a-2bda-4e99-a4bd-d35999ff4ab4 for ec2 about to exit ec2 queue...
2012-02-15 15:53:27,685 DEBUG imgfac.ReservationManager.ReservationManager thread(bdd9d33a) Message: EXITING queue: (ec2)
2012-02-15 15:53:27,685 DEBUG imgfac.ReservationManager.ReservationManager thread(bdd9d33a) Message: SUCCESS EXITING queue: (ec2)



More data:
boomvang % aeolus-image list --image 4fb38b48-c575-4479-b9e9-abccad97269a
ID                                       Name                  OS         OS Version     Arch       Description                                  
------------------------------------     -----------------     ------     ----------     ------     ----------------------------------------     
4fb38b48-c575-4479-b9e9-abccad97269a     f16-config-server     Fedora     16             x86_64     Aeolus Config Server running on Fedora16     

boomvang % aeolus-image list --builds 4fb38b48-c575-4479-b9e9-abccad97269a
ID                                       Image                                    
------------------------------------     ------------------------------------     
1c6d482b-f462-48f1-a7b9-58ef83054d0d     4fb38b48-c575-4479-b9e9-abccad97269a     

boomvang % aeolus-image list --targetimages 4fb38b48-c575-4479-b9e9-abccad97269a

ERROR:  BuildNotFound => Could not find Build 4fb38b48-c575-4479-b9e9-abccad97269a
boomvang % aeolus-image list --targetimages 1c6d482b-f462-48f1-a7b9-58ef83054d0d
ID                                       Status       Build                                    
------------------------------------     --------     ------------------------------------     
881d1710-28f0-4a1a-8027-7e94950344f5     COMPLETE     1c6d482b-f462-48f1-a7b9-58ef83054d0d     

boomvang % aeolus-image list --providerimages 881d1710-28f0-4a1a-8027-7e94950344f5
ID     Target Identifier     Status     Target Image     Account     Provider     Provider Type     
--     -----------------     ------     ------------     -------     --------     -------------     

boomvang %

Comment 1 Joe Vlcek 2012-02-15 21:43:07 UTC
Created attachment 562346 [details]
Imagefactory config file

Comment 2 Joe Vlcek 2012-02-15 21:46:42 UTC
Greg Blomquist and I are both seeing this.

Perhaps we are doing something wrong. Please evaluate and advise.

Comment 3 Ian McLeod 2012-02-15 22:18:43 UTC
Our EC2 snapshot build mechanism is built on Oz which assumes that you can ssh into remote instances as root using an authorized key.

The F16 JEOS image you have added was likely built by boxgrinder and, as a result, doesn't actually do "root key injection".  Instead, it takes the EC2 provided key and authorizes it for a special "ec2-user" that can then sudo to root if needed.

I am in the process of refreshing the JEOS image set for Fedora which should address this.

I'll use this bug to track my progress.

Note that an upload style build should work.

Also please note that we have an "rc5" build in brew now.

Comment 4 Hugh Brock 2012-02-20 19:23:43 UTC
Good that we're fixing this, but f16 is not a supported guest type for cloudforms-1.0.0 (rhel 5.8 up and rhel 6.x are the only supported types). So moving off cloudforms-1.0.0.

Comment 5 Dave Johnson 2012-05-08 17:30:57 UTC
This still seems to be a issue when using the release candidate which has the following rpms...  


[root@ibm-x3690x5-01 ~]# rpm -qa | egrep 'imagefactory|oz'
imagefactory-1.0.0rc11-1.el6.noarch
oz-0.8.0-5.el6.noarch
imagefactory-jeosconf-ec2-rhel-1.0.0rc11-1.el6.noarch
imagefactory-jeosconf-ec2-fedora-1.0.0rc11-1.el6.noarch


logs:
---------
2012-05-08 13:22:52,372 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(421980c6) Message: Being asked to push for provider ec2-us-east-1
2012-05-08 13:22:52,372 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(421980c6) Message: distro: Fedora - update: 16 - arch: x86_64
2012-05-08 13:22:52,373 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(421980c6) Message: acting as EC2 user: 3897-xxxx-xxxx
2012-05-08 13:22:52,373 DEBUG imgfac.BuildJob.BuildJob thread(421980c6) Message: 421980c6-0df1-4e24-8d50-362c108bdfcf for ec2 about to enter ec2 queue...
2012-05-08 13:22:52,373 DEBUG imgfac.ReservationManager.ReservationManager thread(421980c6) Message: ENTERING queue: (ec2)
2012-05-08 13:22:52,374 DEBUG imgfac.ReservationManager.ReservationManager thread(421980c6) Message: SUCCESS ENTERING queue: (ec2)
2012-05-08 13:22:52,374 DEBUG imgfac.BuildJob.BuildJob thread(421980c6) Message: Builder (421980c6-0df1-4e24-8d50-362c108bdfcf) changed status from NEW to PUSHING
2012-05-08 13:22:52,374 DEBUG imgfac.BuildJob.BuildJob thread(421980c6) Message: Builder (421980c6-0df1-4e24-8d50-362c108bdfcf) changed percent complete from 0 to 0
2012-05-08 13:22:52,374 DEBUG imgfac.BuildJob.BuildJob thread(421980c6) Message: Builder (421980c6-0df1-4e24-8d50-362c108bdfcf) changed status from PUSHING to FAILED
2012-05-08 13:22:52,374 DEBUG imgfac.BuildJob.BuildJob thread(421980c6) Message: 421980c6-0df1-4e24-8d50-362c108bdfcf for ec2 about to exit ec2 queue...
2012-05-08 13:22:52,374 DEBUG imgfac.ReservationManager.ReservationManager thread(421980c6) Message: EXITING queue: (ec2)
2012-05-08 13:22:52,374 DEBUG imgfac.ReservationManager.ReservationManager thread(421980c6) Message: SUCCESS EXITING queue: (ec2)
2012-05-08 13:22:52,374 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(421980c6) Message: Exception caught in ImageFactory
2012-05-08 13:22:52,375 DEBUG imgfac.builders.BaseBuilder.Fedora_ec2_Builder thread(421980c6) Message: Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/imgfac/builders/Fedora_ec2_Builder.py", line 458, in push_image
    credentials)
  File "/usr/lib/python2.6/site-packages/imgfac/builders/Fedora_ec2_Builder.py", line 580, in push_image_snapshot_ec2
    raise ImageFactoryException("No available JEOS for desired OS, verison combination")
ImageFactoryException: No available JEOS for desired OS, verison combination

Comment 6 Dave Johnson 2012-05-08 17:43:38 UTC
so reopening this just to get it on the radar...

Comment 7 Mike Orazi 2012-08-09 15:07:34 UTC
Moving of 1.1.0 because it isn't officially supported in product.


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