I have a VirtualBox guest installed on my Windows 7 host, which is a hortonwork sandbox.
The sandbox is up and running as below:
From the output, it indicates using localhost:4200 to access it via SSH.
for localhost, in my hosts file it is defined as below:
192.168.2.29 localhost
127.0.0.1 localhost
192.168.2.29 sandbox.hortonworks.com sandbox
So I use 192.168.2.29:4200
to access the host via SSH (in browser), however, it connects but showing from 172.18.0.2
, if I run ifconfig, it also shows 172.18.0.2
as the ip address. here is the screenshot:
BUT, if I ssh into the 192.168.2.29
(Putty), I see different content in the /tmp folder:
NOTE: Browser SSH shows a completely different content than Putty SSH
If I attempt to Putty SSH to 172.18.0.2
, it will fail as below:
What is the real ip address? How can I connect to the guest via WinScp to the guest showing in Browser SSH?
VirtualBox guest's networking is set as Bridged, see below:
Windows host networking is below:
Thank you very much.
UPDATE 20190909: If I attempted to SSH into 192.168.2.29:2222 as per suggested in @Anaksunaman's answer, I got rejected as below: