이미지 업로드 실패하는 경우

horizon.log 내에 아래와 같은 내용이 나온다.

{"data":"<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">\n<html><head>\n<title>413 Request Entity Too Large</title>\n</head><body>\n<h1>Request Entity Too Large</h1>\nThe requested resource does not allow request data with POST requests, or the amount of data provided in\nthe request exceeds the capacity limit.\n</body></html>\n","status":413,"config":{"method":"POST","transformRequest":[null],"transformResponse":[null],"jsonpCallbackParam":"callback","url":"/api/glance/images/","data":{"source_type":"file-legacy","data":{},"is_copying":false,"protected":false,"min_disk":30,"min_ram":0,"container_format":"bare","disk_format":"qcow2","visibility":"public","name":"CentOS-8"},"_isDigested":true,"_chunkSize":null,"headers":{"Accept":"application/json, text/plain, */*","X-Requested-With":"XMLHttpRequest","X-CSRFToken":"NHilkpdwFjreV0KoSHmXh0g8UsJGxrU4ZEOy1umVlAPXGl8ilV9qCgYWHCxhUulN"},"_deferred":{"promise":{}}},"statusText":"Request Entity Too Large","xhrStatus":"complete"}

또는 Horizon Dashboard 상에서 아래와 같은 오류가 발생한다.

TypeError: Cannot read properties of undefined (reading 'data')
[root@r9-director diskimage-create]# openstack image create amphora-x64-haproxy.qcow2 --container-format bare --disk-format qcow2 --private --tag amphora --file amphora-x64-haproxy.qcow2 --property hw_architecture='x86_64' --property hw_rng_model=virtio
HttpException: 503: Server Error for url: http://10.33.0.10:9292/v2/images/28b3bbb1-34af-4bd0-a678-2313a28aa8d8/file, Service Unavailable

horizon에 포함된 apache의 mod_deflate 모듈에 용량제한 코드가 박혀있는경우가 있다.

horizon.conf 의 맨 아래쪽에 아래 내용을 추가해준다.

LimitRequestBody 0

만약 cinder NFS backend를 사용중이라면 해당 경로의 퍼미션을 확인해보기 바란다.

NFS 경로를 재활용하는경우 소유주 UID/GID값이 달라 권한이 없는경우가 있다.

777 권한으로 변경하여 테스트 해보면 알 수 있다.

로그인하면 댓글을 남길 수 있습니다.
  • 이미지_업로드_실패하는_경우.txt
  • 마지막으로 수정됨: 2023/11/07 07:55
  • 저자 koov