For the above example , update the gradle file to include sshd option as sshdPort , this generates sshd config in node.conf for each node.
sshd {
port=2222
}
Reference - https://docs.corda.net/docs/corda-os/4.4/generating-a-node.html
From your local desktop Login via ssh into Remote Ubuntu machine
ssh -p <port> <ipaddress> -l user1
Reference - https://docs.corda.net/docs/corda-os/4.4/shell.html#the-shell-via-the-local-terminal
And type in run command in corda Crash shell launched
run gracefulShutdown
Reference - https://docs.corda.net/docs/corda-os/4.4/shell.html#shutting-down-the-node
This shuts down the corda node in the remote ubuntu machine.