Microsoft MVP성태의 닷넷 이야기
글쓴 사람
정성태 (techsharer at outlook.com)
홈페이지
첨부 파일
 

redis-py - MISCONF Redis is configured to save RDB snapshots, ...

어느 순간, 테스트 서버에서 호스팅 중인 컨테이너에서 각종 오류들이 쏟아졌습니다. ^^; 가령, redis 호출에 대해서는 이런 오류 메시지가 나오고,

Traceback (most recent call last):
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 2190, in wsgi_app
    response = self.full_dispatch_request()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1486, in full_dispatch_request
    rv = self.handle_user_exception(e)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1484, in full_dispatch_request
    rv = self.dispatch_request()
         ^^^^^^^^^^^^^^^^^^^^^^^
  ...[생략]...
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1469, in dispatch_request
    return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/mnt/d/workshop2/python-agent/testprj/latest_flask/pybo/views/main_views.py", line 190, in redis_test
    client.set('my_db', 5)
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/commands/core.py", line 1453, in set
    return self.execute_command('SET', *pieces, **options)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  ...[생략]...
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/client.py", line 1071, in execute_command
    return conn.retry.call_with_retry(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/retry.py", line 32, in call_with_retry
    return do()
           ^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/client.py", line 1072, in <lambda>
    lambda: self._send_command_parse_response(conn,
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/client.py", line 1051, in _send_command_parse_response
    return self.parse_response(conn, command_name, **options)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/client.py", line 1084, in parse_response
    response = connection.read_response()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/redis/connection.py", line 765, in read_response
    raise response
redis.exceptions.ResponseError: MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk. Commands that may modify the data set are disabled, because this instance is configured to report errors during writes if RDB snapshotting fails (stop-writes-on-bgsave-error option). Please check the Redis logs for details about the RDB error.

Mongo DB 호출은 이렇게 나오고,

Traceback (most recent call last):
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 2190, in wsgi_app
    response = self.full_dispatch_request()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1486, in full_dispatch_request
    rv = self.handle_user_exception(e)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1484, in full_dispatch_request
    rv = self.dispatch_request()
         ^^^^^^^^^^^^^^^^^^^^^^^
  ...[생략]...
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1469, in dispatch_request
    return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/mnt/d/workshop2/python-agent/testprj/latest_flask/pybo/views/main_views.py", line 215, in pymongotest
    db2.users.delete_many({'y': 1})
  ...[생략]...
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/collection.py", line 1451, in delete_many
    self._delete_retryable(
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/collection.py", line 1360, in _delete_retryable
    return self.__database.client._retryable_write(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/mongo_client.py", line 1643, in _retryable_write
    with self._tmp_session(session) as s:
  File "/usr/lib/python3.11/contextlib.py", line 137, in __enter__
    return next(self.gen)
           ^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/mongo_client.py", line 2040, in _tmp_session
    s = self._ensure_session(session)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/mongo_client.py", line 2027, in _ensure_session
    return self.__start_session(True, causal_consistency=False)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/mongo_client.py", line 1976, in __start_session
    server_session = self._get_server_session()
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/mongo_client.py", line 2013, in _get_server_session
    return self._topology.get_server_session()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/topology.py", line 525, in get_server_session
    session_timeout = self._check_session_support()
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/topology.py", line 507, in _check_session_support
    self._select_servers_loop(
  File "/home/testusr/.local/lib/python3.11/site-packages/pymongo/topology.py", line 226, in _select_servers_loop
    raise ServerSelectionTimeoutError(
pymongo.errors.ServerSelectionTimeoutError: 192.168.100.50:15000: [Errno 111] Connection refused, Timeout: 30s, Topology Description: <TopologyDescription id: 6508f21066abc5620a3c1622, topology_type: Single, servers: [<ServerDescription ('192.168.100.50', 15000) server_type: Unknown, rtt: None, error=AutoReconnect('192.168.100.50:15000: [Errno 111] Connection refused')>]>

MySQL 서버 호출은 이런 오류가 발생합니다.

Traceback (most recent call last):
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 2190, in wsgi_app
    response = self.full_dispatch_request()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1487, in full_dispatch_request
    return self.finalize_request(rv)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1506, in finalize_request
    response = self.make_response(rv)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/testusr/.local/lib/python3.11/site-packages/flask/app.py", line 1801, in make_response
    raise TypeError(
TypeError: The view function for 'main.mysqlclient_wrapper2' did not return a valid response. The function either returned None or ended without a return statement.

당황하지 마시고, 컨테이너를 호스팅하는 서버의 디스크 용량을 확인해 보시고, 꽉 찼으면 여유 공간을 확보해 주시면 됩니다. (그나저나, redis의 오류 메시지가 그나마 실제 상황에 가깝군요. ^^)




[이 글에 대해서 여러분들과 의견을 공유하고 싶습니다. 틀리거나 미흡한 부분 또는 의문 사항이 있으시면 언제든 댓글 남겨주십시오.]







[최초 등록일: ]
[최종 수정일: 9/19/2023]

Creative Commons License
이 저작물은 크리에이티브 커먼즈 코리아 저작자표시-비영리-변경금지 2.0 대한민국 라이센스에 따라 이용하실 수 있습니다.
by SeongTae Jeong, mailto:techsharer at outlook.com

비밀번호

댓글 작성자
 




1  2  3  4  5  [6]  7  8  9  10  11  12  13  14  15  ...
NoWriterDateCnt.TitleFile(s)
13714정성태8/19/20243446닷넷: 2295. C# 12 - 기본 생성자(Primary constructors) (책 오타 수정) [3]
13713정성태8/16/20243629개발 환경 구성: 721. WSL 2에서의 Hyper-V Socket 연동
13712정성태8/14/20243613개발 환경 구성: 720. Synology NAS - docker 원격 제어를 위한 TCP 바인딩 추가
13711정성태8/13/20244167Linux: 77. C# / Linux - zombie process (defunct process) [1]파일 다운로드1
13710정성태8/8/20244290닷넷: 2294. C# 13 - (6) iterator 또는 비동기 메서드에서 ref와 unsafe 사용을 부분적으로 허용파일 다운로드1
13709정성태8/7/20244147닷넷: 2293. C# - safe/unsafe 문맥에 대한 C# 13의 (하위 호환을 깨는) 변화파일 다운로드1
13708정성태8/7/20243933개발 환경 구성: 719. ffmpeg / YoutubeExplode - mp4 동영상 파일로부터 Audio 파일 추출
13707정성태8/6/20244388닷넷: 2292. C# - 자식 프로세스의 출력이 4,096보다 많은 경우 Process.WaitForExit 호출 시 hang 현상파일 다운로드1
13706정성태8/5/20244750개발 환경 구성: 718. Hyper-V - 리눅스 VM에 새로운 디스크 추가
13705정성태8/4/20244944닷넷: 2291. C# 13 - (5) params 인자 타입으로 컬렉션 허용 [2]파일 다운로드1
13704정성태8/2/20244494닷넷: 2290. C# - 간이 dotnet-dump 프로그램 만들기파일 다운로드1
13703정성태8/1/20244677닷넷: 2289. "dotnet-dump ps" 명령어가 닷넷 프로세스를 찾는 방법
13702정성태7/31/20244529닷넷: 2288. Collection 식을 지원하는 사용자 정의 타입을 CollectionBuilder 특성으로 성능 보완파일 다운로드1
13701정성태7/30/20244452닷넷: 2287. C# 13 - (4) Indexer를 이용한 개체 초기화 구문에서 System.Index 연산자 허용파일 다운로드1
13700정성태7/29/20244078디버깅 기술: 200. DLL Export/Import의 Hint 의미
13699정성태7/27/20244468닷넷: 2286. C# 13 - (3) Monitor를 대체할 Lock 타입파일 다운로드1
13698정성태7/27/20244219닷넷: 2285. C# - async 메서드에서의 System.Threading.Lock 잠금 처리파일 다운로드1
13697정성태7/26/20244413닷넷: 2284. C# - async 메서드에서의 lock/Monitor.Enter/Exit 잠금 처리파일 다운로드1
13696정성태7/26/20244212오류 유형: 920. dotnet publish - error NETSDK1047: Assets file '...\obj\project.assets.json' doesn't have a target for '...'
13695정성태7/25/20244000닷넷: 2283. C# - Lock / Wait 상태에서도 STA COM 메서드 호출 처리파일 다운로드1
13694정성태7/25/20244424닷넷: 2282. C# - ASP.NET Core Web App의 Request 용량 상한값 (Kestrel, IIS)
13693정성태7/24/20243917개발 환경 구성: 717. Visual Studio - C# 프로젝트에서 레지스트리에 등록하지 않은 COM 개체 참조 및 사용 방법파일 다운로드1
13692정성태7/24/20244560디버깅 기술: 199. Windbg - 리눅스에서 뜬 닷넷 응용 프로그램 덤프 파일에 포함된 DLL의 Export Directory 탐색
13691정성태7/23/20244149디버깅 기술: 198. Windbg - 스레드의 Win32 Message Queue 정보 조회
13690정성태7/23/20243789오류 유형: 919. Visual C++ 리눅스 프로젝트 - error : ‘u8’ was not declared in this scope
13689정성태7/22/20244476디버깅 기술: 197. Windbg - PE 포맷의 Export Directory 탐색
1  2  3  4  5  [6]  7  8  9  10  11  12  13  14  15  ...