DbAppWeb.com

Menu
  • Home
  • Linux
  • HP-UX
  • macOS
  • Windows
  • Web Servers
  • App Servers
  • Storage

HP-UX SSH Login Without Password

August 30, 2020 DbAppWeb Admin

There are two types of authentications that are being used in UNIX systems for SSH connections. The first one is in password-based authentication and the second one is in public key-based authentication. In public key-based authentication, we used a key pair for SSH convection and there is no password required in this method.

HP-UX SSH Login Without Password

Here I have two servers server1 and server2 and I am going to set up passwordless authentication between these two.

  • Create the key pair on the first server i.e. server1, it will create /home/dbappwb/.ssh/id_rsa as a private key and /home/dbappwb/.ssh/id_rsa.pub as a public key. These keys will be created inside your home directory in the .ssh directory.
    $ ssh-keygen -t rsa
    Generating public/private rsa key pair.
    Please be patient....   Key generation may take a few minutes
    Enter file in which to save the key (/home/dbappwb/.ssh/id_rsa):
    Created directory '/home/dbappwb/.ssh'.
    Enter passphrase (empty for no passphrase):
    Enter same passphrase again:
    Your identification has been saved in /home/dbappwb/.ssh/id_rsa.
    Your public key has been saved in /home/dbappwb/.ssh/id_rsa.pub.
    The key fingerprint is:
    3f:87:a5:ff:7d:18:ed:28:ef:97:ce:36:31:9e:e1:fd dbappwb@server1
    The key's randomart image is:
    +--[ RSA 2048]----+
    |                 |
    |                 |
    |                 |
    |                 |
    |        S   .  . |
    |         . +  .+.|
    |          = . o=B|
    |           +. +O=|
    |            .=*+E|
    +-----------------+
    $
  • If the .ssh directory is not available on server2 then you have to create the same before copying the public key.
    $ ssh dbappwb@server2 mkdir -p .ssh
    The authenticity of host 'server2 (server2)' can't be established.
    ECDSA key fingerprint is 47:d3:6a:74:3f:32:f4:bb:38:e1:0b:f0:77:3d:44:0b.
    Are you sure you want to continue connecting (yes/no)? yes
    Warning: Permanently added 'server2' (ECDSA) to the list of known hosts.
    Password:
    $
  • Install the public key in server2, using the command shown below.
    $ cat $HOME/.ssh/id_rsa.pub | ssh dbappwb@server2 'cat >> $HOME/.ssh/authorized_keys'
    Password:
  • Now you may connect to server2 from server1 through SSH and it will not ask for any password.
    $ ssh dbappweb@server2
    $

Last Updated: August 30, 2020

Related Posts

  • SSH login taking too much time on HP-UX 11.31
  • SSH login taking too much time on HP-UX 11.31
  • How to Disable Root SSH Login in HP-UX?
  • Protect SSH Logins with SSH & MOTD Banner Messages in HP-UX

Share this:

  • Click to share on Twitter (Opens in new window)
  • Click to share on Facebook (Opens in new window)
  • Click to share on LinkedIn (Opens in new window)
  • Click to share on Telegram (Opens in new window)
  • Click to share on WhatsApp (Opens in new window)
Prev Article
Next Article
Tags:HP-UX SSH Sys Admin System Security

Leave a Reply Cancel Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

  • Popular
  • Recent

Categories

  • Android (2)
  • Blogger (16)
  • Domain and Hosting (1)
  • Hardware Issues (7)
  • HP-UX (55)
  • HPE Data Protector (9)
  • IBM Lotus Notes (2)
  • IBM WebSphere Application Server (16)
  • Internet Tips & Tricks (15)
  • iOS (8)
  • JBoss/WildFly Application Server (2)
  • Linux (76)
  • macOS (15)
  • Microsoft Windows (31)
  • News and Updates (11)
  • Oracle Database (5)
  • SSL/TLS (1)
  • Storage Servers (23)
  • Tools/Softwares (1)
  • VMware ESXi (17)
  • Web Servers (14)
  • WordPress (5)

Archives

DbAppWeb.com

Solution of Database, Application and Web Server Problems

About DbAppWeb.com

One Stop Solution for Database Server, Application Server and Web Server Problems.

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

DbAppWeb on Social Media

Copyright © 2025 DbAppWeb.com
Terms and Conditions   Theme by MyThemeShop.com