Skip to content
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

Update scrontab to prune slurm logs #269

Merged
merged 5 commits into from
Oct 5, 2023
Merged

Conversation

blinkdog
Copy link
Contributor

@blinkdog blinkdog commented Oct 5, 2023

cd /global/homes/i/icecubed/lta/slurm-logs; find . -type f -mtime 7 -delete

Not the most brilliant construction. If /global/homes/i/icecubed/lta/slurm-logs doesn't exist or is somehow inaccessible, it deletes things exactly a week old wherever scrontab jobs happen to start ... is that ${HOME}? No idea.

Replaced with:
find /global/homes/i/icecubed/lta/slurm-logs -type f -mtime +7 -delete

This will find in the provided directory, or fail, and the +7 means we get all the logs one week and older, not just those exactly a week old.

@blinkdog blinkdog self-assigned this Oct 5, 2023
@blinkdog
Copy link
Contributor Author

blinkdog commented Oct 5, 2023

This is failing on test setups that want new Python 3.12 dependencies, but...

  1. We use Python 3.10 in the deployment on Perlmutter at NERSC.
  2. This PR is not a code change; it captures a configuration change already made at NERSC.

I'll merge this one and hope for better 3.12 support in CI/CD the future.

@blinkdog blinkdog merged commit c53611b into master Oct 5, 2023
27 of 33 checks passed
@blinkdog blinkdog deleted the update-nersc-scrontab branch October 5, 2023 09:21
@blinkdog blinkdog changed the title Update scrontab for prune slurm logs Update scrontab to prune slurm logs Oct 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant