Silverfrost Forums

Welcome to our forums

File access on enterprise networks

2 Oct 2020 10:37 #26430

Please accept my apologies for my lack of technical knowledge, but I am hoping someone out there will know the answer.

The software we write, almost all in Clearwin uses the following calls to read and write to files (it's constantly doing this as our software is running in response to user activity).

OPEN(LUS(NAREA), FILE=WSSURV(1:NWSURV+4), IOSTAT=IOS, * ERR=903, STATUS='OLD', ACCESS='DIRECT', RECL=1664, * SHARE='DENYRW')

Files are created and destroyed usually in the user's temp folder and then at the user's behest, they are then saved away into their desired folder location.

Many customers are experiencing files going missing or spurious messages to do with 'not enough disk space', which is never the case.

We need to know the following about the method being used by salflibc.dll

Is it using Windows API ? (CreateFile or OpenFile) Is it using MS-DOS? Is it using some other method accessing hardware directly.

We have always accepted that it's best for customers to store their data on local drives, but this isn't always possible nowadays and even having to map a physical network drive isn't possible, especially when using cloud storage, so any advice on this would be very much appreciated please.

Thank you.

2 Oct 2020 4:08 #26431

I presume you are talking about FTN95 in 32- or 64-bit.

The run-time library uses CreateFile/OpenFile.

2 Oct 2020 7:32 #26432

There are one or two hints in your post that the application relates to topographic survey, although I could be wrong.

I wrote an application for use by students on a topographic survey field course. It worked fine on stand-alone desktop style PCs. At one point, these were replaced by laptops. Unfortunately, the University technical support had configured them so that if they weren’t connected to a particular segment of the Uni network, they would shut down, and this usually happened when the students had spent time entering data. Not understanding what was happening, they didn’t immediately save their work. It so happened that the field course venue was 60 miles from the relevant building, and so they couldn’t connect via WiFi!

This was worse than stupid, as the laptops could not connect to that segment, even if used in the Uni, because Civil Engineering was located several miles from the building that housed that network segment!

On complaining about this, the technical support re-imaged the laptops, protecting installed software by making many sub-directories read-only. This included the default datafile folder for the application, which at that time wasn’t written to offer multiple attempts at data saving. As a result, the application continued to lose data until the requisite number of backsides had been well and truly kicked (and a little more software development was done by me!)

My experience with such idiocy suggests to me that there is a good chance that the issue lies not with your application (FTN95 &/or CW+), but in how the network is configured. In some organisations, the priority is for the convenience of the tech support group, and not of the users.

Eddie

3 Oct 2020 1:36 #26433

Quoted from John-Silver from the snippet you post you seem to be trying to OPEN an array as if it is a file , is that correct ? The FILE= parameter seems to reference an array and not a file? I don't think that's possible.

I think John S., that you are imagining the worst.

If LUS is an integer array, the OPEN statement is using an element of that array as the unit number for opening a file. He is not passing the array, but only an element of the array. Any integer-valued expression could be used after an explicit or implicit UNIT=.

There is nothing wrong with storing or computing a table of unit numbers (integers) and file names (character strings), and opening each matched pair with an OPEN statement, inside a DO loop that covers all the files that one wishes to open.

3 Oct 2020 2:31 #26434

John, I do this kind of OPEN statement all the time, except for the SHARE option. It is not a problem to supply a unit number from an array, nor to specify the name of the file from an array. Any option that is enclosed in quotes can be handled by a variable (or array element). Similarly for any number that is to be supplied.

I have a single open/close routine that does all the 'magic' behind the scenes. It is what has allowed my software to be ported from a CP/M based micro processor, to MS-DOS, PDP, VAX, Prime, and into Windows (Thanks Silverfrost!).

lozzer: One thing you need to provide is the returned error code. Without it, there is no way to have us help.

For instance, if you are opening a file under DropBox (yes, you can have a networked drive attached to DropBox), you may get the occasional error code 10000 or higher on OPEN operations. It is not consistent, a symptom that you also describe. Is it that? No one can tell. Not enough information

What I have done in my open/close routine is to intercept the error message. If it is > 10000, it is assumed to be a DropBox interference, I wait just a bit, and re-try. I will do that up to 50 times. Since implementing this, I have had zero problems.

You might need to have a re-try if (and this does happen) the file system is a little sluggish allowing the file to open. But, you need the error code (IOS in your example).

5 Oct 2020 6:37 #26435

Thank you everyone. As I said, I am not technical. We are indeed using FTN95.

I will ask a colleague to intervene to provide more information.

Your support and interest is very much appreciated.

6 Oct 2020 9:17 #26438

Quoted from Robert I presume you are talking about FTN95 in 32- or 64-bit.

The run-time library uses CreateFile/OpenFile.

Can you offer any suggestions please as to why we get intermittent errors while accessing files on mapped network drives.

9 Nov 2020 11:11 #26571

What iostats do you get? When do the errors appear -- is it on open or during the write?

10 Nov 2020 5:20 #26577

Note FTN95 Ver 8.50 introduced IOMSG=. Combining IOSTAT= and IOMSG= in all I/O for the file could help with informing on what is happening.

Can SHARE='DENYRW' interact with any network virus scanning ?

Please login to reply.