F5Networks / f5-openstack-image-prep

Contains scripts to prepare an F5® BIG-IP® VE image file to boot in OpenStack.
Apache License 2.0
0 stars 13 forks source link

Keystone authentication failure when patching images in Mitaka #22

Closed swormke closed 7 years ago

swormke commented 8 years ago

Description

Running the F5 VE on boarding heat template in https://github.com/F5Networks/f5-openstack-heat/blob/develop/f5_supported/ve/images/patch_upload_ve_image.yaml fails with the following error. This was run on an OpenStack system installed with the Mitaka version.

Traceback (most recent call last):
  File "ve_image_sync.py", line 149, in <module>
    ve_image_sync.sync_image()
  File "ve_image_sync.py", line 117, in sync_image
    img_model = self._upload_image_to_glance(prepped_image)
  File "ve_image_sync.py", line 100, in _upload_image_to_glance
    gc = GlanceLib(self.os_creds).glance_client
  File "/home/imageprep/f5-openstack-image-prep/f5_image_prep/openstack/glance.py", line 25, in __init__
    self.glance_client = get_glance_client(creds)
  File "/home/imageprep/f5-openstack-image-prep/f5_image_prep/openstack/client.py", line 46, in get_glance_client
    keystone_client = get_keystone_client(creds)
  File "/home/imageprep/f5-openstack-image-prep/f5_image_prep/openstack/client.py", line 31, in get_keystone_client
    auth_url=creds.auth_url)
  File "/usr/lib/python2.7/dist-packages/keystoneclient/v2_0/client.py", line 144, in __init__
    self.authenticate()
  File "/usr/lib/python2.7/dist-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/keystoneclient/httpclient.py", line 392, in authenticate
    resp = self.get_raw_token_from_identity_service(**kwargs)
  File "/usr/lib/python2.7/dist-packages/keystoneclient/v2_0/client.py", line 179, in get_raw_token_from_identity_service
    "%s" % e)
keystoneclient.apiclient.exceptions.AuthorizationFailure: Authorization Failed: Failed to parse: Failed to parse: http:

Debug Output

2016-06-03 20:16:20 (78.1 MB/s) - 'f5_ve_image.zip' saved [1133813050/1133813050]

+ unzip f5_ve_image.zip BIGIP-11.6.0.0.0.401.qcow2
Archive:  f5_ve_image.zip
  inflating: BIGIP-11.6.0.0.0.401.qcow2  
+ python ve_image_sync.py -i BIGIP-11.6.0.0.0.401.qcow2
sudo: unable to resolve host fu-st-patch-ve-image-image-prep-instance-kft6u53kjezh
+ '[' -n '' ']'
+ '[' -n '' ']'
+ check_oldfile_full_path
+ '[' -f BIGIP-11.6.0.0.0.401.qcow2 ']'
++ basename BIGIP-11.6.0.0.0.401.qcow2
+ ofname=BIGIP-11.6.0.0.0.401.qcow2
+ '[' -z os_ready-BIGIP-11.6.0.0.0.401.qcow2 ']'
+ cp BIGIP-11.6.0.0.0.401.qcow2 /home/imageprep/os_ready-BIGIP-11.6.0.0.0.401.qcow2
+ sleep 2
+ qemu-nbd -d /dev/nbd0
+ sleep 2
+ qemu-nbd --connect=/dev/nbd0 /home/imageprep/os_ready-BIGIP-11.6.0.0.0.401.qcow2
+ sleep 2
+ pvscan
+ sleep 2
+ echo 'The following command may cause '\''Can'\''t deactivate'\'' messages.'
+ echo 'These do not necessarily indicate a problem.'
+ vgchange -ay
+ sleep 2
+ mkdir -p /mnt/bigip-config
+ '[' -n '' ']'
+ echo 'Waiting 15 seconds'
+ sleep 15
+ umount /mnt/bigip-config
umount: /mnt/bigip-config: not mounted
+ '[' 1 -eq 1 ']'
+ umount /mnt/bigip-shared
umount: /mnt/bigip-shared: not found
+ '[' 1 -eq 1 ']'
++ get_dev set.1._config
++ ls -l /dev/vg-db-hda
++ grep set.1._config
++ cut '-d>' -f2
++ cut -d/ -f2-
+ mount /dev/dm-6 /mnt/bigip-config
+ inject_files
+ '[' -f /home/imageprep/f5-openstack-image-prep/lib/f5_image_prep/startup.tar ']'
+ tar -xf /home/imageprep/f5-openstack-image-prep/lib/f5_image_prep/startup.tar -C /mnt/bigip-config/
+ true
+ touch /mnt/bigip-config/firstboot
+ '[' -f none ']'
+ '[' -n '' ']'
+ '[' -n '' ']'
+ sleep 2
+ umount /mnt/bigip-config
+ sleep 2
+ '[' -n '' ']'
+ sleep 2
+ vgchange -an
+ sleep 2
+ qemu-nbd -d /dev/nbd0
[  161.857848] block nbd0: Unexpected reply (ffff8800b9711c78)
+ echo 'Patched image located at /home/imageprep/os_ready-BIGIP-11.6.0.0.0.401.qcow2'
+ set +x

Patching image...

Uploading patched image to glance...

Traceback (most recent call last):
  File "ve_image_sync.py", line 149, in <module>
    ve_image_sync.sync_image()
  File "ve_image_sync.py", line 117, in sync_image
    img_model = self._upload_image_to_glance(prepped_image)
  File "ve_image_sync.py", line 100, in _upload_image_to_glance
    gc = GlanceLib(self.os_creds).glance_client
  File "/home/imageprep/f5-openstack-image-prep/f5_image_prep/openstack/glance.py", line 25, in __init__
    self.glance_client = get_glance_client(creds)
  File "/home/imageprep/f5-openstack-image-prep/f5_image_prep/openstack/client.py", line 46, in get_glance_client
    keystone_client = get_keystone_client(creds)
  File "/home/imageprep/f5-openstack-image-prep/f5_image_prep/openstack/client.py", line 31, in get_keystone_client
    auth_url=creds.auth_url)
  File "/usr/lib/python2.7/dist-packages/keystoneclient/v2_0/client.py", line 144, in __init__
    self.authenticate()
  File "/usr/lib/python2.7/dist-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/keystoneclient/httpclient.py", line 392, in authenticate
    resp = self.get_raw_token_from_identity_service(**kwargs)
  File "/usr/lib/python2.7/dist-packages/keystoneclient/v2_0/client.py", line 179, in get_raw_token_from_identity_service
    "%s" % e)
keystoneclient.apiclient.exceptions.AuthorizationFailure: Authorization Failed: Failed to parse: Failed to parse: http:
2016-06-03 20:18:06,847 - util.py[WARNING]: Failed running /var/lib/cloud/instance/scripts/part-001 [1]
pjbreaux commented 8 years ago

Not sure this is an actual issue. I qualified our Heat templates in Mitaka last week and @szakeri will be doing it this week. Once she has replicated my success, I will close this issue.

dflanigan commented 7 years ago

@pjbreaux could you confirm if this is still an issue.

pjbreaux commented 7 years ago

This is not an issue anymore, but I opened up the real issue here: https://github.com/F5Networks/f5-openstack-image-prep/issues/60