Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.3 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Perl Modules

    File::SharedNFSLock 0.02

    Download button

    No screenshots available
    Downloads: 211  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    NOT RATED
    0 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Steffen Muller | More programs
    Perl Artistic License / FREE
    May 11th, 2010, 23:13 GMT
    ROOT / Programming / Perl Modules

     Read user reviews (0)  Refer to a friend  Subscribe

    File::SharedNFSLock description

    Inter-machine locking on NFS volumes

    NFS (at least before v4) is evil. File locking on NFS volumes is worse. File::SharedNFSLock is a Perl module that attempts to implement file locking on NFS volumes using lock files and hard links. It's in production use at our site, but if it doesn't work for you, I'm not surprised!

    Note that the lock files are always written to the same directory as the original file! There is always one lock file per process that tries to acquire the lock. This module does NOT do signal handling. You will have to do that yourself.

    SYNOPSIS

     use File::SharedNFSLock;
     my $flock = File::SharedNFSLock->new(
     file => 'some_file_on_nfs',
     );
     my $got_lock = $flock->lock(); # blocks for $timeout_acquire seconds if necessary
     if ($got_lock) {
     # hack hack hack...
     }
     $flock->unlock;
     
     # meanwhile, on another machine or in another process:
     my $flock = File::SharedNFSLock->new(
     file => 'some_file_on_nfs',
     );
     my $got_lock = $flock->lock(); # blocks for timeout or until first process is done
     # ...



    Product's homepage

    Requirements:

    · Perl

      


    TAGS:

    inter-machine locking | NFS volumes | Perl module | inter-machine | locking | NFS

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM