Created on 05-26-2017 07:09 AM - edited 09-16-2022 04:39 AM
Hi, My questions is somehow similar to this one, but it is still not clear for me. So I ask it again:
I am running HDP Sandbox on VMware in Win 10. I can successfully connect to sandbox using SSH and port 2222 and run hadoop commands. However, on virtual machine itself where sandbox image is loaded, I cannot run and hadoop commands. So everytime I want to run hadoop commands, do I need to use SSH command and putty?
Created 05-26-2017 07:15 AM
Sandbox runs on docker container. So some profile configs are loaded only when you do "ssh on port 2222"
This is the way port forwarding works is that it exposes port 22 of the sandbox machine to the outside network of your PC via port 2222.
# ssh root@127.0.0.1 -p 2222
Or using putty on port 2222 ssh port.
.
But alternatively you can also try using the WebTerminal to run the commands like:
.
Created 05-26-2017 07:15 AM
Sandbox runs on docker container. So some profile configs are loaded only when you do "ssh on port 2222"
This is the way port forwarding works is that it exposes port 22 of the sandbox machine to the outside network of your PC via port 2222.
# ssh root@127.0.0.1 -p 2222
Or using putty on port 2222 ssh port.
.
But alternatively you can also try using the WebTerminal to run the commands like:
.
Created 05-26-2017 07:19 AM
Are you able to run hadoop commands in your sandbox?
Created 05-26-2017 07:29 AM
Yes, After doing ssh on the designed and documented port 2222 i am able to do so.
HW11189:ambari jsensharma$ ssh root@127.0.0.1 -p 2222 Last login: Fri May 26 07:27:30 2017 from 10.0.2.2 [root@sandbox ~]# hdfs Usage: hdfs [--config confdir] [--loglevel loglevel] COMMAND where COMMAND is one of: dfs run a filesystem command on the file systems supported in Hadoop. classpath prints the classpath namenode -format format the DFS filesystem
.
Port 2222 is must to be used.
https://hortonworks.com/hadoop-tutorial/learning-the-ropes-of-the-hortonworks-sandbox/
Created 05-26-2017 07:26 PM
FYI ... you can learn more basic tips of working with the HDP Sandbox with this tutorial:
https://hortonworks.com/hadoop-tutorial/learning-the-ropes-of-the-hortonworks-sandbox/
Created 05-26-2017 07:15 AM
You have installed the sandbox on windows 10 machine. Its not like that you have installed Hadoop onto your system. thats why whenever you want execute hadoop commands you will need to SSH from putty itself and then you can execute the hadoop command into that shell.
Created 05-26-2017 07:20 AM
Yes I know. However it seems logical that hadoop commands should run on virtual machine itself because I am using ssh to connect with it. isn't it?
Created 05-28-2017 03:37 AM
@Sadegh, even you can try to SSH as localhost Ex: ssh root@localhost -p 2222