Recommend, please, some simple popular daemon support lock that waits for connections from clients on TCP and handles the requests for exclusive locks.
I need to synchronize concurrent PHP processes on MULTIPLE machines. For example, the first machine can say "I block the ID of 'abcd' starting from the current moment until my death/disconnect". And if the second car then say "lock 'abcd'", the query "most intriguing moment" as long as the first machine releases the ID 'abcd'. It is important that the identifier should also automatically released if the process dies unexpectedly and doesn't have the ability to tell the daemon lock, which it releases the identifier (it may work, for example, through the tracking of disconnection on the side of the demon — because when the client dies, the connection with the demon breaks).
I looked in the direction of the memcached add(), but it doesn't quite fit because a) can't handle sudden disconnects (the connection with the server though and keeps, but from the point of view of the semantics of lock means nothing) and b) I do not fit the schema lock to be released just in time out of inactivity of the process because the process can be random time.
Need is a demon who knows how to work with persistent connections and handles them in the gap as a signal for releasing the lock.