Jump to content

How is deny mode implemented in UNIX?


Recommended Posts

Hello all!

In order to not jeopardize concurrent access to a file, I have made some tests with the "deny mode" wire to the "open file" vi. It seems to work (I am using lv 7.1.1 on Solaris). I do accesses from different hosts that map the same NFS partitions. Looking at the file properties during execution of the tests, no permissions are altered. Neither can I see that any kind of lock file is created. I have also noticed the the file is only locked for labview. I can access the file perfectly with emacs or cat.

My question is therefore: How is this "deny mode" functionality implemented in solaris? I dont want to break it unintentionally.

Link to comment

QUOTE (Jon Sjöstedt @ Sep 3 2008, 03:39 AM)

Hello all!

In order to not jeopardize concurrent access to a file, I have made some tests with the "deny mode" wire to the "open file" vi. It seems to work (I am using lv 7.1.1 on Solaris). I do accesses from different hosts that map the same NFS partitions. Looking at the file properties during execution of the tests, no permissions are altered. Neither can I see that any kind of lock file is created. I have also noticed the the file is only locked for labview. I can access the file perfectly with emacs or cat.

My question is therefore: How is this "deny mode" functionality implemented in solaris? I dont want to break it unintentionally.

Not sure about Solaris really and Solaris in many ways is often a bit special. But on Linux it seems to be implemented by range locking the entire file.

fcntl(fd, F_SETLK, &lock)

Rolf Kalbermatter

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.