- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- ssh passwordless login
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-26-2012 01:20 AM
07-26-2012 01:20 AM
ssh passwordless login
Hi
I am successful in generating ssh keys for some servers and I am able to login without password.
but for some servers,i am getting the below error message
ssh wiz001
ssh: Could not resolve hostname wiz001: host nor service provided, or not known
what could be the problem.How can I solve it.
regards
Deepan
- Tags:
- ssh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-26-2012 06:18 AM
07-26-2012 06:18 AM
Re: ssh passwordless login
Can you do something like:
# nslookup wiz001
or
# nsquery wiz001
And does it return the hosts IP address. If it does not, then that host is either not in DNS or not in the /etc/hosts file of your server.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-26-2012 06:27 PM
07-26-2012 06:27 PM
Re: ssh passwordless login
Hi
I checked with nslookup and it does not return any output.
but I tried to create a hosts file in my home directory adding ipaddress and hosts name
cat hosts
wiz001 ipaddress
but eventhough its not working.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-27-2012 02:25 AM
07-27-2012 02:25 AM
Re: ssh passwordless login
> I checked with nslookup and it does not return any output
Did you actually type the "#" sign in Patrick's suggestion? It was supposed to be the command prompt of the root user, suggesting that you should run the nslookup command as root.
When you type the "#" sign, it means that the shell should completely ignore the line past the "#" sign. It is used in shell scripts to write descriptive comments.
When properly used, the nslookup command should always produce some output.
> ...I tried to create a hosts file in my home directory...
Why would the system look for a hosts file in your home directory? The only standard location for a hosts file is /etc/hosts. As far as I know, there is no way to tell HP-UX to read a hosts file from a non-default location.
And your syntax is wrong for a hosts file: the IP address must be first, then the primary hostname, then alias names (if there are any).
If you are not allowed to write to /etc/hosts, you can use the SSH configuration file for the same purpose.
There should be a directory named .ssh in your home directory. Create a file named "config" in it. It should have two lines in it:
Host wiz001 HostName ipaddress
This tells the ssh command (only the ssh command and its friends scp and sftp, and only on your user account) that when you type "ssh wiz001", you actually mean "ssh ipaddress".
If you often have to use long and complex hostnames or IP addresses with ssh commands, this can be an useful way to create short names that are easier to type.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-27-2012 03:05 AM
07-27-2012 03:05 AM
Re: ssh passwordless login
OR you may do ssh to IP address instead of hostname.
Regards,
Chirag Parikh.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-30-2012 04:49 PM
07-30-2012 04:49 PM
Re: ssh passwordless login
A better solution would be to ask your DNS administrator to set up the appropriate entries in the DNS.