Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

getbootfile(3) [freebsd man page]

GETBOOTFILE(3)						   BSD Library Functions Manual 					    GETBOOTFILE(3)

NAME
getbootfile -- get kernel boot file name LIBRARY
Standard C Library (libc, -lc) SYNOPSIS
#include <paths.h> const char * getbootfile(void); DESCRIPTION
The getbootfile() function retrieves the full pathname of the file from which the current kernel was loaded, and returns a static pointer to the name. A read/write interface to this information is available via the sysctl(3) MIB variable ``kern.bootfile''. RETURN VALUES
If the call succeeds a string giving the pathname is returned. If it fails, a null pointer is returned and an error code is placed in the global location errno. SEE ALSO
sysctl(3) HISTORY
The getbootfile() function appeared in FreeBSD 2.0. BUGS
If the boot blocks have not been modified to pass this information into the kernel at boot time, the static string ``/boot/kernel/kernel'' is returned instead of the real boot file. BSD
September 23, 1994 BSD

Check Out this Related Man Page

GETVFSBYNAME(3) 					   BSD Library Functions Manual 					   GETVFSBYNAME(3)

NAME
getvfsbyname -- get information about a filesystem LIBRARY
Standard C Library (libc, -lc) SYNOPSIS
#include <sys/param.h> #include <sys/mount.h> int getvfsbyname(const char *name, struct vfsconf *vfc); DESCRIPTION
The getvfsbyname() function provides access to information about a filesystem module that is configured in the kernel. If successful, the requested filesystem vfsconf is returned in the location pointed to by vfc. The fields in a ``struct vfsconf'' are defined as follows: vfc_name the name of the filesystem vfc_typenum the filesystem type number assigned by the kernel vfc_refcount the number of active mount points using the filesystem RETURN VALUES
The getvfsbyname() function returns the value 0 if successful; otherwise the value -1 is returned and the global variable errno is set to indicate the error. ERRORS
The following errors may be reported: [EFAULT] The vfc pointer contains an invalid address. [ENOENT] The name specifies a filesystem that is unknown or not configured in the kernel. SEE ALSO
mount(2), sysctl(3), mount(8), sysctl(8) HISTORY
A variant of the getvfsbyname() function first appeared in FreeBSD 2.0. BSD
May 4, 1995 BSD

Featured Tech Videos