If you want a program to keep running after closing the terminal, than you can try screen
to run a kind of virtual terminal that keeps active on the server, and can be used from another location at another time
screen
will enter this terminal. Ctrl+a then d will detach it and
screen -r
will enable you to re-use it, with your program still running.