|
Multiple things.
1 - Judging from the output the remote machine is also running IBM i.
Therefore
STOP USING LOCSITE! Use just namefmt 1
2 - Put a blank line as the first line of your script. Like this:
*************** Beginning of data *
0001.00
0002.00 open delivery01-bld.dhe.ibm.com
0003.00 user "anonymous" ROB@xxxxxxxxx
0004.00 locsite namefmt 1
0005.00 lcd /fixes/cume
0006.00 ascii
0007.00 cd /ccss/lv1/22189/CUME/C
0008.00 get ftpCUME.txt
0009.00 get ilstCUME.txt
0010.00 binary
0011.00 mget CUME_*.bin
0012.00 quit
****************** End of data ****
Yes, I did use locsite on mine. The difference is that my remote is not
an IBM i but instead is some mainframe IBM uses as their ftp site.
Rob Berendt
--
IBM Certified System Administrator - IBM i 6.1
Group Dekko
Dept 1600
Mail to: 2505 Dekko Drive
Garrett, IN 46738
Ship to: Dock 108
6928N 400E
Kendallville, IN 46755
http://www.dekko.com
From: Jeff Young <jyoung0950@xxxxxxxxx>
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>
Date: 07/15/2014 10:57 AM
Subject: Re: Using FTP to transmit a file in the IFS
Sent by: "MIDRANGE-L" <midrange-l-bounces@xxxxxxxxxxxx>
I am now having another issue with FTP.
I have an FTP Script file with the following commands:
close
open MUSSONJAMAICA.COM
USER xxx yyyy
ascii
locsite namefmt 1
cd /ffff/vvvv
put '/zzzz/gg/inbox/14072014 Creation Report.txs'
close
quit
Prior to issuing the FTP command, I issue an OVRDBF command to file INPUT
AND OUTPUT
INTPUT DB TOFILE(QTEMP/STVFTINST) MBR(STV150714)
OUTPUT DB TOFILE(T37MODSDTA/STVFTPLOG) MBR(STV150714)
When I issue the FTP Command, I get what appears to be a "terminal window"
This is a mostly blank screen with the text Press ENTER to end terminal
session. near the top and the following command keys on the bottom:
F3=Exit F4=End of File F6=Print F9=Retrieve F17=Top
F18=Bottom F19=Left F20=Right F21=User Window
The screen appears to have a command line above the command keys, but
ignores anything I key.
If I press F3 and then Enter, my job ends.
Below is the output from the FTP Log file:
Output redirected to a file.
Connecting to host S105RHXM at address nn.nn.nn.nnn using port 21.
220-QTCP at Sxxxxxxxx.
220 Connection will close if idle more than 5 minutes.
Enter login ID (vai):
331 Enter password.
OS/400 is the remote operating system. The TCP/IP version is "V6R1M0".
250 Now using naming format "0".
Enter an FTP subcommand.
Enter an FTP subcommand.
Enter an FTP subcommand.
What am I missing here?
Jeff Young
Sr. Programmer Analyst
On Tue, Jul 15, 2014 at 10:34 AM, CRPence <CRPbottle@xxxxxxxxx> wrote:
On 15-Jul-2014 08:47 -0500, Jeff Young wrote:Having
On 15-Jul-2014 08:14 -0500, Jeff Young wrote:
I managed to solve the initial issue with the database extension,
but now have another problem.
The file that I am attempting to send has embedded blanks in the
name, and is a long name - 15012014 Creation Report.txt
I have tried to place quotes around it, but it still can not find
the file. When I change the name to use the _ character instead of
blank, I receive an error 5012014_Creation not found. Is there a
limit on the size of the file name in the PUT sub command?
I managed to solve the problem.
It appears that even though I used the locsite namefmt 1 command and
set the local directory using the lcd command, the put command needs
the full path name with the file or I get errors.
Specifying the path name is optional, if the named file is in the
Current Directory that has been established within the FTP session.
correctly placed "quotes around" the name with embedded blanks, the PUThaving
should function as expected.
Once I used the full path name, and surrounded the file name with
single quotes, it worked fine. <<SNIP>>
After LCD FTP subcommand is used to establish a pathname outside the
default in /QSYS.LIB, the PUT should locate the named file within that
newly establisehd Current Directory [outside of /QSYS.LIB]. Simply
delimited the file name with either double-quote or apostrophecharacters,
just as was noted to be successful when fully qualified with thepathname.
There should be no reason to specify the path redundantly; if an errora
persists, either something was still incorrect in the setup, or there is
defect. The following script should successfully PUT the data from athe
client localfile name that includes embedded blanks] from within the
current directory [of the FTP session], into a file named tofilename at
server:list
LOCSITE NAMEFMT 1
LCD /myChosenDirectoryPath
PUT "15012014 Creation Report.txt" tofilename
--
Regards, Chuck
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
To post a message email: MIDRANGE-L@xxxxxxxxxxxx--
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.