Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

automating FTP on 1

Status
Not open for further replies.

rn4it

MIS
Nov 7, 2002
671
CA
I've got a basic ftp script to put a file onto a remote server. I've modified the .netrc file to the following:
machine <ip of ftp svr> user <username> password <password>

I get the following error msg.
[sunbox] : ./fwlog-ftp
./fwlog-ftp: s: not found
Error - .netrc file not correct mode.
Remove password or correct mode.

What does the correct mode mean?

thanks
 
Type the following...

[tt]chmod 700 .netrc[/tt]

Also, in the [tt].netrc[/tt] file it's "[tt]login[/tt]", not "[tt]user[/tt]". So it would be...

[tt]machine <ip of ftp svr> login <userid> password <password>[/tt]

Hope this helps.
 
Also, if [tt]fwlog-ftp[/tt] is a script, you've got some other syntax errors in it. The "[tt]./fwlog-ftp: s: not found[/tt]" means you've got a line where it thinks "[tt]s[/tt]" is a command. Probably due to a typo.
 
Thanks SamBones, I'll make the recommended changes and let you know home it works out.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top