|
Rank: Starting Member
Groups: Registered
Joined: 2/2/2006 Posts: 1 Location: ,
|
Hi everybody,
I´m having problems with my perl script when I´m trying to download some files from an external HTTPS server:
My perl script is something like:
/********************************************/
my $ua = LWP::UserAgent->new;
$ua->timeout(20);
# $ua->env_proxy;
$nombrefichero = shift(@ARGV);
my @URLS = ('https://mydomain/' . $nombrefichero);
my $response = $ua->get($laurl);
/********************************************/
The fact is that when I run my script from the putty console (SSH), it downloads the file without problems getting next traces:
/********************************************/
LWP::UserAgent::request: ()
LWP::UserAgent::send_request: GET https://mydomain/myfile
LWP::UserAgent::_need_proxy: Not proxied
LWP::Protocol::http::request: ()
SSL_connect:before/connect initialization
SSL_connect:SSLv3 write client hello A
SSL_connect:SSLv3 read server hello A
SSL_connect:SSLv3 read server certificate A
SSL_connect:SSLv3 read server key exchange A
SSL_connect:SSLv3 read server done A
SSL_connect:SSLv3 write client key exchange A
SSL_connect:SSLv3 write change cipher spec A
SSL_connect:SSLv3 write finished A
SSL_connect:SSLv3 flush data
SSL_connect:SSLv3 read finished A
SSL_connect:SSL renegotiate ciphers
SSL_connect:SSLv3 write client hello A
SSL_connect:SSLv3 read server hello A
SSL_connect:SSLv3 read server certificate A
SSL_connect:SSLv3 read server key exchange A
SSL_connect:SSLv3 read server certificate request A
SSL_connect:SSLv3 read server done A
SSL_connect:SSLv3 write client certificate A
SSL_connect:SSLv3 write client key exchange A
SSL_connect:SSLv3 write certificate verify A
SSL_connect:SSLv3 write change cipher spec A
SSL_connect:SSLv3 write finished A
SSL_connect:SSLv3 flush data
SSL_connect:SSLv3 read finished A
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 4096 bytes
LWP::Protocol::collect: read 1000 bytes
LWP::UserAgent::request: Simple response: OK
/********************************************/
but if I try to schedule this process with the cron, to download same file, I get this error message:
/********************************************/
LWP::UserAgent::request: ()
LWP::UserAgent::send_request: GET https://mydomain/myfile
LWP::UserAgent::_need_proxy: Not proxied
LWP::Protocol::http::request: ()
LWP::UserAgent::request: Simple response: Internal Server Error
/********************************************/
Does anybody have any idea about this problem ? maybe the environment vars ??
Thanks a lot.
|