#原因がわかったので新しく質問しました
CentOS7にインストールしたPython3.6でSSL通信をするライブラリを使ったのですが、その時エラーが出て、通信ができません。
どうやったら解決できるか教えてください。
#環境
- CentOS Linux release 7.4.1708 (Core)
- Python 3.6.4(IUSからyumで
python36u
をインストール) - ConoHaのメモリ512MBプラン
#試したこと
- OSの再インストール
update-ca-trust
を実行- OpenSSLのアップデート
- cURLがNSSを使うようになっていたので、OpenSSLを使うようにコンパイル
- 接続先がmacのcURLからは正常にアクセスできることを確認
#発生するエラー
File "/usr/lib/python3.6/site-packages/thrift/transport/THttpClient.py", line 141, in _f result = f(*args, **kwargs) File "/usr/lib/python3.6/site-packages/thrift/transport/THttpClient.py", line 181, in flush self.__http.endheaders() File "/usr/lib64/python3.6/http/client.py", line 1234, in endheaders self._send_output(message_body, encode_chunked=encode_chunked) File "/usr/lib64/python3.6/http/client.py", line 1026, in _send_output self.send(msg) File "/usr/lib64/python3.6/http/client.py", line 964, in send self.connect() File "/usr/lib64/python3.6/http/client.py", line 1400, in connect server_hostname=server_hostname) File "/usr/lib64/python3.6/ssl.py", line 407, in wrap_socket _context=self, _session=session) File "/usr/lib64/python3.6/ssl.py", line 814, in __init__ self.do_handshake() File "/usr/lib64/python3.6/ssl.py", line 1068, in do_handshake self._sslobj.do_handshake() File "/usr/lib64/python3.6/ssl.py", line 689, in do_handshake self._sslobj.do_handshake() ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:777)
最後に実行してからしばらく時間をおくと、下のエラーが出て、もう1度実行すると上のエラーになります
File "/usr/lib/python3.6/site-packages/thrift/transport/THttpClient.py", line 141, in _f result = f(*args, **kwargs) File "/usr/lib/python3.6/site-packages/thrift/transport/THttpClient.py", line 181, in flush self.__http.endheaders() File "/usr/lib64/python3.6/http/client.py", line 1234, in endheaders self._send_output(message_body, encode_chunked=encode_chunked) File "/usr/lib64/python3.6/http/client.py", line 1026, in _send_output self.send(msg) File "/usr/lib64/python3.6/http/client.py", line 964, in send self.connect() File "/usr/lib64/python3.6/http/client.py", line 1400, in connect server_hostname=server_hostname) File "/usr/lib64/python3.6/ssl.py", line 407, in wrap_socket _context=self, _session=session) File "/usr/lib64/python3.6/ssl.py", line 814, in __init__ self.do_handshake() File "/usr/lib64/python3.6/ssl.py", line 1068, in do_handshake self._sslobj.do_handshake() File "/usr/lib64/python3.6/ssl.py", line 689, in do_handshake self._sslobj.do_handshake() ConnectionResetError: [Errno 104] Connection reset by peer

回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2018/03/26 04:54 編集
2018/03/26 04:56
2018/03/26 04:58
2018/03/26 05:00
2018/03/26 05:12
2018/03/26 05:13
2018/03/26 05:18
2018/03/26 05:23