# ftp transfer my $ftp = Net::FTP->new ($server, Timeout => 9000, Debug => 3); $ftp or die "$server: cannot connect: $@"; # If you don't use ~/.netrc $ftp->login ($user,$passwd) or die "$_: Could not login: " . $ftp->message; # change remote directory my ($f1, $f2, $ftp_upload_location) = @$f; $ren[0]->[2] = "/DE/IN"; $ren[1]->[2] = "/DE/OUT"; $ftp->cwd ($ftp_upload_location);