Do a WRKLNK on the NFS file and then take option 5 to view the file.
If this works, then you should theoretically be able to read it via RPG.
Also try and CPY it from NFS to the IFS. If this works as well you
should theoretically be able to open it directly from RPG.
Sounds like you still have some permission issues.
Regards,
Richard Schoen
RJS Software Systems Inc.
"Get the information you need. Now!"
Email: richard@xxxxxxxxxxxxxxx
Web Site:
http://www.rjssoftware.com
Tel: (952) 898-3038
Fax: (952) 898-1781
Toll Free: (888) RJSSOFT
-----------
message: 1
date: Wed, 30 Apr 2008 17:12:13 -0500
from: Bruce Collins <Bruce.Collins@xxxxxxxxxxxxx>
subject: Reading From an NFS
I installed Windows Services for Unix 3.5 on one of our Windows 2003
servers.
The NFS Services is running and I have shared the directory under the
tab "NFS Sharing" and made sure that I allowed Anonymous Access and set
the Anonymous UID to 0 Zero and the Anonymous GID to 0 Zero.
I set permissions for All Machines to have Read-Write access and the
encoding to be ANSI.
Under the security tab I Added Anonymous Logon and Everyone and gave
them Full Control.
I went to my iSeries and created a directory on the IFS and gave it
appropriate permissions.
Mount type(*nfs) mfs('10.0.108.18:/ImageCache')
mntovrdir('/iseriesnfs')
options('rw,nosuid,retry=5,rsize=8096,wsize=8096,timeo=20,retrans=5,acre
gmin=30,acregmax=60,acdirmin=30,acdirmax=60,hard')
I then wrote an RPG program to read the directory and when if finds a
particular type of file extension i.e. .txt then to read the file.
When I open the file it returns a handle
gHandle = open(%trim(fnwithdir): O_RDONLY: S_IRWXU + S_IRWXG +
S_IRWXO);
When I read the file gBytes is 0 Zero.
gBytes = read(gHandle: gDataPtr: gDataPtrSize);
I would think that gBytes should be greater than 0.
I have validated that there is data in the file I am trying to read.
Any thoughts?
Thanks
As an Amazon Associate we earn from qualifying purchases.