use Net::FTP; $ftp = Net::FTP->new("SERVER_NAME", Debug => 0) or die "Cannot connect to the server: $@"; $ftp->login("anonymous",'-anonymous@') or die "Cannot login ", $ftp->message; print "Succesfully connencted to the server...\n"; $ftp->cwd("/downloads/pub") or die "Cannot change working directory ", $ftp->message; $ftp->get("*.txt") or die "get failed ", $ftp->message; $ftp->quit;