Chris McKillop <firstname.lastname@example.org
I think the idea is to find the processes by always using /net. In the
local case you can use "/net/localhost/" and if you need to talk to a remote
machine you can use "/net/machinename". This doesn't cover global names
but the reality is you generally know the name of the machine you want to
talk to anyways.
This is potentially error prone. /net does not exist if qnet isn't running, but
if you use something that isn't dependant on /net... ie. /var/net then the
name_locate function could simply look there first and then walk /net if it
exists. As for knowing the name of the machine, that's completely opposite
of why you want a global namespace. I *don't* want to know the name of the
machine, because it can change. During development/testing, I might have
all the processes/resmgrs running on the same machine, but when I deploy, it
might be different, and possibly distributed. So, I think this is a bad idea
unless you make your app use some kind of configuration file that you can
edit, but even that is something that you don't really need if you make the
One of the issues that I personally didn't like about how naming worked on
QNX4 was the fact that you where basically forced to use the global name
space to communicate between two nodes and when there where mulitple
registrations of the same global name sometimes things worked out kinda funny.
Agreed. I actually liked the QNX2 method where the uniqueness of global names
was enforced (ie. you could not attach a duplicate name). True, the QNX4 ability
to have multiple allowed for the situation of some failover transparency, but
it could be rather complex to get it right. For the most part, I think developers
tried to avoid having duplicate names unless absolutely neccesary.
the case of multiple machines with the same named resource. Perhaps using
an open standard like LDAP or some other open scheme.
I hadn't thought of LDAP. That's an interesting idea, but is also pretty
heavy in terms of solutions, especially when working with small embedded systems.
For the larger systems that might have LDAP for other reasons, it's a perfect
Another thing I found light-years ahead of QNX4 was the push to use resmgrs
so that all applications can use the POSIX APIs to communicate to the
managers over the network.
The push would have been ignored if they API hand not made it so easy. The
same push existed in QNX4, but it still wasn't _that_ easy, so it was rarely
done outside of QSSL. QNX4 still had some black magic associated with the
technique as well. QNX6 has some black magic required when you want to handle
directories rather than individual entries, and that needs to be addressed in
the docs (as I am sure it will).
Using a global name is pretty much useless if you want to use perl to talk
to your service.
Well, this depends.
If you use name_attach() and name_locate(), then you
could have a resmgr manage the /var/net space and perform a redirect/symlink
type service to point to the actual resource in /net/machine/... then you COULD.
Mind you, there isn't any reason why you can't have a resmgr sit "on top" of /var/net
and examine those requests to determine if it needed to let them pass-thru or
be redirected, somewhat like fs-pkg does already.
There is a related topic (cdm: you knew this was coming), which is remote spawn,
which is, IMO the other requirement of being able to actually create distributed
Right now remote spawn *IS* possible, but it needs to be wrapped up in an API call
of some sort to move it out of the realm of "guru black magic".