I'm trying to FTP a file in ASCII mode over to a mainframe, which I can accomplish manually from my workstation. The response that I'm not logged in is very strange since the connection is successfully made, and the quit is successfully received. Bug?

Take a look, and please offer any suggestions you can. Not really sure why its sending a STOR when I told it to do a PUT.....

Code:

if (!($sftp = Net::FTP ->new("main.frame.address", Debug => 1))) { print "Can't connect to mainframe: $@\n"; exit(1); } $sftp -> ascii; if (!($sftp -> put<BR>("/some/path/defined/READY","LOGIN.FILE.PATH.RE +ADY"))) { $sftp -> quit; print "Couldn't put ready file onto mainframe:$@\n"; exit(3); } if (!($sftp ->quit)) { print "Failed to logout\n"; exit(4); } Debug Response: Net::FTP: Net::FTP(2.61) Net::FTP: Exporter(5.562) Net::FTP: Net::Cmd(2.20) Net::FTP: IO::Socket::INET(1.25) Net::FTP: IO::Socket(1.26) Net::FTP: IO::Handle(1.21) Net::FTP=GLOB(0x400389e4) 220-FTPD1 IBM FTP CS V2R6 at main.frame.addr +ess, 10:40:44 on 2001-12-05. Net::FTP=GLOB(0x400389e4) 220 Connection will close if idle for more t +han 5 minutes. Net::FTP=GLOB(0x400389e4) TYPE A Net::FTP=GLOB(0x400389e4) 200 Representation type is Ascii NonPrint Net::FTP=GLOB(0x400389e4) PORT 128,210,99,99,999,999 Net::FTP=GLOB(0x400389e4) 200 Port request OK. Net::FTP=GLOB(0x400389e4) STOR LOGIN.FILE.PATH.READY Net::FTP=GLOB(0x400389e4) 530 Not logged in. Net::FTP=GLOB(0x400389e4) QUI Net::FTP=GLOB(0x400389e4) 221 Quit command received. Goodbye. Couldn't put bursar ready file onto mainframe:
jcwren, 2001/12/05: <code>s tags added

In reply to Net::FTP to MVS problems with put by Anonymous Monk

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.