flux_shell_get_hostname(3)

SYNOPSIS

#include <flux/shell.h>
#include <errno.h>

const struct hostlist * flux_shell_get_hostlist (flux_shell_t *shell);

Link with -lflux-core -lflux-hostlist.

DESCRIPTION

flux_shell_get_hostlist() returns the list of hosts assigned to the current job in struct hostlist form. This hostlist can be used to map job node IDs or job shell ranks to hostnames using the interfaces exported in libflux-hostlist.so.

RETURN VALUE

This function returns a pointer to the shell's internal struct hostlist or NULL on failure with errno set.

ERRORS

EINVAL

if shell is NULL or the function is called before the hostlist is available to the job shell.

RESOURCES

Flux: http://flux-framework.org

Flux RFC: https://flux-framework.readthedocs.io/projects/flux-rfc

Issue Tracker: https://github.com/flux-framework/flux-core/issues

FLUX RFC

34/Flux Task Map