I'm trying to find out the directory size of a folder to determine if a user has rights to keep writing to the folder (i.e. they are within the given limits I've imposed).
du -sb <path>
which is fine and all, but the problem is if whilst this is being executed, another user deletes something from that directory then
du chucks a bunch of
Cannot find file errors to the console.
Is there any way of handling this or at least stopping du chucking errors?