Because the connection is inside the qualifications, you will need to uncover its PID to kill it. You can do so by trying to find the port you forwarded: SSH, or Safe Shell, is a network protocol that gives a safe strategy to accessibility a remote server, like an EC2 https://servicessh.com/