HN-Community
shell script untuk FTP - Printable Version

+- HN-Community (https://hacker-newbie.org)
+-- Forum: Miscellaneous (https://hacker-newbie.org/forum-86.html)
+--- Forum: Operating System (https://hacker-newbie.org/forum-13.html)
+---- Forum: GNU/Linux (https://hacker-newbie.org/forum-15.html)
+---- Thread: shell script untuk FTP (/thread-1183.html)



shell script untuk FTP - akatsuchi - 12-02-2009

Kadangkala kita membutuhkan untuk upload secara automatis menggunakan FTP. Shell Script berikut akan membantu,

Edit Script
Code:
# vi myftp.sh

isinya
Code:
#! /bin/sh REMOTE='namamesin' USER='namauser' PASSWORD='passworduser' FTPLOG='/tmp/ftplog' date >> $FTPLOG

Code:
ftp -n $REMOTE <<_FTP>>$FTPLOG quote USER $USER quote PASS $PASSWORD bin cd /myraid/dailyjpgs mput *.jpg quit _FTP

Jalankan di shell dan di background process
Code:
# ./myftp.sh &

tambahkan di Contrab bila dibutuhkan
Code:
# crontab -e

thanks to : mbak arianom KILL-9 crew Ngakak


RE: shell script untuk FTP - ArRay - 12-03-2009

nah nah. sangar iki. tambah pinter dirimu kang. tak copas yo.


RE: shell script untuk FTP - akatsuchi - 12-03-2009

ããããããã....sapa dulu ketua genk nya Ngakak sopo yoh??