Is their Automatic command to send a JPG file using FTP
freebsd at edvax.de
Thu Jan 28 19:10:24 UTC 2010
On Thu, 28 Jan 2010 10:21:32 -0800, "Dixit, Viraj" <Viraj.Dixit at CityofPaloAlto.org> wrote:
> Thanks so much. One question, I created a .netrc file and put it in the
> root (/root) directory and this is what it looks like below. I have
> taken out the IP, user name & password so no body can use them.
Do you regularly work as root? :-)
> Can you
> tell me if my syntax is correct [...]
Check "man ftp", there's a whole section "THE .netrc FILE".
I know that the ability to rely on manpage information isn't
very common in Linux land due to missing documentation
> [...] and how do I activate this file and is
> this file in the right place on the server.
The syntax is "ftp -N <file>". The default is ~/-netrc.
> machine 172.16.0.38
> macdef init
> lcd /ftp
> cd /var/temp
> get newemp.db
That looks okay to me. You can process it with "ftp -v"
to check verbose output for any strange things, should they
In order to avoid interaction (especially when working
with more than one file), you could add "prompt" to supress
any manual input.
By the way, FreeBSD's ftp program accepts stdin input,
printf "prompt\nmdelete *\nbye\n" | \
This is what I call "make deinstall" for web pages. :-)
This means that you could do the same as with .netrc.
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
More information about the freebsd-questions