Score:1

Teamcity does not clean-up logs when clean-up rules are adjusted

il flag

So I have a project with large amount of build logs which previously inherited "delete after 91 days" rule from grandparent project.

I am adding the specific "delete after 31 days" rule to this project via Kotlin DSL configuration and it is displayed in this project's Clean-up Rules section.

However, after pushing Administration -> Clean-up Settings -> Start clean-up now, the disk space is not reclaimed and the builds older than 31 days still have their logs available via TeamCity UI. Waiting for a periodic clean-up does not help - the logs are still there and accessible. The logs which were older than 91 days were pruned correctly. However, when I set up the 91 days rule initially, I had the similar issue and had to remove old logs by hand.

Why does not Clean-up work as expected?

TeamCity runs as a local user (not in docker), owns the log files. They are not cleaned since TeamCity can still show logs way after they are supposed to be cleaned up. Nothing in logs. Actually, cleanup logs list some build ids to be cleaned, but when I go to these builds' pages, logs are still available there!

Marcel avatar
gb flag
I think you already answered your own question. Do it manually.
il flag
But there's a feature for that, I would expect it to work if it exists.
il flag
Now I can't even get these logs to be cleaned up after 91 days. It's as if my manual cleaning efforts tripped the automatic process and it broke down completely.
Marcel avatar
gb flag
How's it deployed? Docker? Dropped jar? Which user does it runs as? Does the user the jar run as have permissions to all its folders? What have you done to verify that the files are not being removed? Any logs showing the failure to clean up / remove old logs?
il flag
Updated @Marcel
Marcel avatar
gb flag
what do you see in Administration | Project-related Settings | Server Health ? any warnings?
il flag
There are some warnings but nothing relevant.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.