Skip to main content

[archive] Finding which user has a record locked

  • October 20, 2004
  • 13 replies
  • 0 views

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane

13 replies

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
In HPUX I have used the function:

CALL "C$LOCKPID" GIVING WS-PROCESS-ID


It is the DECLARATIVES section for each file that we access.

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
Unfortunately the c$lockpid routine does not work with windows.

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
See my post elsewhere in this forum.

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
If you are referring to the netenumfiles program, I have tried that but have not had any luck. It only seems to show files that are opened over the network.

If I use alfred to open a Vision file accoss the network, it shows up in the netenumfiles program. All of the other Vision files that are open do not show up, I assume because they are opened locally on the server by thin client users.

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
Correct, local opens are not listed by that API. Naturally, that would have been thousands of files related to the OS as well.

Have you considered using AcuServer?

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
It is not enough of a problem to justify buying another product. Thanks for your input.

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
hi,

If you run a windows 2000 or XP system (server or workstation)
you could use the managment console "mmc.exe".

If you choose the "shared folder" snap-in and connect to your
file-server. You can find under the "open files" all the files who are in use, by who and a lock indication.


Greets,

Ronald

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
Hi Ronald,

The "Shared Folders" in the MMC gives me the same info as the netenum program mentioned earlier in this post. When using the AcuConnect thin client, the Vision files are opened locally on the server and do not show up in this list.

Thanks for the suggestion,

Duane

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
I do not know what kind of performance hit it will cause, but with Windows NT/2000/XP/2003, you can map a drive to a local share and then files opened on it should show up in MMC/netenumfiles.

For example, share the folder c:\\mydata as "mydata".

net use m: \\\\mysystem\\mydata

Set FILE-PREFIX to M:\\

Now any files opened should show up in MMC/netenumfiles. (I have not tried it myself specifically with Vision files, but I know it does work generally.)

This may cause issues with the thin client server however - you would need to play around with that - I don't recall whether or not the runtime spawned by the service runs as SYSTEM or not. SYSTEM generally cannot access network drives (unless you set it up to allow null session shares). The latest thin client server apparently does now allow you to run the service in an account other than the SYSTEM account.

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
JoeD,

I was not able to get your suggestion working using mapping drive letters, but it does seem to work using by assigning the file name directly using the share (\\\\servername\\filename). It does show up in the netenumfiles program.

As you mentioned, I am sure there is a performance hit to doing this way and I do not think I want to risk that.

Thanks, Duane

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
Hi

I have the same requirement and use Acuserve. Still I can't find out how to get the username.

Can anyone help?

Thanks, Christian

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
You could use something like:

CALL "SYSTEM" USING "acurcl -info 2> /tmp/clientinfo"

This will give you a file you can parse through looking for your relevant information (Client,User, PID are all in there). Works well for us under an unix server. I'm not sure what it works like under windows servers...

[Migrated content. Thread originally posted on 20 October 2004]

We have been running on a Windows 2000 server with the thin client and using Vision files for several months. One problem I am having is trying to determine which user has a record locked.

All users are mapped to a single account on the server.

Short of recoding all of my applications, does anyone know how I can find the user or at least the PID of the task that has a record locked in a Vision file.

Thanks, Duane
There is a freeware utility called 'OpenedFilesView' available at http://www.nirsoft.net/utils/opened_files_view.html

It looks like it will do what you want.

It appears to have a command line option to output the result to a text file. This could be read by your Cobol program to determine the user programmatically.

Let us know if it works for you.

DISCLAIMER: As we are a unix shop, I have not tried this utility.

Cheers.