I am using SSH to start a background process on a remote server. This is what I have at the moment:
ssh remote_user@server.com \"nohup process &\"
You could use screen
to run your process on this screen, detach from screen Ctrl-a :detach
and exit your current session without problem. Then you can reconnect to SSH and attach to this screen again to continue with your task or check if is finished.
Or you can send the command to an already running screen. Your local script should look like this:
ssh remote_user@server.com
screen -dmS new_screen sh
screen -S new_screen -p 0 -X stuff $'nohup process \n'
exit
For more info see this tutorial