* Problems with the netmesgserver under OSF/1
@ 1993-09-08 19:36 Ravikumar Dikkala
1993-09-10 15:06 ` Ravikumar Dikkala
0 siblings, 1 reply; 2+ messages in thread
From: Ravikumar Dikkala @ 1993-09-08 19:36 UTC (permalink / raw)
Hi:
I have problems trying to communicate with the remote
netmesgserver under OSF/1. I do a netname_check_in a server
port on a remote machine and then try to do a netname_look_up
from the local machine, but I get the following error message:
netname look up: (server/netname) name not checked in
Local machine (client) : OSF1 kaon 1.0.4 SVR99 i386
Remote machine (server) : OSF1 lepton 1.0.4 SVR99 i386
But when the server and client are running on the same machine,
there is no problem, the netname_look_up is successful.
Thanks for any hints,
-Ravi
PS: I have included the source for more information...
---------------Server Code-----------------------------------------
#include <mach.h>
#include <servers/netname.h>
#include <mach/port.h>
port_name_t server_port;
main()
{
kern_return_t ret;
netname_name_t name;
/*
* Allocate a new port.
*/
ret = port_allocate(task_self(), &server_port);
if (ret != KERN_SUCCESS) {
mach_error("port_allocate:", ret);
exit(1);
}
/*
* Check the name in. The ASCII name will be
* "TimeServerPort"; any client wishing to
* communicate with the time server must
* know to use this name.
*/
strcpy(name, "TimeServerPort");
ret = netname_check_in(name_server_port, name,
task_self(), server_port);
if (ret != NETNAME_SUCCESS) {
mach_error("netname check in:", ret);
exit(1);
}
while (1) {
sleep (10000);
}
}
-----------------Client Code--------------------------------------
#include <stdio.h>
#include <mach.h>
#include <servers/netname.h>
#include <mach/port.h>
port_name_t server_port;
main()
{
kern_return_t ret;
netname_name_t name;
/*
* Look up the server port using the name "TimeServerPort".
*/
strcpy(name, "TimeServerPort");
ret = netname_look_up(name_server_port, "kaon",
name, &server_port);
if (ret != NETNAME_SUCCESS) {
mach_error("netname look up:", ret);
exit(1);
}
printf (" Look up successful.\n");
}
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: Problems with the netmesgserver under OSF/1
1993-09-08 19:36 Problems with the netmesgserver under OSF/1 Ravikumar Dikkala
@ 1993-09-10 15:06 ` Ravikumar Dikkala
0 siblings, 0 replies; 2+ messages in thread
From: Ravikumar Dikkala @ 1993-09-10 15:06 UTC (permalink / raw)
Hi:
Thanks too all those who helped me out. The reason I was getting
the error:
"netname look up: (server/netname) name not checked in"
was because we were running only the Simple Message Server
(snames) on our machines instead of the Network Message Server
(netmsgserver).
-Ravi
My original posting:
--------------------------------------------------------------------------
Hi:
I have problems trying to communicate with the remote
netmesgserver under OSF/1. I do a netname_check_in a server
port on a remote machine and then try to do a netname_look_up
from the local machine, but I get the following error message:
netname look up: (server/netname) name not checked in
Local machine (client) : OSF1 kaon 1.0.4 SVR99 i386
Remote machine (server) : OSF1 lepton 1.0.4 SVR99 i386
But when the server and client are running on the same machine,
there is no problem, the netname_look_up is successful.
Thanks for any hints,
-Ravi
PS: I have included the source for more information...
---------------Server Code-----------------------------------------
#include <mach.h>
#include <servers/netname.h>
#include <mach/port.h>
port_name_t server_port;
main()
{
kern_return_t ret;
netname_name_t name;
/*
* Allocate a new port.
*/
ret = port_allocate(task_self(), &server_port);
if (ret != KERN_SUCCESS) {
mach_error("port_allocate:", ret);
exit(1);
}
/*
* Check the name in. The ASCII name will be
* "TimeServerPort"; any client wishing to
* communicate with the time server must
* know to use this name.
*/
strcpy(name, "TimeServerPort");
ret = netname_check_in(name_server_port, name,
task_self(), server_port);
if (ret != NETNAME_SUCCESS) {
mach_error("netname check in:", ret);
exit(1);
}
while (1) {
sleep (10000);
}
}
-----------------Client Code--------------------------------------
#include <stdio.h>
#include <mach.h>
#include <servers/netname.h>
#include <mach/port.h>
port_name_t server_port;
main()
{
kern_return_t ret;
netname_name_t name;
/*
* Look up the server port using the name "TimeServerPort".
*/
strcpy(name, "TimeServerPort");
ret = netname_look_up(name_server_port, "kaon",
name, &server_port);
if (ret != NETNAME_SUCCESS) {
mach_error("netname look up:", ret);
exit(1);
}
printf (" Look up successful.\n");
}
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1993-09-10 15:06 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1993-09-08 19:36 Problems with the netmesgserver under OSF/1 Ravikumar Dikkala
1993-09-10 15:06 ` Ravikumar Dikkala
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox