Comment 9 for bug 930430

Revision history for this message
Serge Hallyn (serge-hallyn) wrote : Re: [Bug 930430] Re: lxc-ls requires root access after deploying an LXC instance

Quoting Kapil Thangavelu (<email address hidden>):
> I've just noticed this with some of the unit tests, afaik this is some
> change in lxc behavior.

I don't think it's a change in lxc behavior. I think it's a change in
the umask which juju has set when it calls lxc-start.

lxc passes a requested mode to mkdir(2), which then &s that with the
umask.

Ideally juju would set umask correctly. There are two ways lxc could
help, but they're not particularly palatable.

It could second-guess the caller and hand-set umask before calling
mkdir. I think that's Wrong.

It could check umask and spit out an error if it is too restrictive.
That will help users find the cause more quickly, but doesn't solve
the bug.