You can use screen.
sudo apt install screen
Screen allows you to run processes inside of it and leave the process running even if your pipe automatically breaks or you leave the EC2 instance.
When you connect back screen will have kept your processes running.
Here is how to use it..
1) ssh into server (or practice locally first)
2) start screen
$ screen
# press return to get back to terminal
3) run a command
$ htop
4) create a new screen
Ctrl+A then Ctrl+C
# swap Ctrl for Cmd if you have a mac
4) run another command
$ echo 'running my big process here..'
5) split the screen (vertically)
Ctrl+A then |
6) move cursor between split screens
Ctrl+A then Tab
7) move to next screen
Ctrl+A then Ctrl+N
8) detach from screen and let commands keep running
Ctrl+A then Ctrl+D
9) disconnect from server
exit
1) re-connect by ssh
2) list screens
screen -ls
3) re-attach to screen
screen -r {id}
# {id} only required if you ran the screen command multiple times
4) check out your screens
Ctrl+A then Ctrl+N
5) exit the screens
exit