Search code examples
bashlinode

bash: script doesn't run in the background


I have a script that performs several linux commands. When I run "./script.sh &" it works fine until I cancel the console. However, when I login again the scritp seems to be running in background but not doing anything.

What can be the problem?

Thanks


Solution

  • You forgot to use nohup when starting it.