- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
SSH login issue
- Labels:
-
Apache Ambari
-
Apache Hadoop
-
Cloudera Hue
Created on ‎12-22-2015 04:15 PM - edited ‎09-16-2022 02:54 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am running the sandbox on Azure. I am able to login to Ambari, hue and 8080 page. However, the SSH using putty or using web version at port 4200, does not accept any credentials.
Tried root/hadoop Also the user name and password set for this vm at azure. Getting Access denied message. Thoughts? How do reset root password if it helps?
Created ‎12-31-2015 02:32 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks to everyone for the suggestions. I wanted to give an update as I am able to connect to the prompt, hopefully will help others who have similar environments similar to mine.
My challenge was to get the SSH working from Windows 10 (Surface Pro) where the VM was created in Azure (classic)
General guidelines https://azure.microsoft.com/en-us/documentation/articles/virtual-machines-windows-use-ssh-key/
- Installed GitHub with GitShell.
- Ran the command from GitShell to generate the key file and .pem file (openssl.exe req -x509 -nodes -days 365 -newkey rsa:2048 -keyout myPrivateKey.key -out myCert.pem)
- Installed PuttyGen
- Convert to .rsa file so PuttyGen can understand (openssl rsa -in ./myPrivateKey.key -out myPrivateKey_rsa# chmod 600 ./myPrivateKey_rsa)
- Load the private key via PuttyGen, save the PrivateKey as .ppk file
- Next copy the PublicKey from PuttyGen.
Now, I attempted to take the key to existing Azure VM, Settings, Reset Password and change to SSH Public Key. Although, the key was accepted, it did not finish for a long time. The restart did not help. Kept getting Server key was refused.
- So, I created a new VM using Marketplace Sandbox using Resource Manager (not classic) using the Public Key. Note down the user name!
- Ran Putty, provided the IP address using port 22, on SSH -> Auth page, provided the .ppk file saved earlier from PuttyGen.
- When prompted, provide the username used in Azure portal. Voila!
Created ‎12-22-2015 04:44 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
https://hortonworks.com/hadoop-tutorial/deploying-...
NOTE: Make sure to write down your username and password. If using ssh public key, ensure you have the corresponding private key. Without it, you won’t be able to access the terminal of the machine.
Created ‎12-22-2015 07:55 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@ergo al2011 http://docs.hortonworks.com/HDPDocuments/Ambari-2.2.0.0/bk_Installing_HDP_AMB/content/_set_up_passwo...
The above link can help to create keys
Created ‎12-22-2015 05:04 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Log on as root on your sandbox and follow the below procedure
Just press "Enter" when prompted for a passphrase.
[root@hadoop01 ~]# ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):
/root/.ssh/id_rsa already exists. Overwrite (y/n)? y
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.
The key fingerprint is: 6f:40:61:c1:89:a5:f0:f4:8d:6b:01:98:fc:01:fb:d4 root@hadoop01
The key's randomart image is:
Two files will be created in the folder /root/.ssh [
root@hadoop01 ~]# cd /root/.ssh id_rsa id_rsa.pub
Copy the contents of id_rsa.pub to authorized_keys and copy this files to your desktop
Execute the below commands
[hdp@hadoop01 .ssh]$ cat id_rsa.pub >> authorized_keys
copy this authorized_keys to your local desktop/laptop c:\drive or wherever.
Then on your putty under connection>>Ssh>>auth browse and locate the downloaded authoriszed_keys on your computer and import it into putty remember to chose the good algorithm either ssh-1 or ssh-2 RSA
Now you can log on without any issues.
Please let me know if you are succesfully and accept the answer
Created ‎12-22-2015 07:47 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@ergo al2011 Did you import the generated id_rsa.pub that you copied to authorized_keys? Can you tell me precisely where you failed what step?
Created ‎12-23-2015 03:41 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My problem is that I am running Windows and I cannot connect to terminal mode of the sandbox to run any commands recommended here. I think I have to generate the keys and plug it in Azure, which I assume copies to authorized keys. Still on this step.
Created ‎12-22-2015 05:37 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@
I cannot successfully login as root. The enter does not give me a prompt to enter commands. Sample below.
login as: root
root@xxxxx. cloudapp . net 's password:
Access denied
root@xxxxx . cloudapp . net's password:
Are there specific settings in Putty? I am using machinename.cloudapp.net with port 22, which is same as SSH port in the endpoint at azure. OS on my side is W10.
Created ‎12-22-2015 06:50 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You likely need a keypair file to be passed.
ssh -i <keypair> root@xxxxx.cloudapp.net
Created ‎12-29-2015 02:32 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Created ‎12-29-2015 02:32 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
