Search before creating an issue
Bug Description
Follows up on #8415
SiteDirectors still rely mostly on proxies to authenticate to Computing Elements and submit pilots.
ComputingElement._prepareProxy() calls gProxyManager.dumpProxyToFile() without specifying a destinationFile, so a new temp file is created in /tmp each time the cache doesn't have a hit for the given proxy chain.
While dumpProxyToFile cache files to avoid duplicates, a cache miss (and therefore a new file) occurs whenever the proxy chain hash changes.
The previous temp files are only cleaned up on process exit. For a long-running SiteDirector with many CEs, this leads to an accumulation of orphaned proxy files in /tmp.
Steps to Reproduce
- Run a
SiteDirector for a very long time.
- See an increasing number of proxies appearing in
/tmp.
Expected Behavior
One temp proxy file per CE/VO.
Actual Behavior
Many temp proxy files with random names.
Environment
No response
Relevant Log Output
Additional Context
An elegant fix would consist in passing a deterministic destinationFile based on the CE and VO (extracted from proxy?) names, so the file is overwritten in place rather than creating a new temp file each time.
This would eliminate the accumulation entirely: one file per CE/VO, overwritten in place.
Search before creating an issue
Bug Description
Follows up on #8415
SiteDirectorsstill rely mostly on proxies to authenticate to Computing Elements and submit pilots.ComputingElement._prepareProxy()callsgProxyManager.dumpProxyToFile()without specifying adestinationFile, so a new temp file is created in/tmpeach time the cache doesn't have a hit for the given proxy chain.While
dumpProxyToFilecache files to avoid duplicates, a cache miss (and therefore a new file) occurs whenever the proxy chain hash changes.The previous temp files are only cleaned up on process exit. For a long-running
SiteDirectorwith many CEs, this leads to an accumulation of orphaned proxy files in/tmp.Steps to Reproduce
SiteDirectorfor a very long time./tmp.Expected Behavior
One temp proxy file per CE/VO.
Actual Behavior
Many temp proxy files with random names.
Environment
No response
Relevant Log Output
Additional Context
An elegant fix would consist in passing a deterministic
destinationFilebased on the CE and VO (extracted fromproxy?) names, so the file is overwritten in place rather than creating a new temp file each time.This would eliminate the accumulation entirely: one file per CE/VO, overwritten in place.