Search code examples
linuxbackgroundnohup

Linux Script - How To Keep It Running Even When Logged Out?


I just started a CS GO server, I would use TCAdmin a GUI for making game servers but since Counter Strike GO is in beta, doesnt work too well with it. My question is I have a script called ./srcds_run then I run it. Works perfect. But how would I make it run as a background process so I can just log out and leave the server there?

Thanks, necro.


Solution

  • This should work:

    nohup  ./srcds_run &
    

    This puts your command in the background and has it continue to run after you log out [nohup man page]