question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Generated images are not being deleted from /tmp folder

See original GitHub issue

We are using the grafana-image-render in a separate docker container from Grafana and we’ve noticed that the /tmp folder is full of hundreds of thousands of png images like:

138f788c.png  
2760f9cb.png
3af9ae80.png
and so on

These are not being cleaned up and go back all the way to February when this container was created. Does the image renderer not clean these up at all or am I missing a config option somewhere?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
marefrcommented, Mar 16, 2020

Seems they’re not being automatically deleted. Thanks for reporting this

0reactions
marefrcommented, Mar 31, 2020

v1.0.12 will be available soon which includes the fix. Please note that it only does a delete o temporary file after image being rendered and served to the client Your existing temporary files you have to cleanup manually.

Read more comments on GitHub >

github_iconTop Results From Across the Web

generated temp files are not deleted - Magick - ImageMagick
A better solution might be to create a temporary folder for each call to ImageMagick and point ImageMagick to it (e.g MAGICK_TMPDIR=/data/ ...
Read more >
I cannot delete an image in tmp folder when lamda function is ...
For anyone who comes across the same problem. Please clear your image using : plt.clf(). Then save the image you created :
Read more >
Tmp. Files that I cannot delete - Microsoft Community
I have several files like this "MSI1df29.tmp" on my C drive. I do not have permission to delete them. They are all empty....
Read more >
Watch /tmp for file creation and prevent deletion of files?
Files can be created and written to but not deleted. Use chattr -a /tmp/*some folder* when you're done. Share.
Read more >
linux - Are we supposed to manually delete the contents of /tmp?
The /tmp directory must be made available for programs that require temporary files. Programs must not assume that any files or directories in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found