이미지 업로드 에러발생시
리눅스/Ceph2017. 8. 7. 09:51
반응형
원인 : token id 인증유효기간
ImageNotAuthorized: Not authorized for image 9caecc4e-eaf0-48c6-aebe-04581707ff2b.
기본값은 3600초 (1시간)
이미지를 Upload 시점부터 주기적으로 image 상태를 체크하게 되는데 완료된 시점에 처음시점에 발급받은 토큰 유효기간이 지나면서 인증에 오류발생
# cat /etc/keystone/keystone.conf
..............
[token]
provider = fernet
expiration =9000
:: 2시간 30분
# service apache2 restart
# date
2017. 08. 01. (화) 11:34:42 KST
# openstack token issue -c expires
+---------+-----------------------------+
| Field | Value |
+---------+-----------------------------+
| expires | 2017-08-01T12:34:50.751559Z |
+---------+-----------------------------+
# service apache2 restart
# openstack token issue -c expires
+---------+-----------------------------+
| Field | Value |
+---------+-----------------------------+
| expires | 2017-08-01T14:05:06.677567Z |
+---------+-----------------------------+
# cat /var/log/cinder/cinder-volume.log
..........................................
2017-07-18 17:40:23.130 24165 INFO cinder.volume.manager [req-ce23ac35-f334-43f0-909a-4b89cd47c5c7 21600390e35444bb989d79b4bc4ca15f 07edea9946d84472b2dfd8214c39bfb0 - - -] Created volume successfully.
2017-07-18 17:40:26.067 24165 INFO cinder.volume.manager [req-05c9cc61-a77f-410e-a481-770ab11659a9 21600390e35444bb989d79b4bc4ca15f 07edea9946d84472b2dfd8214c39bfb0 - - -] Initialize volume connection completed successfully.
2017-07-18 17:40:27.880 24165 INFO cinder.volume.manager [req-7526c5c2-50ea-458e-90b7-3718f6c26bee 21600390e35444bb989d79b4bc4ca15f 07edea9946d84472b2dfd8214c39bfb0 - - -] Attach volume completed successfully.
2017-07-18 17:52:08.341 24165 INFO cinder.image.image_utils [req-067b3d37-01ec-42b7-b178-547670a0c029 0989cabab0124d578b69f1e4aa9a1841 7d5a2d6a87b7425b84a23a673a1a530d - - -] Converted 153600.00 MB image at 83.71 MB/s
2017-07-18 18:58:50.151 24165 ERROR cinder.volume.manager [req-067b3d37-01ec-42b7-b178-547670a0c029 0989cabab0124d578b69f1e4aa9a1841 7d5a2d6a87b7425b84a23a673a1a530d - - -] Upload volume to image encountered an error (image-id: 9caecc4e-eaf0-48c6-aebe-04581707ff2b).
2017-07-18 18:58:53.549 24165 WARNING cinder.volume.manager [req-067b3d37-01ec-42b7-b178-547670a0c029 0989cabab0124d578b69f1e4aa9a1841 7d5a2d6a87b7425b84a23a673a1a530d - - -] Image delete encountered an error.
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager Traceback (most recent call last):
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 1330, in _delete_image
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager image_meta = image_service.show(context, image_id)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 245, in show
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager _reraise_translated_image_exception(image_id)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 555, in _reraise_translated_image_exception
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager six.reraise(type(new_exc), new_exc, exc_trace)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 243, in show
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager image = self._client.call(context, 'get', image_id)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 177, in call
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager return getattr(controller, method)(*args, **kwargs)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/glanceclient/v1/images.py", line 132, in get
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager % urlparse.quote(str(image_id)))
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 272, in head
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager return self._request('HEAD', url, **kwargs)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 267, in _request
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager resp, body_iter = self._handle_response(resp)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 83, in _handle_response
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager raise exc.from_response(resp, resp.content)
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager ImageNotAuthorized: Not authorized for image 9caecc4e-eaf0-48c6-aebe-04581707ff2b.
2017-07-18 18:58:53.549 24165 ERROR cinder.volume.manager
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher [req-067b3d37-01ec-42b7-b178-547670a0c029 0989cabab0124d578b69f1e4aa9a1841 7d5a2d6a87b7425b84a23a673a1a530d - - -] Exception during message handling: Not authorized for image 9caecc4e-eaf0-48c6-aebe-04581707ff2b.
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher Traceback (most recent call last):
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 138, in _dispatch_and_reply
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher incoming.message))
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 185, in _dispatch
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher return self._do_dispatch(endpoint, method, ctxt, args)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 127, in _do_dispatch
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher result = func(ctxt, **new_args)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 1320, in copy_volume_to_image
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher payload['message'] = six.text_type(error)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher self.force_reraise()
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher six.reraise(self.type_, self.value, self.tb)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 1306, in copy_volume_to_image
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher image_service, image_meta)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/volume/drivers/rbd.py", line 961, in copy_volume_to_image
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher image_meta, tmp_file)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/image/image_utils.py", line 414, in upload_volume
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher image_service.update(context, image_id, {}, image_file)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 364, in update
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher _reraise_translated_image_exception(image_id)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 555, in _reraise_translated_image_exception
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher six.reraise(type(new_exc), new_exc, exc_trace)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 362, in update
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher **image_meta)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/cinder/image/glance.py", line 177, in call
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher return getattr(controller, method)(*args, **kwargs)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/glanceclient/v1/images.py", line 365, in update
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher resp, body = self.client.put(url, headers=hdrs, data=image_data)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 281, in put
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher return self._request('PUT', url, **kwargs)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/glanceclient/v1/images.py", line 365, in update
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher resp, body = self.client.put(url, headers=hdrs, data=image_data)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 281, in put
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher return self._request('PUT', url, **kwargs)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 267, in _request
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher resp, body_iter = self._handle_response(resp)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/glanceclient/common/http.py", line 83, in _handle_response
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher raise exc.from_response(resp, resp.content)
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher ImageNotAuthorized: Not authorized for image 9caecc4e-eaf0-48c6-aebe-04581707ff2b.
2017-07-18 18:58:53.615 24165 ERROR oslo_messaging.rpc.dispatcher
[출처] https://chonnom.com/bbs/board.php?bo_table=OpenStack&wr_id=524
반응형
'리눅스 > Ceph' 카테고리의 다른 글
Rocky Linux 8 에서 Ceph 17 (Quincy) 설치하기 (0) | 2023.05.15 |
---|---|
Ceph qcow2 실제 디스크 사용량으로 변환 (zero-fill) (0) | 2017.07.07 |
Ceph qemu-nbd and zerofill 사용하고 다시 줄어든 용량 적용해주기 (0) | 2017.07.07 |
Ceph 실제 고객이 사용하는 블록스토리지 1개 사용량 확인하기 (0) | 2017.07.07 |
Ceph mount 명령어 스크립트를 암호화 하여 (부팅시) 다른 데몬 보다 먼저 구동하기 (0) | 2016.09.02 |
댓글()