Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
From: Bob Harris <harris@zk3.dec.com>
To: GopalKrishna Prasad <prasad@swecexc.xko.dec.com>
Subject: Re: Free Space On a Disk
Date: 1999/11/27	[thread overview]
Message-ID: <271119991722022091%harris@zk3.dec.com> (raw)
In-Reply-To: 383B6AA9.611265B5@swecexc.xko.dec.com

[[ This message was both posted and mailed: see
   the "To," "Cc," and "Newsgroups" headers for details. ]]

In article <383B6AA9.611265B5@swecexc.xko.dec.com>, GopalKrishna Prasad
<prasad@swecexc.xko.dec.com> wrote:

>    I want to extract amount of free space available on a disk (for
>example rz0). How can I do this in a C program ?

use the statvfs() or statfs() system calls.  

statvfs() is the POSIX standard way to do this, however, it lacks some
host OS specific features.  The statvfs structure is defined in the
<sys/statvfs.h> header file.

statfs() is what is used by the df utility, but the values that it
returns may not be available on all UNIX implementations.  The statfs
structure is defined in the <sys/mount.h> header file.



      reply	other threads:[~1999-11-27  5:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-11-24  5:00 Free Space On a Disk GopalKrishna Prasad
1999-11-27  5:00 ` Bob Harris [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox