I want to upload a file to remote server through ftp
daily.Can anyone suggest how to make a shell script for
that.I hv credentials for that ftp
Answer Posted / geichel
#!/bin/bash
/bin/ftp -inv ip_address_of_target_station<<ENDFTP
user ftpusername ftpuserpassword
cd folder_on_target
bin
lcd folder_on_local
put filename.txt
bye
ENDFTP
# Alternatively some ftp packages let you put a script in
$HOME/.netrc
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is the fastest scripting language?
What is the use of "$#" in shell scripting?
Is shell script a programming language?
What is shift command in shell script?
How do scripts work?
What is shell scripting?
What is a beat in a script?
What can you do with powershell?
Is bash an operating system?
Write a shell script that adds two numbers if provided as the command line argument and if the two numbers are not entered throws an error message.
How to debug the problems encountered in the shell script/program?
Why are shell scripts used?
Explain about return code?
What is inside a seashell?
What does it mean by #!/Bin/sh or #!/Bin/bash at the beginning of every script?