- From: Jesse Nelson <
>
- To: Chef Dev <
>
- Subject: [chef-dev] Looking for feedback on Inotify hack
- Date: Mon, 26 Nov 2012 14:50:28 +0900
Hello chefs,
I wrote this quick hack a while back as a proof of concept that hooks chefs file/template resources to register an Inotify watch[1].
Caveat: This code is not prod worthy don't run it anywhere except for something that you feel fine breaking :)
The intent was just to see what overhead all the chef file stats and checks were, and weather I could make the system use a notification system for on disk changes vs poll.
The implementation is only 1/2 complete. I am not hooking the chef-server side of reporting a change. Which is where I would like some feedback on how to go about doing this? I was looking into the checksum generation and such. I am wondering if theres a way I can get the list of files that were modified in a cookbook from the server in the normal run ?. Ideally this would then trigger the flag that the watch was dirty, and causes chef to run the full file converge. Also just looking for any feed back in general int weather this is insane or useful. I didn't have a need for it. Just had some curiosity about weather it could be hacked into chef easy or not.
On a test node where I ran this with 10k false files my runtime was reduced from 10s to < 2s on runs where no change was taken. (this was a contrived test with a loop around a file resource with some content).
Thanks,
Jesse Nelson
- [chef-dev] Looking for feedback on Inotify hack, Jesse Nelson, 11/25/2012
Archive powered by MHonArc 2.6.16.