2.5 Using SSH to Run Background Processes

If you choose to run CLI commands in the background via the standard SSH interface, it is possible that keyboard breaks interrupt running processes. This is a standard behaviour if the TTY setting has been set to sane, and is remedied by providing the SSH command with the -n option to automatically send keyboard input to /dev/null. This type of command can only be used with key-based authentication, since at the point that it is run, the command is run in the background so you can no longer interact with it.

$ ssh -l admin localhost -p 10000 -n "importVirtualAppliance Repository name=MyRepository
url=http://example.com/myappliance.ova" &

Note that using the -n flag does not make sense if you intend to maintain an interactive session within the CLI.