I create ssh pub/private keys to access the remote VM. I copied the public keys in the VM ssh config and was able to access the VM very fine. After a few days, it just stopped working and I was getting the connection time out. I tried every things configuration so that I can reconnect it but nothing works. This includes creating new ssh keys, deleting and creating a new VM, and changing AZ, but nothing works.
But I don’t know why but I switched to another wifi network (which is basically the same router but with 2.4 GHz and earlier was 5GHz) and tried to connect and surprisingly It worked. But I don’t know the reason behind it. Does anyone have any idea about it?