Sponsored Content
Top Forums UNIX for Beginners Questions & Answers FTP from Widows to UNIX system - how to? ( was To not to duplicate) Post 302965062 by jgt on Friday 22nd of January 2016 08:58:50 PM
Old 01-22-2016
Either way;
Code:
ftp host >filelist
user
password
cd 'filepath'
ls
quit

You should now have a list of all the files on the source system, in the local file filelist.
You should now examine filelist to decide which file(s) you want to move and write them to a new file looking something like
Code:
cd pathtofile
get DAILYFEED_20160121.txt
quit

then re-connect
Code:
ftp host <new_file

If you are running the ftp client on the unix system, then you can create a .netrc file in the home directory of the user running these scripts so that you do not need to enter the user and password.
Sample script to select files:
Code:
count=0
echo "cd pathtofiles"
while read filename
do
    if [ $filename = "some criteria" ]
    then
     echo get (or maybe put) $filename
     count=`expr $count + 1`
     fi
done <filelist
echo "quit"
if [ $count -eq 0 ]
   then
   exit 1 
   #no files selected
else
    exit 0
fi

 

10 More Discussions You Might Find Interesting

1. Programming

Need help about realizing an ftp-like system.

Hi people! As you can read in the subject, I have a project at the University that requires me to realize a ftp-like through the sockets, in C. This is what I've been told so far, and since I'm studying Unix now for the first time I have little idea of where to start. Does anybody know of a... (1 Reply)
Discussion started by: OpSys
1 Replies

2. Solaris

Secure FTP Problem using Sun SSH on Client system F-Secure on Server system

I am using shell script to do secure ftp. I have done key file setup to do password less authentication. Following are the FTP Details: FTP Client has Sun SSH. FTP Server has F-Secure. I am using SCP Command to do secure copy files. When I am doing this, I am getting the foll error scp:... (2 Replies)
Discussion started by: ftpguy
2 Replies

3. Shell Programming and Scripting

FTP script to FTP file to UNIX - Solaris

Hello, A couple of times per week, i receive emails notifications when files are available for processing. Currently i read these eamails with a java program and store the attachement on my C: drive and would now like to generate a PC script to send this file name up to UNIX-Solaris and... (3 Replies)
Discussion started by: bobk544
3 Replies

4. Filesystems, Disks and Memory

How to duplicate a drive in Unix?

I have a drive that I need to make a sector-by-sector or exact image copy of. In Windows, I use a program call Ghost by Symantec, but the version I have does not support Unix. Does anyone know of a good product for Unix? Thanks, Brett Gibson Gibson Teldata, Inc. (13 Replies)
Discussion started by: bgibson
13 Replies

5. UNIX for Advanced & Expert Users

MVS->Unix FTP : Using chmod as part of FTP.

We are transferring file from mainframes to unix, & in FTP process itself we would like to set access rights for unix machine. Has anyone used chmod command in association with site command in ftp? How it should be used? Thanks in advance. (1 Reply)
Discussion started by: videsh77
1 Replies

6. UNIX for Advanced & Expert Users

user is not able to FTP to system.

Helo, I have created one group called RBAC.(roll back access control) Now when I created user of RBAC its entry in /etc/passwd file is given below: roleadm:x:120:109:RBAC User:/home/pds_RBAC:/bin/false I have keep at the end /bin/false because I dont want to give direct login to the user... (2 Replies)
Discussion started by: amitpansuria
2 Replies

7. Windows & DOS: Issues & Discussions

script to change widows update permissions

I want to allow windows update when ordinary users are logged on, I'm pretty sure that adjusting the permissions registry entry HEY_LOCAL_MACHINE/SOFTWARE/Microsoft/Windows/CurrentVersion/WindowsUpdate to allow acces to all domins users does the trick. I already have a logon.bat that runs at... (0 Replies)
Discussion started by: barrydocks
0 Replies

8. UNIX for Dummies Questions & Answers

Duplicate column in unix file

Hello, I have a fixed width unix file with 2 columns containing the following data ZTXX_CTBR1-ZBRAN1 ZTXX_CTBR1-ZBRAN_DESC 01 CASH & CARRY 02 DRUGSTORE - RX 04 ... (4 Replies)
Discussion started by: chumsky
4 Replies

9. UNIX for Dummies Questions & Answers

Unix System Programmer Vs. Unix System Administrator

Hi friends, I hope you are all fine and doing well. First of all, let me say that I love Unix with passion. But I have one query in my mind that is bothering me. What should I do, Unix System Administration or Unix System Programmering. Could you please tell me the difference between the two. And... (3 Replies)
Discussion started by: gabam
3 Replies

10. UNIX for Beginners Questions & Answers

Migrating jobs from COBOL Mainframe system to UNIX system

In a nutshell requirement is to migrate the system from mainframe environment to UNIX environment (MF cobol would be used I guess). I have not much of idea in this field. I need to do some investigation on following points - - Ease of conversion - Known Data compatibility issue - Issue in... (9 Replies)
Discussion started by: Tjsureboy4me
9 Replies
Select(3)						User Contributed Perl Documentation						 Select(3)

NAME
podselect - function to extract selected sections of pod documentation SYNOPSIS
use PDL::Pod::Select; podselect (@filelist); podselect ({OUTPUT => "tmp.out"}, @filelist): podselect ({SELECT => ["NAME|SYNOPSIS", "OPTIONS"]}, @filelist): podselect ({OUTPUT => ">&STDERR", SELECT => ["DESCRIPTION"]}, "-"); DESCRIPTION
podselect() is a function which will extract specified sections of pod documentation from an input stream. This ability is already provided in the PDL::Pod::Parser module. Subclasses of PDL::Pod::Parser that wish to take advantage of this feature do not need to derive from PDL::Pod::Select. PDL::Pod::Select merely provides a single function named podselect() which provides this capability in function form (as opposed to object form) for extracting the raw pod docs. podselect(\%options, @filelist) podselect will print the raw (untranslated) pod documentation of all pod sections in the given input files specified by @filelist according to the given options. If any argument to podselect is a reference to a hash (associative array) then the values with the following keys are processed as follows: "OUTPUT" A string corresponding to the desired output file (or ">&STDOUT" or ">&STDERR"). The default is to use standard output. "SELECT" A reference to an array of sections specifications (as described in "SECTION SPECIFICATIONS" in PDL::Pod::Parser) which indicate the desired set of pod sections and subsections to be selected from input. If no section specifications are given, then all sections of pod documentation are used. All other arguments should correspond to the names of input files containing pod documentation. A file name of "-" or "<&STDIN" will be interpeted to mean standard input (which is the default if no filenames are given). SEE ALSO
PDL::Pod::Parser AUTHOR
Brad Appleton <Brad_Appleton-GBDA001@email.mot.com> Based on code for pod2text written by Tom Christiansen <tchrist@mox.perl.com> perl v5.8.0 1999-12-09 Select(3)
All times are GMT -4. The time now is 09:08 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy