0

I am trying to run a Python code vote.py in AWS EC2 to collect some data about vote information in some countries. However, my current problem is that if I stop the connect with EC2, then the process will be stopped. Hence, I follow the instruction in How to run a Python script in the background even after I logout SSH?. And my current result is:

[ec2-user@ip-172-31-40-248 task1]$ pwd
/home/ec2-user/task1
[ec2-user@ip-172-31-40-248 task1]$ nohup /home/ec2-user/task1/vote.py &
[1] 27248
[ec2-user@ip-172-31-40-248 task1]$ nohup: ignoring input and appending 
output to ‘nohup.out’
Connection reset by 52.47.192.210 port 22

What does the command "nohup: ignoring input and appending output to ‘nohup.out’" mean? How can I supervise the process? This code might run several days in ec2. Thank you!

Yipin
  • 173
  • 1
  • 2
  • 12
  • you will probably want to run your script using some kind of process supervisor like supervisord or systemd. If you just want it to be quick and dirty and don't care about crashes, tmux might work too. – Azsgy Apr 13 '18 at 12:51
  • @Azsgy Thanks! Is this tmux /home/ec2-user/task1/vote.py, right? I just want to run the code for one time. – Yipin Apr 13 '18 at 13:06
  • This is not a programming question and therefore off-topic on SO. – Klaus D. Apr 13 '18 at 14:20

0 Answers0