Hi guys,
Good day! Anyone there could suggest on how can I create a program that will get (ftp) the logs I need from a remote Server (running in Linux) into my Desktop (running in Windows 7). For Perl program suggestions, FYI that I'm using Active Perl version. The reason why I need this one is that I want to run the program that has been created not on the remote server but in the Desktop itself so not to affect the remote Server.
I've tried these simple codes below:
#!usr/bin/perl
$connect = "ftp <IP>";
system ($connect);
$user = <STDIN>;
chomp $user;
$pass = <STDIN>;
chomp $pass;
if ($user eq /<correct user>/ && $pass eq /<correct pass>/)
{
$logs_dir = "cd <dir>/";
system ($logs_dir);
}
it only works for the FTP part and just like an ordinary FTP command it did not save the input user and pass into the variables and nothing else happens.
Please help!
Br,
rymnd_12345