message queues: msgrcv uses round-robin?
I have this server accepting messages through IPC using msgrcv. I am able to send messages to it using msgsnd and they arrive fine.
My problem is that when more servers are listening to the message queue (the same one), then every server gets a message in turn.
e.g.
I have 2 servers listening with msgrcv and I send 4 messages from the same client:
Server 1 receives message 1
Server 2 receives message 2
Server 1 receives message 3
Server 2 receives message 4
and so forth.
This is with linux kernel 2.6.
With kernel 2.4 this happens instead:
Server 1 receives message 1
Server 1 receives message 2
Server 1 receives message 3
Server 1 receives message 4
Only the first server receives any message. My problem is that I want the kernel 2.4 behaviour, i.e. only one client can listen to incoming messages. Is that possible with message queues?
|