1 .TH llapi_search_rootpath 3 "2022 May 23" "Lustre User API"
3 llapi_search_rootpath, llapi_search_rootpath_by_dev \-
4 retrieve the path of a lustre mount point
7 .B #include <lustre/lustreapi.h>
9 .BI "int llapi_search_rootpath( char *" pathname " ,const char *" fsname ")
11 .BI "int llapi_search_rootpath_by_dev( char *" pathname ", dev_t " dev ")
15 .BR llapi_search_rootpath()
17 .BR llapi_search_rootpath_by_dev()
18 find the first Lustre mount point by matching the filesystem name \fIfsname\fP or the filesystem device \fIdev\fP.
20 The path of the mount point found is stored into \fIpathname\fP. This buffer should be sufficient to store the path.
23 char pathname[PATH_MAX];
25 The filesystem device can be retrieved from a file with
27 (field \fIst_dev\fP) or
29 (fields \fIstx_dev_major\fP and \fIstx_dev_minor\fP).
36 error code on failure and sets errno appropriately.
40 \fIpathname\fP pointer is NULL.
43 The Lustre mount point was not found.