Workspace directories deleted monthly

My build directories in my work-space are removed on the first day of the month.
It has happened now for 3 months in a row (since I started using Jenkins).
Why does this happen and how can I control it (NOT remove them)?

Hi @twurgler,

What kind of directories are being removed? Like the whole workspace directory on the agent is being removed/emptied? Presumably, there’s no configuration in the pipeline or job that should be removing the workspace and recreating it?


The $HOME/jenkins-workspace/workspace/{project name} directory still exists.

There are 2 directories under that yet that have the source I compile. These 2 directories are git directories that the Jenkins first does a “git pull” to update them from the master repository. These 2 directories were initially created with “git clone {main repository}”.

So during the month, I run Jenkins using a pipeline, multiple times a week. There are no lines relating to removing those 2 directories. We found a log for Nov 1 where Jenkins deleted the 2 directories once again. So I have to clone them again and continue on.

So right now I can’t find that log again to show you.

It’s this: Jenkins Features Controlled with System Properties

1 Like