File locking in Multiuser environment

Posted on 2012-09-03
Last Modified: 2012-09-05
Hello Experts

I am working in a multiuser environment and am searching for software/method that will help me with the following:

-When a user1 opens a file, no other user can edit it until user1 closes it, similar to a way a     DBMS would lock a record (for example) from being changed if its being used by another user.

Your assistance is highly appreciated
Question by:devguru001
    LVL 18

    Expert Comment

    by:Sushil Sonawane
    When a one user already opened a.doc file and same time another user access the same file that time user second automaticaly file open as read only mode. The user can't write on the file upto user one close the open file.

    Author Comment

    I understand.  That was the ideal situation.  Another alternative is to not allow the second user to open the file at all, instead of changing the files permissions.  This way, only one user can edit the file at a time.  Any ideas on how I can accomplish this?
    LVL 22

    Expert Comment

    Like sushil84 already said, if the file is open by someone else, you may be able to open the file too, but you cannot add or change something. What filetypes are we talking about?
    LVL 18

    Expert Comment

    by:Sushil Sonawane
    I think your are searching for software/method as your requriement is not available.
    LVL 23

    Accepted Solution

    I cannot see any general solution to your problem. There are specific solutions for certain development systems and databases, but no general solution.

    Moving the file to an unshared location would work, but the user would have to move it back .... then of course, you would have backup and security issues.

    If a user were to temporarily rename a file like this when they want exclusive access .....
    Document22.doc    >>>>   zzzDocument22.doc
    it would work

    Not an elegant workaround, but it will work.

    If the files are sorted alphabetically all the documents being worked upon will be at the end of the list, or use == instead of zzz if you want them at the top of the list

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Find Ransomware Secrets With All-Source Analysis

    Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

    Preface Having the need * to contact many different companies with different infrastructures * do remote maintenance in their network required us to implement a more flexible routing solution. As RAS, PPTP, L2TP and VPN Client connections are no…
    Hallo! I guess almost every Windows Administrator must have got stumped with this question "Where does WINDOWS store a users cached credentials? Every user who had once logged onto a Server/Desktop while it was connected to the domain could sti…
    In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
    With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now