Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I made an .sh file load.sh which has (almost) unlimited loop of curl requests. I run this as $ bash load.sh. Now it just keeps running the loop. I can't cancel its execution. It keeps running. I pressed ctrl+c to cancel but it starts again. I closed the terminal window. But in background script is still running. how do I get rid of it?

share|improve this question

closed as off-topic by dawud, SvW, Iain, Michael Hampton Mar 20 at 22:02

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions must demonstrate a minimal understanding of the problem being solved. Try including attempted solutions, why they didn't work, and the expected results. See How can I ask better questions on Server Fault? for further guidance." – dawud, SvW, Iain, Michael Hampton
If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer 1

up vote 0 down vote accepted

get the pid and kill the process. Its a beginner question

ps -ef | grep [l]oad.sh  # second column is the PID

kill <PID>
share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.