Zend certified PHP/Magento developer

SSH to AWS EC2 instance hangs

I was able to log in to my ec2 instance via ssh few days ago. But somehow today when I connected it with
ssh -i something.pem ubuntu@ip_address -v
then the terminal hung on this line:
debug1: Local version string SSH-2.0-OpenSSH_8.6.
I’ve tried to reboot the ec2 instance but it’s not working.
security group is properly set up that allows ssh connection.