Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The umount of the job tmpdir often takes a lot of time (minutes!) when the user write a lot of data to it, because there are many dirty pages which are written to the disk before the umount completes. This writing is obviously a waste of resources, because as soon as the unmount is finished, the backup image for the filesystem is destroyed anyway. Unfortunatly, we currenty don't have a solid way to avoid the unnecessary writeback. What we can do is to purge the directory. Experiments show, that this is indeed faster with both: few very big files or many small files. So do that. Hard-code the directory prefix into the rm command to decrease the risk of rm removing wrong files in case future code changes are buggy and, for example, missspell a shell variable. Because the cleanup still needs time, do that in the background so that mxqd can continue.
- Loading branch information