Re: [vserver] dlimit refresher script for review :)

From: Ghislain <gadnet_at_aqueos.com>
Date: Tue 28 Feb 2012 - 08:52:07 GMT
Message-ID: <4F4C95B7.4040506@aqueos.com>

I can see one issue but i don't know which would be the way to correct this:

chxid -URx -c "$1" "$DIRECTORY";

  is done AFTER the usage is recorded with USED_SPACE=$(vdu --xid
"$1" --space "$DIRECTORY" | cut -d" " -f2); so we will miss the
file that would have been tagged by the chxid and therefor be inacurate.

   But if i do the reverse and that the tagged files exceed the limit
then i will make the guest crash as it will not be able to write any
files to this directory and if this directory is the root or any system
important directory we can loose data. Then to get accurate result you
will need to run it two times and be ready in case of warning to quickly
do something about it.

regards,
ghislain.

Received on Tue Feb 28 08:52:34 2012
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Tue 28 Feb 2012 - 08:52:35 GMT by hypermail 2.1.8