Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

File locking in Linux

Status
Not open for further replies.

xailer

Programmer
Nov 6, 2003
13
SI
hi

I don't get the whole atomic file locking in Linux.
First,are they called lock files because they restrict access to only program that created them?

Also,lock files act only as indicators and are termed advisory.
Indicators of what?And why are they termed advisory?

thank you

bye
 
> And why are they termed advisory?
Because a program can choose to ignore them.
Two programs which share a file have to agree to use locks in a specific way if it is to work as expected.

If you want mandatory locking, then I think there is an option you have to specify when the file system itself is mounted. This obviously requires some work from your sys-admin.

The bottom of the flock manual page (SEE ALSO) tells you more about it.

--
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top