Hello Monks,

I am struggling with an FTP transfer which doesnt seem to respect the timeout value, tried both Passive 1 and Passive 0 modes

This is timing out even when i have specified 1200 s timeout. Thanks for your help.

use Net::FTP; my ($dropzone,$path,$l,$p,$filename)=@_; $ftpobj = Net::FTP -> new ($dropzone, Timeout => 1200, Debug => 1,Pas +sive => 0)or die "Cannot connect to $dropzone: $!"; $ftpobj -> login($l,$p)or die "Cannot login to ftp ", $ftpobj->messag +e; $ftpobj -> cwd ($path) or die "$!: No Such path $path"; $ftpobj ->binary; $ftpobj -> put ("$filename") or die "copy failed for $filename...$!\n +", $ftpobj->message; ..........
Command prompt log:
Net::FTP>>> Net::FTP(2.77) Net::FTP>>> Exporter(5.63) Net::FTP>>> Net::Cmd(2.29) Net::FTP>>> IO::Socket::INET(1.31) Net::FTP>>> IO::Socket(1.31) Net::FTP>>> IO::Handle(1.28) Net::FTP=GLOB(0x1db55b4)<<< 220 Microsoft FTP Service Net::FTP=GLOB(0x1db55b4)>>> USER Abc Net::FTP=GLOB(0x1db55b4)<<< 331 Password required for Abc. Net::FTP=GLOB(0x1db55b4)>>> PASS .... Net::FTP=GLOB(0x1db55b4)<<< 230 User Abc logged in. Net::FTP=GLOB(0x1db55b4)>>> CWD /directory1/directory3/Assets/director +y4 Net::FTP=GLOB(0x1db55b4)<<< 250 CWD command successful. Net::FTP=GLOB(0x1db55b4)>>> TYPE I Net::FTP=GLOB(0x1db55b4)<<< 200 Type set to I. Net::FTP=GLOB(0x1db55b4)>>> ALLO 296490288 Net::FTP=GLOB(0x1db55b4)<<< 200 ALLO command successful. Net::FTP=GLOB(0x1db55b4)>>> PORT 10,w,x,y,z,0 Net::FTP=GLOB(0x1db55b4)<<< 200 PORT command successful. Net::FTP=GLOB(0x1db55b4)>>> STOR 1-1112-1356-01_Test_Data_1-1112-1356T +X_V_800.tmp Net::FTP=GLOB(0x1db55b4)<<< 150 Opening BINARY mode data connection fo +r 1-1112-1356-01_Test_Data_1-1112-1356TX_V_800.tmp. Net::FTP=GLOB(0x1db55b4)>>> &#8215;ABOR Net::FTP=GLOB(0x1db55b4)<<< 426 Connection closed; transfer aborted. Net::FTP=GLOB(0x1db55b4)<<< 421 Timeout (120 seconds): closing control + connection. copy failed for Package/1-1112-1356-01_Test_Data_1-1112-1356TX_V_800.t +mp... Connection closed; transfer aborted. Timeout (120 seconds): closing control connection.

In reply to FTP transfer ABOR by prompt

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.