beostat_get_name -- get the name of node
#include <sys/beostat.h> int beostat_get_name (int node, char **name);
- The node to query
- A handle to a
char, which will be allocated with an appropriate amount of memory and then set to the name of a node. The caller must free the allocated memory when it is done with the memory.
beostat_get_name executes on the master node and returns the name of
a given node.
char *name; beostat_get_name (3, &name); printf ("The name for node 3 is %s\n", name); free (name);
Return 0 on success. If an error occurs, it will return -1.
This function relies on the
Beostat subsystem, which consists of the
proc filesystem on the remote node, the
sendstats daemon on the
remote node, the
recvstats daemon on the master node, and two shared
memory files in the directory
/var/shm. If any part of the system
breaks down, this function could fail.