Message Queues

Hello again,

I am having difficulty using message queues between processes and
across a network.

In both cases, the code is identical. Two processes are spawned, they
both attempt to open two message queues (one RX and one TX), followed
by bi-directional message passing. The difference between the two
processes is that the first one spawned (process A) attempts to recieve a
message first wheras the second process spawned (process B) attempts to
send first.

  1. Between Processes running on the same node

The problem here is that I must open the queues in a particular order.

Process A
TxQ = mq_open("/net/hostname1/MsgQueueAB", …)
RxQ = mq_open("/net/hostname1/MsgQueueBA", …)

while( num_messages )

RxQ = mq_open("/net/hostname1/MsgQueueAB", …)
TxQ = mq_open("/net/hostname1/MsgQueueBA", …)

while( num_messages )

If I try to open the queues in the reverse order (on Process B)
the processes lockup attampting to send messages to eachother.

  1. Between Processes running on separate nodes

The above example will not run when the two processes are
on different nodes. All of the queue functions appears to work
properly (checking the return values) and I can see the queues
on the node where they were created (hostname1), but I cannot
receive messages. I heard this is an issue with MQ for QNX 6.3.
Is this so?

Also, I am interested in using standard POSIX message queues
over different physical channels (not ethernet) is this is simple thing to


Tom Labno