Show application performance/errors from pseudo file
Daniel Hilst Selli <[email protected]> Thu, 16 Oct 2014 16:50:04 -0300
| Newsgroups | org.kernel.vger.linux-c-programming |
|---|---|
| Message-ID | <[email protected]> |
I'm writing a new application and would be nice to have a pseudo file showing its status, just the way that procfs does with kernel. I'm looking for sugestions, I want to `cat' files contents and have something similar to /proc/meminfo First I think using named pipes, but, AFAIK, pipes would retain data writed until someone read it, what I thought is a kind of read hook that only show data when asked for. Here are a few requisites, - Don't retain data - Don't generate disk I/O - Vanish when application stops - Work with a simple cat or something similar.. With that in mind I think about using unix domain sockets.. it seems to fit all requisites, for the fourth requisite I could use netcat, that is almost cat, Cheers