📄 getfsent.3x
字号:
.\" SCCSID: @(#)getfsent.3x 8.1 9/11/90.TH getfsent 3x.SH Namegetfsent, getfsspec, getfsfile, getfstype, setfsent, endfsent \- get file system descriptor file entry.SH Syntax.nf.B #include <fstab.h>.B #include "/usr/include/sys/fs_types.h".PP.B struct fstab *getfsent().PP.B struct fstab *getfsspec(\fIspec\fP).B char *\fIspec\fP;.PP.B struct fstab *getfsfile(\fIfile\fP).B char *\fIfile\fP;.PP.B struct fstab *getfstype(\fItype\fP).B char *\fItype\fP;.PP.B int setfsent().PP.B int endfsent().fi.SH Description.NXR "getfsent subroutine".NXR "getfsspec subroutine".NXR "getfsfile subroutine".NXR "getfstype subroutine".NXR "setfsent subroutine".NXR "endfsent subroutine".NXR "fstab file" "getting entry".NXR "fstab file" "setting".NXR "fstab file" "closing".NXR "fstab file" "getting special file name".NXR "fstab file" "getting file system name".NXR "fstab file" "getting file system type".NXA "fstab file" "getfsent subroutine"All routines operate on the file .PN /etc/fstab ,which containsdescriptions of the known file systems.The routine.PN setfsentopens this file. The routine.PN getfsentreads the next file system description within .PN /etc/fstabopening the file if necessary. The.PN endfsent routine closes the file..PPThe.PN getfsspec ,.PN getfsfile ,and.PN getfstyperoutinessequentially scan the file .PN /etc/fstabfor specific file system descriptions. The.PN getfsspecroutine searches for a description with a matching special file name field. The routine.PN getfsfilesearches for a description with a matching file system path prefix field.The routine.PN getfstypesearches for a description with a matching file system type field..PPThe.PN getfsent ,.PN getfsspec ,.PN getfstype, and.PN getfsfileeachreturn a pointer to a representation of the description they havematched or read.Representations are in the format of the following structure:.EX#define FSTAB_RW "rw" /* read-write device */#define FSTAB_RO "ro" /* read-only device */#define FSTAB_RQ "rq" /* read-write with quotas */#define FSTAB_SW "sw" /* swap device */#define FSTAB_XX "xx" /* ignore totally */struct fstab { char *fs_spec; /* block special device name */ char *fs_file; /* file system path prefix */ char *fs_type; /* rw,ro,sw or xx */ int fs_freq; /* dump frequency, in days */ int fs_passno; /* pass number on parallel dump */ char *fs_name; /* name of the file system type */ char *fs_opts /* arbitrary options field */};.EE.SH Return ValuesA NULL or 0 is returned, but .I errnois not seton detection of errors..SH Restrictions All descriptions are contained instatic areas, which should be copied. .SH Files.TP 15/etc/fstabFile system information file..SH See Alsofstab(5)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -