Date: Mon, 02 Nov 1998 15:15:24 -0600 From: David Kelly <dkelly@hiwaay.net> To: Steven P Yang <spyang@MIT.EDU> Cc: freebsd-questions@FreeBSD.ORG Subject: Re: how do I automate ftp? (clarification) Message-ID: <199811022115.PAA10894@nospam.hiwaay.net> In-Reply-To: Message from Steven P Yang <spyang@MIT.EDU> of "Mon, 02 Nov 1998 14:17:21 EST." <199811021917.OAA13614@scrubbing-bubbles.mit.edu>
next in thread | previous in thread | raw e-mail | index | archive | help
Steven P Yang writes: > Hi, about my last e-mail, a specific goal I have in mind for an automated ftp > would be the ability to schedule a file transfer at a specific time to > a remote ftp server. So, this implies that the ftp script would automatically > supply the username and password. > I can do this on NT, but don't know if I can do this on FreeBSD. > > Is this possible? Not only possible, but falling-out-of-bed simple. See the man page for fetch(1). Basically "fetch ftp://user:password@host/file" will get you there from here. Fetch will also download web pages. That opens up all kinds of interesting things, such as download and archive of current stock prices, comic strips, etc. Also /usr/ports/net/ncftp3 could be used. The "advantage" of ncftp3 is that you can create a file of user names and passwords for ncftp3 to use automatically on a per site basis. The disadvantage is this file exists with passwords in the clear for somebody to dig for. Fetch may leave your password on the command line, visible with ps to other users on your host. ncftp3 should allow you to put files too. Once Upon A Time I would run nasty ftp jobs in batch. Type all your commands into a file then, "ftp < filename". A rotten way to do things if something hiccups. /usr/ports/lang/expect looks like it can provide the tools needed to be able to add error handling. -- David Kelly N4HHE, dkelly@nospam.hiwaay.net ===================================================================== The human mind ordinarily operates at only ten percent of its capacity -- the rest is overhead for the operating system. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199811022115.PAA10894>