Comments (13)
It looks like it's working as it should:)
Unpurged/deleted reports still have a link which might come handy sometime, but purged are not linked. From my side it works as expected.
from puppet-summary.
Yea yea, typo on my end:)
Unchanged reports that are still on the disk and not purged by purge -unchanged
.
from puppet-summary.
With that volume of reports I can see that this would be a useful enhancement.
I would probably add a new flag to the prune
command:
puppet-summary prune -days=3
- Delete all reports which are older than 3 days.
- This means remove from the various views and delete the report from disk.
puppet-summary prune -unchanged
- Delete all reports from disc where the status is "unchanged".
- But keep the reports in the various views.
I'm just a little unsure whether to keep the references to the "unchanged" reports in the views; on the one hand it shows you that puppet did run, on the other hand if you can't click it for the details maybe it is not worth showing?
If we remove the entries, not just the files, then I suspect the end result is that over time nodes would become "orphaned" as the might be days where every run was "unchanged" - so if we remove them all the node will have no local state.
That makes me think we just reap the report-files, and leave the records (until they're removed via the -days
mechanism). Does that seem sane?
from puppet-summary.
I would definitely keep the references to the "unchanged" states for the exact reason you said in the other part of reply. I want to see if puppet was ran or not, because this way I can see "orphaned" hosts, which comes handy from time to time (catching users who forget to start puppet after testing:P)
As far as your commands go, they seem sane and simple to use. Would one then have to run puppet-summary prune -unchanged
via crontab?
from puppet-summary.
For test, I erased all unchanged reports and disk usage changed from 12GB to 28MB.
from puppet-summary.
The commit e0487ee should have given you what you want.
Update via:
go get -u github.com/skx/puppet-summary
Then run this to test it:
puppet-summary prune -unchanged [-prefix ./blah/blah]
The downside is, as I realized too late, that the links to the report will still exist - because the renderer doesn't read/touch the path. So you'll get a 404..
from puppet-summary.
Wow, that was fast:)
Compiled and ran it, it cleaned up my reports folder nicely. prune
added to hourly crontab.
And, as you already realized, I get 404 when accessing unexisting report:
open reports/pruned: no such file or directory
One solution would be to check if report ID
is pruned
here and in this case, not create a link. I'm not sure if this is a good solution or not, but this one came to mind:)
from puppet-summary.
Yeah it needs a bit more work, as the report ID is numeric - it's the yaml_file
column in the database which is set to pruned
- and that isn't part of the struct/record that the node-view has access to.
Shouldn't be hard to fix, but it'll take me a day or two I guess.
from puppet-summary.
Ooo ok:) I would help you, but Go is not my thing:/
Yea, no need to hurry, current solution works for me. Not linking unchanged
reports is just a nice touch:)
from puppet-summary.
Got there in the end :)
from puppet-summary.
Great! Will recompile today.
This patch is really helping me to keep low disk usage. I'm keeping 14 days of reports and disk usage is around 27GB for cca 16k reports/day.
from puppet-summary.
Nice to hear it works at that kind of scale!
Let me know if you do/don't see any problem, and then I'll tag a new release.
from puppet-summary.
I assume you meant "Unpurged/undeleted", i.e. reports of changes are still linked.
But thanks for the speedy update. I'll tag a new release later in the day, which will show up on the download-page.
from puppet-summary.
Related Issues (20)
- Feature Request, tab for environments HOT 1
- Pruning/auto-pruning not working due to locked database HOT 2
- Issue: Node count doesn't increase when new nodes come online. HOT 8
- Performance issues in initial display HOT 1
- Add static-check analysis to the test-script,. HOT 1
- Add screenshots, remove sample link.
- Do not depend on external sites HOT 3
- Feature Request: Certificate request manual approvals
- stale environments in drop down for environments HOT 18
- max limit on node report display is 50? HOT 3
- static font files are 404 HOT 1
- add a donation link to readme HOT 2
- search results are not sortable HOT 3
- Add option to delete database record if status is unchanged and yaml_file is pruned HOT 1
- puppet-summary fails on CentOS 7 due to too old glibc HOT 1
- debian 11 - go install - nothing happens HOT 1
- Improve build instructions HOT 1
- How to listen on any IP address HOT 3
- systemd service file HOT 4
- Improve visibility of bars HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from puppet-summary.