写一个ftp自动取文件的脚本


转载时请务必以超链接形式标明文章 原始出处和作者信息及本版权声明
链接:http://www.dbasky.net/archives/2009/03/ftp.html
写一个ftp取文件的脚本,记录一下,以后可以用,放在后台跑了就实现无人操作了。
vi ftp_get_file.sh

ftp -i -n 219.238.148.41<<FTPFILE > down.log
   user username password
   bin
   prompt off
   cd ora_hp
   mget p*_9206_HP64.zip
  bye
FTPFILE
授权并挂到后台执行:

#chmod 777 ftp_get_file.sh
#nohup ftp_get_file.sh &

发表评论

Close