FTP stage for ftping file from Linux server to Mainframe
Moderators: chulett, rschirm, roy
FTP stage for ftping file from Linux server to Mainframe
My requirement is to ftp files from Linux server to Mainframe GDG's using the FTP enterprise stage.
Following is what I found in the documentation
The syntax for a relative path is:
ftp://host/path/filename
Where path is the relative path of the user's home directory.
The syntax for an absolute path is:
ftp://host//path/filename
While connecting to the mainframe system, the syntax for an absolute path is:
ftp://host/\'path.filename\'
The syntax for connecting to the mainframe system through USS (Unix System Services) is:
ftp://host//path/filename
Where path is the absolute path of the user's home directory.
I have tried all the above options for URI but still getting error message as follows. With different options the value of current directory changes but the error is still around "No such file or directory'.
Remote system type is POSIX (z/OS).
HFS directory `/u/grsds' is the current directory.
Error: EDC5129I No such file or directory., file: /u/grsds/N01.FILENAME
This is what I have in URI sftp://#HOST_SERVER#/./N01.FILENAME
I need some help with the syntax and other paramters that need to be set. Thanks
Following is what I found in the documentation
The syntax for a relative path is:
ftp://host/path/filename
Where path is the relative path of the user's home directory.
The syntax for an absolute path is:
ftp://host//path/filename
While connecting to the mainframe system, the syntax for an absolute path is:
ftp://host/\'path.filename\'
The syntax for connecting to the mainframe system through USS (Unix System Services) is:
ftp://host//path/filename
Where path is the absolute path of the user's home directory.
I have tried all the above options for URI but still getting error message as follows. With different options the value of current directory changes but the error is still around "No such file or directory'.
Remote system type is POSIX (z/OS).
HFS directory `/u/grsds' is the current directory.
Error: EDC5129I No such file or directory., file: /u/grsds/N01.FILENAME
This is what I have in URI sftp://#HOST_SERVER#/./N01.FILENAME
I need some help with the syntax and other paramters that need to be set. Thanks
Here is a sample URI from my code:
The alias (we call it a portal) redirects the session to the host location for the logon. Note that the dataset name is surrounded by single-quotes, which I note are missing from your URI sample. The other possibility is that your ftp logon id requires authorization to access the dataset, something you can't know from the error message (which is ambiguous at best).
The alias name has no slashes in it, only the periods. Except for the angle brackets, all of the text in my sample is directly replaceable, meaning the / and () are required.
I learned early on to never rely on the DataStage messaging out of FTP Enterprise. Go straight to the ftp log on the host to see if it has messages that might help you find the specific problem.
Code: Select all
ftp://<url-style alias>/'<high-level-qualifier.secondqual.datasetname(gdg generation number)'
The alias name has no slashes in it, only the periods. Except for the angle brackets, all of the text in my sample is directly replaceable, meaning the / and () are required.
I learned early on to never rely on the DataStage messaging out of FTP Enterprise. Go straight to the ftp log on the host to see if it has messages that might help you find the specific problem.
Franklin Evans
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
That's a question for your mainframe/ftp support as well. Here it looks just like a website name (changed here for security reasons, of course):
Code: Select all
zosname.anothername.com
Franklin Evans
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
I resemble your remarklstsaur wrote:The hardest thing for me to do is to convince the mainframe side to open up its security.
![Cool 8)](./images/smilies/icon_cool.gif)
Franklin Evans
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
Its still not working. Below is what I find in the DS logs
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n0
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n1
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n2
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n3
In properties of FTP stage, I have URI = ftp://hostname/../'N01.abc.xyz(+1)' ; username ; transfer mode and force parallelism set.
only when i give ".." before the filename does the current HFS directory matches with the one in existing running sftp script. If I remove tht its /u/xyz and still the next error message is the same. n1 , n2 is getting added at runtime. Thats how we are passing the file name in the script but its not working here.
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n0
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n1
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n2
Remote system type is POSIX (z/OS).
HFS directory `/u' is the current directory.
Error: No such data set, file: //'N01.abc.xyz(+1)'.n3
In properties of FTP stage, I have URI = ftp://hostname/../'N01.abc.xyz(+1)' ; username ; transfer mode and force parallelism set.
only when i give ".." before the filename does the current HFS directory matches with the one in existing running sftp script. If I remove tht its /u/xyz and still the next error message is the same. n1 , n2 is getting added at runtime. Thats how we are passing the file name in the script but its not working here.
Let's start from the beginning. Though I might not know everything I need to, I might help you find something.
1) Verify that the pointers to the datasets actually exist in the 'u/' directory your messages are confirming.
2) At this point, I don't think it's a session authority problem. The construction of the dataset names does concern me, though, because just for example the gdg generation number usually is the very last part of the data set name. That your script is appending .n0 outside of the single quotes looks very strange to me.
You are at a level of detail where your in-house support should be able to find the problem. Without seeing the host ftp log, I don't think I can be of much more help. This last point is I think very important. You keep quoting the DS log. It won't tell you much. You need access to the host ftp logs for the actual sessions outside of DS.
1) Verify that the pointers to the datasets actually exist in the 'u/' directory your messages are confirming.
2) At this point, I don't think it's a session authority problem. The construction of the dataset names does concern me, though, because just for example the gdg generation number usually is the very last part of the data set name. That your script is appending .n0 outside of the single quotes looks very strange to me.
You are at a level of detail where your in-house support should be able to find the problem. Without seeing the host ftp log, I don't think I can be of much more help. This last point is I think very important. You keep quoting the DS log. It won't tell you much. You need access to the host ftp logs for the actual sessions outside of DS.
Franklin Evans
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
Let me re-phrase.
the URI value in DS FTP stage is URI = ftp://hostname/../'N01.abc.xyz(+1)'
Datastage is adding .n0 , .n1 etc ( which I see in the logs)
Is that the correct format of filename that the ftp stage is expecting?
Appreciate all your inputs so far.
the URI value in DS FTP stage is URI = ftp://hostname/../'N01.abc.xyz(+1)'
Datastage is adding .n0 , .n1 etc ( which I see in the logs)
Is that the correct format of filename that the ftp stage is expecting?
Appreciate all your inputs so far.
Are you doing a file-pattern read for input? If so, and if you are expecting to see more than one file after the FTP, that may be the problem.
Try doing just one file at a time. If you are not doing a file pattern, I think I may be out of suggestions. Good luck, and post here your results especially if you succeed.
Try doing just one file at a time. If you are not doing a file pattern, I think I may be out of suggestions. Good luck, and post here your results especially if you succeed.
Franklin Evans
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson
Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872