getmountent(3)getmountent(3)Namegetmountent - get information about mounted file systems without block‐
getmountent(start, buffer, nentries)
struct fs_data *buffer;
The library routine retrieves mounted file system information from mem‐
ory without blocking. The file system information retrieved (the num‐
ber of free inodes and blocks) might not be up to date. If the accu‐
racy of the file system information retrieved is critical, you should
use or instead of
The start argument is the current logical location within the internal
system mount table and must be initially set to 0. The buffer argument
is the holding area for the returned information; that is, the struc‐
tures. The size of buffer should be at least the number of entries
times the size of the structure, in bytes.
The nentries argument defines the number of mount table entries that
are to be retrieved.
The number of file systems described by the information placed in buf‐
fer is returned. The start argument is updated so that successive
calls can be used to retrieve the entire mount table.
Upon successful completion, a value indicating the number of structures
stored in buffer is returned. If there are no more file systems in the
mount table, is returned. Otherwise, is returned and the global vari‐
able errno is set to indicate the error.
EINVAL Invalid argument.
EFAULT Either buffer or start causes an illegal address
to be referenced.
EIO An I/O error occurred while reading from the file
See Alsogetmnt(2), statfs(3)getmountent(3)