[rrd-developers] rrdcached daemonize failed, exiting
kevin brintnall
kbrint at rufus.net
Wed Sep 24 16:57:06 CEST 2008
On Wed, Sep 24, 2008 at 06:45:27AM +0200, Tobi Oetiker wrote:
>> How about this.. if a base directory is specified (-b <base>) and a command
>> comes in with an absolute <path>, then enforce:
>>
>> <path> starts with <base>/
>
> that sounds fine yes.
One problem with the current setup is that users expect to refer to a file
with relative paths. In otherwords, it's expected that these two things
do the same:
rrdtool update file.rrd N:...
rrdtool update $PWD/file.rrd N:...
However, the daemon will treat these two differently (since the key
comparison function in the daemon is strictly strcmp()).
So, I'd like to propose the following:
* the daemon ONLY accepts fully qualified paths (path[0]=='/')
* rrdc_* functions always use realpath() to convert to absolute path
before sending to daemon
* change the meaning of -b from "rrdcached will convert your paths" to
"this is the only place you can write"
I've had to be cautious to refer to files by full path in my testing.. I
think this would make things much more DWIM.
Let me know what you guys think.
--
kevin brintnall =~ /kbrint at rufus.net/
More information about the rrd-developers
mailing list