Unix Programming - Synchronizing resource access across multiple platforms

This is Interesting: Free IT Magazines  
Home > Archive > Unix Programming > November 2006 > Synchronizing resource access across multiple platforms





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Synchronizing resource access across multiple platforms
kenkahn

2006-11-15, 1:21 pm

Is there some 'standard' way to implement a mutex-semaphore like access
to a hardware resource shared between applications running on different
workstations, perhaps running different platforms like AIX, Solaris or
Linux?

At any given time only one application can own/access the resource;
others must wait their turn. When the 'owner' gives the resource up,
control is given to another application.

All the applications, as well as the hardware resource, are connected
via ethernet. When the hardware is started it sends out a UDP
Broadcast message to all the applications.

I'm wondering if there's some 'standard' way of doing this; perhaps
using named pipes or something (are named pipes restricted to a single
workstation).

Any help or suggestions are appreciated.

Maxim Yegorushkin

2006-11-17, 7:30 am

kenkahn wrote:

> Is there some 'standard' way to implement a mutex-semaphore like access
> to a hardware resource shared between applications running on different
> workstations, perhaps running different platforms like AIX, Solaris or
> Linux?
>
> At any given time only one application can own/access the resource;
> others must wait their turn. When the 'owner' gives the resource up,
> control is given to another application.
>
> All the applications, as well as the hardware resource, are connected
> via ethernet. When the hardware is started it sends out a UDP
> Broadcast message to all the applications.
>
> I'm wondering if there's some 'standard' way of doing this; perhaps
> using named pipes or something (are named pipes restricted to a single
> workstation).


There are many ways to do so.

One way is to have a proxy process somewhere, which will serialize all
access to the resource. You can design a protocol which suits best your
access patterns. If the proxy provides the same (network) protocol as
the resource being hidden behind the proxy, no code change may be
required for users of the device.

Another way is to have a nfs filesystem which is mounted by all the
users of the resource. You could then serialize access by using file
locks on that filesystem.

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com