FTP 자동 다운로드 Shell 스트립트

#!/bin/bash
#[ 오늘 날짜 얻기 20080529]
TODAY=`date +%Y%m%d`

TARGET_IP=116.127.120.133
USER_ID=xxxx
USER_PASS=xxxxx
TARGET_FILE=$TODAY".log"
TARGET_DIR=/log

# [Download 받을 파일명 확인 ]
echo $TARGET_FILE" Download!"
cd ./

#[ Ftp 연결하기 ]
ftp -n $TARGET_IP << EOF
user $USER_ID $USER_PASS
binary
hash
cd $TARGET_DIR
cd ./
get $TARGET_FILE
bye
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2008/07/24 11:13 2008/07/24 11:13
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/3482

Trackback URL : http://tcbs17.cafe24.com/tc/trackback/3482

« Previous : 1 : ... 4 : 5 : 6 : 7 : 8 : 9 : 10 : 11 : 12 : ... 213 : Next »

블로그 이미지

- 홍반장

Archives

Recent Comments

  1. 1 pHqghUme 01/05
  2. 1 pHqghUme 01/05
  3. 1 pHqghUme 01/05
  4. 1 pHqghUme 01/05
  5. 1 pHqghUme 01/05

Calendar

«   2025/03   »
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31          
Statistics Graph

Site Stats

Total hits:
274577
Today:
59
Yesterday:
274