Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

Print a given number, in reverse order using a shell script such that the input is provided using command line argument only.

1156


What are the different types of commonly used shells on a typical linux system?

1095


What is shell company all about?

982


c program to implement unix/linux command to block the signal ctrl-c and ctrl-\ signal during the execution ls -l|wc -l

3764


What does .sh file contain?

959


What are script files?

1036


What is batch file programming?

1161


What is the first line of a shell script called?

1089


What is bash eval?

1014


How to print all the arguments provided to the script?

962


write a shell script to emulate the Id command of PRIMOS which lists files and directories. It list files first with a header FILES and then directories with a header DIRECTORIES. This command has several options. The main ones are. -file select files only -dir select directories only -reverse sort in reverse order -no_header put no header on the output -brief output the header only -size display the size of each file -help display Id´s syntax and options.

2782


What is in a script?

1020


Suppose you execute a command using exec, what will be the status of your current process in the shell?

1073


How to get the last line from a file using just the terminal?

1232


What are the different variables present in linux shell?

1107