[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
mkdir failing in TESTMIRIN
The TESTMIRIN program statement below in the "do_dir" subprocedure is
failing.
callp mkdir(%trimr(LocalDir): 511)
This is causing the following statement "if
chdir(%trimr(LocalDir)) < 0" to fail and set the Diagnostic message in
the job log to "chdir(): No such path or directory."
So to try to identify the return error of the failed mkdir command, I
added the Diagnostic message logic to the mkdir command as shown below:
c** callp mkdir(%trimr(LocalDir): 511)
c if mkdir(%trimr(LocalDir): 511) < 0
c callp DiagMsg('mkdir(): ' +
c %str(strerror(errno)))
c return -1
c endif
Which generated the same message in the job log as shown below:
0: > CWD
0: 250 CWD command successful.
0: > TYPE A
0: 200 Type set to A.
0: > PORT 10,30,1,7,243,62
0: 200 PORT command successful.
0: > NLST
0: 150 Opening ASCII mode data connection for file list.
0: 226 Transfer complete.
mkdir(): No such path or directory.
Below is a debug display of variable LocalDir right before the mkdir
and chdir commands:
EVAL
LocalDir
LOCALDIR
=
....5...10...15...20...25...30...35...40...45...50...55...60
1 '/imports/ncr_aj1/incoming
'
61 '
'
121 '
'
181 '
'
241 '
'
301 '
'
361 '
'
421 '
'
481 '
'
541 '
'
601 '
'
Bottom
This is the WRKLNK command illustrating the path exists on the local
IBMi system up to the point of the directory path where the mkdir
command in do_dir is called to create the same directory found on the
FTP Server (the FTP Server directory to mirror).
Work with Object
Links
Directory . . . . :
/imports/ncr_ajl/incoming
Type options, press
Enter.
2=Edit 3=Copy 4=Remove 5=Display 7=Rename 8=Display
attributes
11=Change current directory
...
Opt Object link Type Attribute
Text
import.ajl
STMF
So obviously the path is there so I don't understand the "No such path
or directory." error. Can anyone shed some light on what I am doing
wrong or what the problem might be?
Best Regards,
Jerry L. Birch
-----------------------------------------------------------------------
This is the FTPAPI mailing list. To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------