Diff. between f_bavail & f_bfree in statfs sys call???
Hi gurus,
I would like to the know the diff between the following two elements
of the statfs structure in AIX...
fsblkcnt_t f_bfree; /* free block in fs */
fsblkcnt_t f_bavail; /* free blocks avail to non-superuser*/
In AIX, both elements have the same value. But in other UNIX versions,
such as Linux, Solaris & HP_UX, they differ by a few megabytes. So that
difference amount gives me the filesystem sapce reserved for the
superuser.
Is there any reason for this behaviour in AIX?
I am in need of calculating the file system space reserved for
superuser in AIX. Is there any other method of getting it?
Any pointers on this topic would be helpful.
TIA!
Cheers
Raj.
PS: attaching statfs structure for a reference!
---------------------------
/*
* file system statistics
*/
struct statfs {
int f_version; /* version/type of statfs, 0 for now*/
int f_type; /* type of info, zero for now */
ulong_t f_bsize; /* optimal file system block size */
fsblkcnt_t f_blocks; /* total data blocks in file system */
fsblkcnt_t f_bfree; /* free block in fs */
fsblkcnt_t f_bavail; /* free blocks avail to non-superuser*/
fsfilcnt_t f_files; /* total file nodes in file system */
fsfilcnt_t f_ffree; /* free file nodes in fs */
#if !defined(_KERNEL) && defined(__64BIT__)
fsid64_t f_fsid; /* file system id */
#else
fsid_t f_fsid; /* file system id */
#endif
int f_vfstype; /* what type of vfs this is */
ulong_t f_fsize; /* fundamental file system block size*/
int f_vfsnumber; /* vfs indentifier number */
int f_vfsoff; /* reserved, for vfs specific data offset */
int f_vfslen; /* reserved, for len of vfs specific data */
int f_vfsvers; /* reserved, for vers of vfs specific data */
char f_fname[32]; /* file system name (usually mount pt.) */
char f_fpack[32]; /* file system pack name */
int f_name_max; /* maximum component name length for posix */
};
|