01.01.2013 Views

AT&T UNIX™PC Unix System V Users Manual - tenox

AT&T UNIX™PC Unix System V Users Manual - tenox

AT&T UNIX™PC Unix System V Users Manual - tenox

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

USTAT (2) USTAT (2)<br />

NAME ustat - get file system statistics<br />

SYNOPSIS<br />

#include <br />

#include <br />

int ustat (dev, buf)<br />

int dev;<br />

struct ustat •buf;<br />

DESCRIPTION<br />

Ustat returns information about a mounted file system. Dev is a<br />

device number identifying a device containing a mounted file system.<br />

Buf is a pointer to a ustat structure that includes to follow­<br />

ing elements:<br />

daddr_t<br />

ino_t<br />

char<br />

char<br />

f_tfree;<br />

f_tinode;<br />

f_fname[6];<br />

f_fpack[6];<br />

I* Total free blocks *I<br />

I* Number of free inodes *I<br />

I* Filsys name •I<br />

I* Filsys pack name *I<br />

Ustat will fail if one or more of the following are true:<br />

Dev is not the device number of a device containing a<br />

mounted file system. [EINV AL]<br />

Buf points outside the process's allocated address space.<br />

[EFAULTJ<br />

RETURN VALUE<br />

Upon successful completion, a value of 0 is returned. Otherwise, a<br />

value of - 1 is returned and errno is set to indicate the error.<br />

SEE ALSO<br />

stat(2), fs( 4).<br />

- 1 -

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!