]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man2/nfsservctl.2
099e6ab3660ec512486840c54bb4450a9f54eedf
[thirdparty/man-pages.git] / man2 / nfsservctl.2
1 .\" %%%LICENSE_START(PUBLIC_DOMAIN)
2 .\" This text is in the public domain.
3 .\" %%%LICENSE_END
4 .\"
5 .\" FIXME . The description of nfsservctl() on this page
6 .\" is woefully thin.
7 .\"
8 .TH NFSSERVCTL 2 2015-05-07 "Linux" "Linux Programmer's Manual"
9 .SH NAME
10 nfsservctl \- syscall interface to kernel nfs daemon
11 .SH SYNOPSIS
12 .nf
13 .B #include <linux/nfsd/syscall.h>
14 .sp
15 .BI "long nfsservctl(int " cmd ", struct nfsctl_arg *" argp ,
16 .BI " union nfsctl_res *" resp );
17 .fi
18 .SH DESCRIPTION
19 .IR Note :
20 Since Linux 3.1, this system call no longer exists.
21 It has been replaced by a set of files in the
22 .I nfsd
23 filesystem; see
24 .BR nfsd (7).
25
26 .nf
27 /*
28 * These are the commands understood by nfsctl().
29 */
30 #define NFSCTL_SVC 0 /* This is a server process. */
31 #define NFSCTL_ADDCLIENT 1 /* Add an NFS client. */
32 #define NFSCTL_DELCLIENT 2 /* Remove an NFS client. */
33 #define NFSCTL_EXPORT 3 /* Export a filesystem. */
34 #define NFSCTL_UNEXPORT 4 /* Unexport a filesystem. */
35 #define NFSCTL_UGIDUPDATE 5 /* Update a client's UID/GID map
36 (only in Linux 2.4.x and earlier). */
37 #define NFSCTL_GETFH 6 /* Get a file handle (used by mountd)
38 (only in Linux 2.4.x and earlier). */
39
40 struct nfsctl_arg {
41 int ca_version; /* safeguard */
42 union {
43 struct nfsctl_svc u_svc;
44 struct nfsctl_client u_client;
45 struct nfsctl_export u_export;
46 struct nfsctl_uidmap u_umap;
47 struct nfsctl_fhparm u_getfh;
48 unsigned int u_debug;
49 } u;
50 }
51
52 union nfsctl_res {
53 struct knfs_fh cr_getfh;
54 unsigned int cr_debug;
55 };
56 .fi
57 .SH RETURN VALUE
58 On success, zero is returned.
59 On error, \-1 is returned, and
60 .I errno
61 is set appropriately.
62 .SH CONFORMING TO
63 This call is Linux-specific.