- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: automating sftp
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
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
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
тАО12-22-2008 05:35 PM
тАО12-22-2008 05:35 PM
I need some help in automating sftp.
I have searched this forum and there are numerous threads on this topic but it pertains to OpenVMS.
I am running HP-UX 11.23.
I have tried putting the password in a batch file and executing sftp with '-b' option but it doesn't seem to work - it always prompts for password. =(
Does anyone know how to make it work?
Thanks in advance
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-22-2008 06:48 PM
тАО12-22-2008 06:48 PM
SolutionOn source server, generate public and private keys.
/usr/bin/ssh-keygen -t rsa
/usr/bin/ssh-agent $SHELL
/usr/bin/ssh-add
Just keep hitting return key.
On the Destnation Server
mkdir $HOME/.ssh
chmod 700 $HOME/.ssh
From Source Server to Dest
scp $HOME/.ssh/id_rsa.pub Dest_Server_IP:$HOME/.ssh/id_rsa.pub_Source_Server
On Dest Server
cat $HOME/.ssh/id_rsa.pub_Source_Server >> $HOME/.ssh/authorized_keys
You are done.
Cheers,
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-22-2008 07:12 PM
тАО12-22-2008 07:12 PM
Re: automating sftp
After following the above procedure, I just found that sftp hostname is not asking any password.
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-22-2008 07:56 PM
тАО12-22-2008 07:56 PM
Re: automating sftp
Have you arranged the key files for SSH
access without a password? (Why not?)
Normally, SSH, SCP, SFTP, Sxxx are used when
one does not wish to specify a password
interactively. (And there should be any
number of Forum threads related to setting up
SSH access without using a password, for
practically every OS.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-22-2008 08:52 PM
тАО12-22-2008 08:52 PM
Re: automating sftp
If you configure your server SSH without passwd it will automaticly configure for all S* like SSH, SCP, SFTP, so just configre the above things and do sftp without passwd.
Suraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-23-2008 04:51 PM
тАО12-23-2008 04:51 PM
Re: automating sftp
Thanks for all your replies.
With regards to setting SSH access without password, is it an "all or nothing" setting? In other words, is it a global setting in that once set without password, all access will be without password or can it be set such that some users will not be prompted while some will?
Regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-23-2008 05:08 PM
тАО12-23-2008 05:08 PM
Re: automating sftp
It can be done per host ("hostbased") or per
user ("publickey"). Find some appropriate
SSH documentation. As I suggested before, a
Forum search should lead to some. (I could
do it for you, but you'll learn more this
way.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-23-2008 05:21 PM
тАО12-23-2008 05:21 PM
Re: automating sftp
Each user can set it as he pleases. Assuming you mean from UserA to UserA on different machines.
You can also set it up so a user doesn't have to enter a passphrase at all (a generic account), to being required at least once.
There may be configuration settings that may disallow some of these?