I launch connexion ssh to use rsync command in terminal and I would like to shutdown my computer, but I need to let run the process rsync.

I executed this command on a remote host. If I quit now then the process will stop I guess?

Yes I know I should run my command with option to avoid to lost the process.

  • how did you launch the command remotely? ssh? – Sufiyan Ghori Apr 27 '18 at 11:43
  • What exact command? How was it executed - over SSH? Add details. – LinuxSecurityFreak Apr 27 '18 at 12:11
  • The typical way of managing this is to use screen(1). – vonbrand Apr 27 '18 at 13:42
  • @Sufiyan Ghori yes I use ssh then I use rsync – DragonF0rce Apr 27 '18 at 15:51
  • Look into using nohup, or screen, perhaps. – mrflash818 Apr 27 '18 at 16:02

You can run disown -a && exit which will release all the shell processes you have started from the current shell and end the current shell. The processes will continue to run.

| improve this answer | |

It is very generic, and there are many solution.

You can use nohup. But often on remote host a screen (or tmux) is used.

On the first case: process continue also if terminal is terminated (but you should no more use stdin/stout/stderr (a redirect it is ok).

On the second, it is just a virtual terminal, so you can return (from an other computer) and see the terminal.

| improve this answer | |
  • The command is running and I cant stop it now so there is a way to maintain the PID ? – DragonF0rce Apr 27 '18 at 11:56
  • Now it is late. I use the other tools, so I do not know. – Giacomo Catenazzi Apr 27 '18 at 12:03

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