disk space weirdness

John Macdonald john-Z7w/En0MP3xWk0Htik3J/w at public.gmane.org
Fri Mar 11 00:04:24 UTC 2005


On Thu, Mar 10, 2005 at 05:37:14PM -0500, Taavi Burns wrote:
> On Mon, 7 Mar 2005 18:47:57 -0800 (PST), J. Qiang Li
> <shijialee-/E1597aS9LQAvxtiuMwx3w at public.gmane.org> wrote:
> > Hello,
> > 
> > I am having a weird problem. When i moved one huge file under / parition to /var partition, I saw
> > the /var partition usage increased to the expected size and / partition usage still remains the
> > same.
> > I am pretty sure the file is not in / anymore and yet the usage for / don't change. What is going
> > on ?
> > 
> > here is the df output, as u can see / and /var are different partition :
> 
> If some program still has the huge file open on /, then it won't
> actually have been removed yet (the name is gone, but the inode and
> associated disk space will remain in use until all file handles are
> closed).  Try the lsof utility to see if this is the case.

Or alternatively, if the original file had more than one
link, the space is not freed until the *last* link is deleted.
A file with multiple links only has one copy of the data, plus
the multiple directory entries which each point to the copy of
the data.  (This is true of Unix-like file system types such
as ext*, reiser, jfs, xfs, etc., but it need not be true for
all file system, and possibly is not true for hosted non-Unix
file systems like FAT*.)

-- 
--
The Toronto Linux Users Group.      Meetings: http://tlug.ss.org
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://tlug.ss.org/subscribe.shtml





More information about the Legacy mailing list