qnet source code

Hi,
i looking qnet source code. i want to know how exactly qnet detects the remote node is their or not.
io-net uses “ndp” to detect the remote node or neighbour nodes. please give me an idea how exactly ndp detect the neighbour nodes.

  1. how ndp identifies the neighbour node?
  2. how qnx knows about this (source code)?
  3. As soon as the remote node disconnected how the ndp gets the information and how it gives to qnet.

Thanks,
raj.

Hi!

Everything what belongs to QNET is covered by fog “it’s our proprietary protocol and we tell noone how this works”. But for me this fog smells like “it was never good documented”. At least I never got any document about QNET protocol implementation except some general blah-blah papers those available in QNX documentation.

Answering your questions:

  1. Spying with wireshark I have found that ndp protocol works following way:
  • every node at startup of QNET stack fires a broadcast packets “Boys, I’m Mickey!” to network,
  • every who got such message adds Mickey in his list and send packet “Hi Mickey, I’m Donald!”,
  • when initial node gets such packet it also adds senders to his list and also says “Hi Donald, I’m Mickey!”.
  1. donno
  2. I’m not sure but perhaps here is no dedicated packet for this case exist. A node simply suddenly gets no any reply packets from another node because addressee is down, tries find him by “Hi Mickey, I’m Donald!” messages, and if this doesn’t help removes him from internal node list. This is only a guess because I didn’t dig this part of a protocol.
  1. In the QNX 2 days, there was a packet the periodically was sent to say “I’m alive”. I’m willing to bet that it has existed through to QNX 4 and QNX 6. There is a trade off here. If you want your application to know that a node has gone down within a milli-second, then these packets must be sent every millisecond, using bandwidth. I think this timeout is adjustable. I think io-net also would notice if you send a message and no ACK appears within some timeout amount. If a process is Reply blocked however, there would be no way to know that either node is gone unless by the first method.

Do you really need to deal with io-net itself? It isn’t good for you some other outside io-net detection method?

Juan Manuel