OSError: Failure - please help to increase the timeout
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 9.9k
- Forks
- 2.1k
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
I am getting this exception when downloading files from several servers (network switches) at the same time.
How can I increase the timeout?
CRITICAL :: 2020-09-13 01:06:21,671 :: 46 :: Thread-4800 :: def_log_exceptions :: Unhandled exception: Traceback (most recent call last):
File "coll_diag_3.py", line 71, in run
run_old(*args, **kwargs)
File "/opt/rh/rh-python36/root/usr/lib64/python3.6/threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "coll_diag_3.py", line 228, in ssh_session
def_get_coll_diag_file(hostname, timestamp_str)
File "coll_diag_3.py", line 125, in def_get_coll_diag_file
sftp.get(remoteFilePath, localFilePath)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/pysftp/__init__.py", line 249, in get
self._sftp.get(remotepath, localpath, callback=callback)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_client.py", line 802, in get
size = self.getfo(remotepath, fl, callback)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_client.py", line 782, in getfo
reader=fr, writer=fl, file_size=file_size, callback=callback
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_client.py", line 678, in _transfer_with_callback
data = reader.read(32768)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/file.py", line 219, in read
new_data = self._read(read_size)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_file.py", line 186, in _read
CMD_READ, self.handle, long(self._realpos), int(size)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_client.py", line 813, in _request
return self._read_response(num)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_client.py", line 865, in _read_response
self._convert_status(msg)
File "/home/taakeis1/bfd_fix/lib64/python3.6/site-packages/paramiko/sftp_client.py", line 898, in _convert_status
raise IOError(text)
OSError: Failure
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with paramiko/sftp_client.py at _request and _read_response, following the traceback from sftp.get through the SFTP read. Check how timeout behavior is configured for concurrent transfers and whether the reported OSError can be reproduced. Done means the relevant timeout behavior is identified and a documented or testable resolution is established.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100