HI Vern

Thanks for the reply.
Sorry, it looks like I pasted the wrong command. This command is working
fine in FTP but same failed in SFTP.

put /QSYS.lib/EVENTS.lib/ASGTRESP.file/M000028373.mbr
/QSYS.LIB/EVENTS.LIB/RA02600001.FILE/RA02600001.MBR

Note: This RA02600001 is not available yet on the remote server. In FTP,
RA02600001 this file is automatically created and member RA02600001
is automatically added with a single FTP PUT command.

Thanks
Manoj




On Sun, Mar 2, 2025 at 12:56 AM Vern Hamberg via MIDRANGE-L <
midrange-l@xxxxxxxxxxxxxxxxxx> wrote:

Hi Manoj

I'm actually surprised that this works in regular FTP - you are
specifiying 2 levels of members, and there is only 1 - a member is not a
directory, so the error is reporting correctly. To say it another way,
there are no members inside members, members are inside files.

I suggest removing /*.MBR from both.
--

*Regards*

*Vern Hamberg*

IBM Champion 2025 <cid:part1.H9ddGZX3.7a8T03Cd@centurylink.net> CAAC
(COMMON Americas Advisory Council) IBM Influencer 2023

On 3/1/2025 11:43 AM, manoj kumar wrote:
Hi

We have an existing process that will use FTP script to upload the
iSeries
physical file in QSYS.LIB/XXXX.LIB to the remote server. Now we are
planning to change the existing process to use SFTP.

We are using QOpensys and using the PUT command to upload the physical
file. But my concern is, the following command fails when the physical
file
not already available on the remote server when i was using SFTP. The
same
command works fine when i run this on FTP protocol.

put /QSYS.lib/EVENTS.lib/ASGTRESP.file/M000028373.mbr/*.MBR
/QSYS.LIB/EVENTS.LIB/RA02600001.FILE/RA02600001.MBR/*.MBR

Error: open("/QSYS.LIB/EVENTS.LIB/RA02600001.FILE/RA02600001.MBR"): No
such file or directory".

There is no issue with the above command when the destination file is
already available at the remote location.


how can i use PUT command, so that it can create the file automatically
when it's not already at remote location?

why is the same command creating the file successfully at the remote
location if i use FTP instead of SFTP? why its fail in SFTP?

Please help me.

Regards
Manoj




--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related
questions.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2025 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.