I am practicing on AWS instance for HDPCD test from the link: https://hortonworks.com/wp-content/uploads/2015/02/HDPCD-PracticeExamGuide1.pdf
I have started AWS instance as mentioned in the step by step procedure and was able to reach till step 12. The AWS instance is in "running" state. For step-13, which is installing a VNC client, I have done it through http://www.realvnc.com/download/viewer/ link provided. I have selected 64 bit version for windows. When I provide the public DNS followed by :5901 port and hitting "connect" I am getting the timeout error.
Q1: What is the correct version of VNC client/viewer to be used. I have selected 64 bit version for Windows. Q2. Do I have to mention 5901 port anywhere in the VNC configuration. I have already mentioned that in AWS (Configure Security Group >> Custom TCP Rule >> Port 5901 >> IP: 0.0.0.0/0
Yes - you put port 5901 at the end of the public DNS, but it looks like you already did that.
In almost all situations, you inability to connect using VNC is due to a firewall setting on your computer or on your internet connection. Your connection is blocking port 5901. If you are trying to connect from work, you should wait until you get home and try your home internet connection. Otherwise, disable the firewall and anti-virus software on your laptop and see if that helps.
Thanks @Rich Raposa for your prompt reply.
I tried with my home network and still getting the same error on VNC: "Timed out waiting for a response from the host computer". a. I have used entire aws public DNS followed by port (ec2-52-38-116-3.us-west-2.compute.amazonaws.com:5901) b. VNC viewer also asked for the Encryption. I have given Let VNC Server choose. c. I have also tried opening port explicitly in Windows firewall by going to Control Panel >>> Windows Firewall >>> Advance Settings >>> Inbound Rules >>> New Rule >>> and added TCP port 5901. The same is done for Outbound Rules.
Still getting the same error. Am I missing something crucial here?
I can't even ping that public DNS, so that is part of the issue. When you launch the AMI, make sure you check the box that gives it a public IP address - which is the "Configure Instance Details" step of the launch wizard.
At this point, I would recommend terminating your current EC2 instance and launching a new one.
Thanks @Rich Raposa
My current instance has the public IP Address (Public IP 220.127.116.11). I even tried VNC viewer with this IP as 18.104.22.168::5901 as well, and got the same error. The public IP in "Configure Instance Details" was already enabled.
Again, I terminated the old instance and relaunched the new EC2 instance with details - Public DNS ec2-52-40-163-86.us-west-2.compute.amazonaws.com and Public IP 22.214.171.124. Still I get the same error. I am now doubting if my VNC viewer is correct.
Can you ping your server on its public DNS? Mayank's server was unreachable, but your issue could be something else. Did you disable the firewall settings on your laptop? Like I said before, the most common reason for not being able to connect is that port 5901 is blocked.
@Luca Natali Did you try disabling the firewall settings on your machine? @Rich Raposa I also tried pinging my running server using windows>>>>CMD and it was giving me timeout. Do I need to wait for the server to be up (although the status says running on AWS)?
One more query - I have just installed the VNC viewer (client), however the step by step guide says that "In the Address field, enter the public DNS name of your EC2 instance, followed by :5901 (which is the port that the VNC server is listening on):" Do I need to install VNC server as well?