Bug 801193 - Clicking on 'Test Connection' for an ec2 account gives 'undefined method `permissions' for nil:NilClass' error
Clicking on 'Test Connection' for an ec2 account gives 'undefined method `per...
Status: CLOSED ERRATA
Product: CloudForms Cloud Engine
Classification: Red Hat
Component: aeolus-conductor (Show other bugs)
1.0.0
x86_64 Linux
unspecified Severity high
: rc
: ---
Assigned To: Scott Seago
wes hayutin
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-03-07 16:54 EST by Ronelle Landy
Modified: 2012-05-15 18:50 EDT (History)
5 users (show)

See Also:
Fixed In Version: v0.8.1-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-05-15 18:50:02 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
permissions error (182.96 KB, image/png)
2012-03-07 16:54 EST, Ronelle Landy
no flags Details
end of rails.log (38.65 KB, text/x-log)
2012-03-13 08:40 EDT, Ronelle Landy
no flags Details

  None (edit)
Description Ronelle Landy 2012-03-07 16:54:43 EST
Created attachment 568436 [details]
permissions error

Description of problem:

 - Ran aeolus-configure -p mock, ec2
 - Ran aeolus-configure -p rhevm
 - Ran aeolus-configure -p vsphere
 - Ran aeolus-restart-services
 - Started conductor - logged in as admin
 - Added account for rhevm and vsphere
 - Built and pushed images for vsphere and rhevm successfully
 - Added and account for ec2 - ec2-us-east-1
 - Built and image for ec2 
 - Tried to push the image ... failed (see error copied from .var/log/imagefactory.log)
 - Went to check ec2 account ... thinking there is an issue with creds
 - Clicked 'Cloud Resource Providers' -> 'ec2-us-east-1' -> 'ec2Account' -> 'Test Connection'

Conductor displayed:

Notices

    Test Connection Success: Valid Account Details

Errors
undefined method `permissions' for nil:NilClass

See attached screenshot.


***** Error from /var/log/imagefactory.log ******

 Permanently added 'ec2-50-19-76-213.compute-1.amazonaws.com,50.19.76.213' (RSA) to the list of known hosts.
1+0 records in
1+0 records out
1048576 bytes (1.0 MB) copied, 0.0031964 s, 328 MB/s
mke2fs 1.41.14 (22-Dec-2010)
Traceback (most recent call last):
  File "/usr/bin/euca-bundle-vol", line 492, in <module>
    main()
  File "/usr/bin/euca-bundle-vol", line 467, in main
    ancestor_ami_ids,
  File "/usr/lib/python2.7/site-packages/euca2ools/__init__.py", line 994, in generate_manifest
    user_pub_key = X509.load_cert(cert_path).get_pubkey().get_rsa()
  File "/usr/lib64/python2.7/site-packages/M2Crypto/X509.py", line 611, in load_cert
    return load_cert_bio(bio)
  File "/usr/lib64/python2.7/site-packages/M2Crypto/X509.py", line 639, in load_cert_bio
    raise X509Error(Err.get_error())
M2Crypto.X509.X509Error: 140702711510816:error:0906D06C:PEM routines:PEM_read_bio:no start line:pem_lib.c:696:Expecting: CERTIFICATE

*****************

RPMs tested:

rpm -qa |grep aeolus
aeolus-conductor-doc-0.8.0-41.el6.noarch
rubygem-aeolus-image-0.3.0-12.el6.noarch
rubygem-aeolus-cli-0.3.0-13.el6.noarch
aeolus-conductor-0.8.0-41.el6.noarch
aeolus-configure-2.5.0-18.el6.noarch
aeolus-conductor-daemons-0.8.0-41.el6.noarch
aeolus-all-0.8.0-41.el6.noarch


rpm -qa |grep image
imagefactory-1.0.0rc8-1.el6.noarch
genisoimage-1.1.9-11.el6.x86_64
rubygem-aeolus-image-0.3.0-12.el6.noarch
rubygem-imagefactory-console-0.4.0-1.el6.noarch
imagefactory-jeosconf-ec2-rhel-1.0.0rc8-1.el6.noarch
imagefactory-jeosconf-ec2-fedora-1.0.0rc8-1.el6.noarch

*********************************

The same certificates uploaded to ec2 Account in previous aeolus version did not give any errors:

rpm -qa |grep aeolus
rubygem-aeolus-image-0.3.0-10.el6.noarch
aeolus-configure-2.5.0-15.el6.noarch
aeolus-conductor-doc-0.8.0-38.el6.noarch
aeolus-conductor-daemons-0.8.0-38.el6.noarch
rubygem-aeolus-cli-0.3.0-11.el6.noarch
aeolus-all-0.8.0-38.el6.noarch
aeolus-conductor-0.8.0-38.el6.noarch
Comment 1 Scott Seago 2012-03-12 23:24:46 EDT
I'd like to see the stack trace from rails.log that corresponds to that permissions error.

I think I know what's going on, but the error I'm getting on my end is slightly different.

I'll submit a patch that fixes the error I'm seeing here, which I hope will fix the reported issue as well (it looks like a similar problem). Once I see that stacktrace I'll know for sure.
Comment 2 Scott Seago 2012-03-13 00:18:53 EDT
Patch posted here: https://fedorahosted.org/pipermail/aeolus-devel/2012-March/009542.html
Comment 3 Ronelle Landy 2012-03-13 08:40:45 EDT
Created attachment 569661 [details]
end of rails.log

rails.log from the conductor instance where I saw the permissions error is large (over 19.6MB). I attached just the text from today - where I clicked on 'Test Connection' and saw the error again. If you need more of the log, you can pull it from: ibm-x3200m3-01.rhts.eng.bos.redhat.com (Beaker machine) or let me know and I'll attach the full log.
Comment 4 Scott Seago 2012-03-13 09:44:29 EDT
OK, from the log, it looks like you're hitting the same root cause that I hit, just at a different point in the view code, possibly due to unrelated differences in what's on the development tip and what's in the build you're testing with. The posted patch should resolve both issues just the same, so this should be resolved once the fix is ACKed and pushed.
Comment 5 Scott Seago 2012-03-15 19:07:20 EDT
Pushed to master at f9f53bcd0e96eef0875f4dd6e226d5aab267a11c
Comment 7 Rehana 2012-04-04 11:17:54 EDT
Able to build/push/ launch instance on ec2. and also the test connection was success-full.

verified on:

 rpm -qa | grep aeolus
rubygem-aeolus-image-0.3.0-12.el6.noarch
aeolus-conductor-0.8.7-1.el6.noarch
aeolus-conductor-doc-0.8.7-1.el6.noarch
aeolus-conductor-daemons-0.8.7-1.el6.noarch
aeolus-configure-2.5.2-1.el6.noarch
aeolus-all-0.8.7-1.el6.noarch
rubygem-aeolus-cli-0.3.1-1.el6.noarch
Comment 9 errata-xmlrpc 2012-05-15 18:50:02 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2012-0583.html

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