steve@mullian.ee.mu.oz.au (Steve Mabbs) (07/14/90)
In article <3644@zorba.Tynan.COM> Chris Davies <uunet!relay.EU.net!vision!chris> writes: >In article <3587@zorba.Tynan.COM> jimli@milton.u.washington.edu (Jimmy Li) writes: >>Everytime I login on my school Unix machine, I need to ftp several files to >>my accounts on another machine. It gets pretty tedious typing in username, >>passwood, and so on over and over again. > >Why not use "rcp" (Remote CoPy)? If you've got ftp then you've probably got >this. You could also try rdist(1). Create a file called 'distfile' in your home directory that looks like: % cat distfile distfiles = (~/file1 ~/src/file2 ~/bin/file3.sh) (${distfiles}) -> chris@machine_b (${distfiles}) -> chris@machine_c % and just type 'rdist'. If rdist is present on the other machine, then this should work OK. As Jimmy says, you should also create a .rhosts file on machine_b and machine_c. Note: you can specify another distfile using the -f option (e.g. I use '.rdist' to keep it hidden). Then just put 'rdist -f .rdist' in your .login and it should all happen automatically. rdist has been designed to maintain identical copies of multiple files/dirs across many machines. See the manual page for more info. Regards, Steve --------------- Stephen A. Mabbs, Dept of Electrical and Electronic Engineering University of Melbourne Phone: office (room 3.10): +61 3 344 6714 PARKVILLE VIC 3052 vlsi lab (room 3.16): +61 3 344 7436 AUSTRALIA Fax: +61 3 344 6678 "Well, I never!". "Well, maybe that's your problem, lady".
pjs@socrates.Jpl.Nasa.Gov (Peter Scott) (07/14/90)
> In article <3587@zorba.Tynan.COM> jimli@milton.u.washington.edu (Jimmy Li) writes: > >Everytime I login on my school Unix machine, I need to ftp several files to > >my accounts on another machine. It gets pretty tedious typing in username, > >passwood, and so on over and over again. > > >So, my question is : Could anyone show me a C program (or a shell program?) > >that would take a filename as an argument and 'ftp' it to another machine > >automatically? > > Why not use "rcp" (Remote CoPy)? If you've got ftp then you've probably got > this. Didn't see the original posting but certainly would like to see a solution. We transfer software between many systems that aren't running Unix but do have ftp, and could use an automatic method of running ftp so we can insert it in delivery scripts. Say for the sake of argument that the request to receive or send a file(s) will be initiated on a Sun 3 system running SunOS 4.1. This is news. This is your | Peter Scott, NASA/JPL/Caltech brain on news. Any questions? | (pjs@aristotle.jpl.nasa.gov)