[英]Need to be able to sftp to iSeries and write to a Library structure
I have created a script to move files from a Linux source to a lib folder on an iseries server - part of the script connects to the iseries server:我创建了一个脚本,用于将文件从 Linux 源移动到 iseries 服务器上的 lib 文件夹 - 脚本的一部分连接到 iseries 服务器:
sftp -oIdentityfile=/root/.ssh/id_rsa my_user@server.mydomain.com <<EOF
cd /qsys.lib/folder.lib
put *.txt
exit
EOF
In the script (on Linux source server), I able to sftp to an iseries server fine - once on, I can cd to the /qsys.lib/user.lib folder.在脚本中(在 Linux 源服务器上),我可以 sftp 到一个 iseries 服务器 - 一旦打开,我可以 cd 到 /qsys.lib/user.lib 文件夹。 Unfortunately, not able to put anything on this library folder once connected?
不幸的是,连接后无法在此库文件夹中放置任何内容?
So question is, is this possible to write (put) files to this destination using sftp with additional commands in the script to allow this?所以问题是,是否可以使用 sftp 和脚本中的其他命令将文件写入(放置)到此目标以允许这样做?
Path names in the QSYS.LIB
file system have to respect some restrictions QSYS.LIB
文件系统中的路径名必须遵守一些限制
If you want to put a file name a.txt
in a source file name MYFILE
in a library named MYLIB
for example you have to put it in some path like /qsys.lib/mylib.lib/myfile.file/a.mbr
例如,如果您想将文件名
a.txt
放在名为MYLIB
的库中的源文件名MYFILE
中,则必须将其放在某些路径中,例如/qsys.lib/mylib.lib/myfile.file/a.mbr
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.