| | |
Need SFTP script
Please support our Shell Scripting advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Aug 2009
Posts: 1
Reputation:
Solved Threads: 0
Hi All,
I am new in SFTP.
1)I need to transfer the file from one server to another server.
2) I have written .com file in my ALPHA VMS system with SQLquery.
3) Usually I send .com file through NDM protocol. In this file i write NDM script in the file for sending the file.
$!copy/log ie_acctinfo.dat MEDDEV::NDM_SEND:ie_acctinfo.dat
$!copy/log nl: MEDDEV::NDM_SEND:ie_acctinfo.dat_ack
this script we use inside the file. and then we can submit the file
@ie_acctinfo.com
--------------------------------
But this enhancement(project) I should use SFTP(SSH).
1) Both system(myside and other application(server)) side are generated and exchanged the public key.
2) now i need to the SFTP script inside the .com file and send(submit) SFTP script.
I really appriciate your help and spending time for me.
Thanks, prabha
I am new in SFTP.
1)I need to transfer the file from one server to another server.
2) I have written .com file in my ALPHA VMS system with SQLquery.
3) Usually I send .com file through NDM protocol. In this file i write NDM script in the file for sending the file.
$!copy/log ie_acctinfo.dat MEDDEV::NDM_SEND:ie_acctinfo.dat
$!copy/log nl: MEDDEV::NDM_SEND:ie_acctinfo.dat_ack
this script we use inside the file. and then we can submit the file
@ie_acctinfo.com
--------------------------------
But this enhancement(project) I should use SFTP(SSH).
1) Both system(myside and other application(server)) side are generated and exchanged the public key.
2) now i need to the SFTP script inside the .com file and send(submit) SFTP script.
I really appriciate your help and spending time for me.
Thanks, prabha
•
•
Join Date: Oct 2009
Posts: 1
Reputation:
Solved Threads: 0
0
#3 Oct 20th, 2009
Wow, that was a really profound and useful reply to a sincere question. Not the least bit presumptuous, rude or arrogant. Let me ask you this Salem: if Prabha didn't actually take the time to try things and read manuals and his question is just a waste of your time; why would you waste any time responding at all? Help someone or be silent; your sarcasm doesn't benefit anyone.
•
•
Join Date: Nov 2009
Posts: 1
Reputation:
Solved Threads: 0
0
#4 30 Days Ago
Jackmandu... applaud you sir!
Its crazy how people get off on being pretentious on message boards.... if he knew how to get the answer, the problem wouldn't have been posted.
Now to answer prabha24107
Place the private key in your $home/.ssh/
directory and call it $whatever.key
go into your .profile and create an alias
something like
alias -x $alias_name="sftp -oIdentityFile=$HOME/.ssh/$whatever.key username@xx.xx.xxx.xx"
however you choose to write your script, you can now call this alias and be able to sftp however you like. I hope this helps.
Salem is a real sit down guy...
Its crazy how people get off on being pretentious on message boards.... if he knew how to get the answer, the problem wouldn't have been posted.
Now to answer prabha24107
Place the private key in your $home/.ssh/
directory and call it $whatever.key
go into your .profile and create an alias
something like
alias -x $alias_name="sftp -oIdentityFile=$HOME/.ssh/$whatever.key username@xx.xx.xxx.xx"
however you choose to write your script, you can now call this alias and be able to sftp however you like. I hope this helps.
Salem is a real sit down guy...
![]() |
Similar Threads
- Running Automatic SFTP From Windows to Linux (Windows NT / 2000 / XP)
- Automating sftp (script) to copy files (Shell Scripting)
- correct my syntax in shell script (Shell Scripting)
- Help With Sftp In C++ (C++)
Other Threads in the Shell Scripting Forum
- Previous Thread: Problem printing date
- Next Thread: automation scripts--help needed urgent
| Thread Tools | Search this Thread |






