Python IOError: [Errno 5] Input/output error?

前端 未结 2 809
感动是毒
感动是毒 2021-01-12 07:03

I m running on a remote server a python script using nohup.

  • First I connected to the remote machine using a VPN and SSH
  • Second I run a pytho

相关标签:
2条回答
  • 2021-01-12 07:15

    I finally fixed the problem by opening the file "file_in", modifying it (just adding a point in the REMARK line for example) and saving the changes.

    0 讨论(0)
  • 2021-01-12 07:25

    I had the same problem, I used to run my script using this command:

    python MY_SCRIPT.py &
    

    The script will run in the background and the output will be displayed on the terminal until you logout or exit.

    By logging out, the script is still running but it's output has nowhere to display thus, exceptions will be made when the script wants to display something (e.g. calling print).


    Solution:

    I've piped the output to somewhere other than the actual terminal display:

    python MY_SCRIPT.py >/dev/null &
    

    Checkout this link for more details:

    https://stackoverflow.com/a/38238281/6826476

    0 讨论(0)
提交回复
热议问题