[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Purging bug
From: |
Patrick Forsberg |
Subject: |
Purging bug |
Date: |
Thu, 14 Dec 2000 16:59:24 +0100 (MET) |
Hi.
I found a bug in 1.5.4 that I think is still present in 1.6.0.
What happens is that when it's time to purge a directory this isn't done
recursively but instead the dir is just unlinked. This leaves files on
the filesystem that are only removed with fsck (Not even that if you're
make a clean reboot since the filesystem then is considered clean)
Since we use cfengine for rdisting we've found out this the hard way.
(Filesystems get full and du -dks gives different numbers than df -k)
I haven't had the time to look too thoroughly at the source but I think
the error lies within image.c
I have tested this with the following setup.
###cfengine.conf
import:
any::
site
rdist
###site
classes:
rdist_clients_local = ( boudin_math_chalmers_se )
control:
any::
actionsequence = ( copy )
###rdist
copy:
rdist_clients_local::
/local/cftest
dest=/local/cftest type=sum recurse=inf
purge=true
server=foo.bar
First I created the follwing structure on the server and ran cfengine on
the client
>ls -R /local/cftest/
/local/cftest/:
dir1/ fil1
/local/cftest/dir1:
dir1.1/ fil1.1
/local/cftest/dir1/dir1.1:
fil1.1.1
Then I removed /local/cftest/dir1/dir1.1/ with rm -rf on the server and
ran cfengine again. The truss output is attached.
As you can see /local/cftest/dir1/dir1.1 is unlinked without removing
/local/cftest/dir1/dir1.1/fil1.1.1
/Patrick
--
------------------------------------------------------------------------
System administrator at math.chalmers.se|address@hidden|cd|dtek}.chalmers.se
Webmaster at www.md.chalmers.se |WCT #638
------------------------------------------------------------------------
cfengine.truss
Description: Truss output running cfengine.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Purging bug,
Patrick Forsberg <=