Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/s/setdomainname.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/s/setdomainname.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/s/setdomainname.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/s/setdomainname.html on line 8

setdomainname()

Set the domain name of the current host

Synopsis:

#include <unistd.h>

int setdomainname( const char * name,
                   size_t namelen );

Arguments:

name
The domain name.
namelen
The length of the name.

Library:

libsocket

Use the -l socket option to qcc to link against this library.

Description:

The setdomainname() function sets the domain name of the host machine. Only the superuser (root) can use this function and even then, the function is normally used only when bootstrapping a system.

Returns:

0
Success.
-1
Failure; errno is set.

Errors:

EFAULT
The name or namelen parameters gave an invalid address.
EPERM
The caller tried to set the domain name without being the superuser.

Classification:

Unix

Safety:
Cancellation point No
Interrupt handler Yes
Signal handler Yes
Thread Yes

See also:

getdomainname()


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/s/setdomainname.html on line 145

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/s/setdomainname.html on line 145