-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
remove temporary files after crash. #43
Comments
If there is a crash, you want to be able to look at the logs. It is possible that clean up upon success is not perfect. Haven't check, but should be fixed if that's the case. Also note #39, which is (remotely) related. |
Hi Philippe I think the cleanup upon success is only missing one part, the removal of the directory. about your corolarry... users are lazy so the files will usually be left behind. you suggestion to delete $SCRATCH/tmp_ecearth3 all at once is tempting, but you might end up deleting files during an ece3-postproc process is active Not sure what is the best approach. |
I think the best approach is to have a tmpdir which is unique for the experiment, so you can delete it when you are finished |
Yes, probably the easiest way to go. |
Hi,
Pablo from BSC reports that lots of temporary files remain after running ece3-postproc. Some of the folders are quite large, which happens after the scripts crash. It seems that folder created by mktemp are not automatically deleted.
As a workaround, we could put them in a unique folder (e.g. $SCRATCH/tmp_ecearth3/$expid) and delete that folder later on.
Probably a better solution is to create the folder in $TMPDIR instead of $SCRATCH, so when the job finishes the files are deleted. But this has the drawback that in case of an error the files are not around for debugging. Also it might be platform dependent, so we could define the top-level folder in the conf/ files.
But a drawback to this is that the files might not be available for debugging (also platform dependent).
Any thoughts @plesager @pabretonniere @mcastril @aearamos ?
The text was updated successfully, but these errors were encountered: