[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [PATCH 0/2] rework virFileCreate into virFileOperation w/hook function



(This patchset requires that the virFork() patchset I send a couple
hours ago be applied first, otherwise it will fail to apply).

virFileCreate just didn't have what it takes to get the job done. It
turns out that there are other things that must be done to files as the
qemu (or whatever) user, so this patchset adds a hook function that
gets called during the child process. That solves a problem I found
with creating raw storage volumes on root-squash NFS, and will also be
used for an upcoming domain-save-on-root-squash-nfs patch.

I'm now beginning to think that virFileCreate/virFileOperation is just
too narrow in scope, and it's getting too many options. Possibly it
will be better to just make a simpler virCallasUID() function that
gets a pointer to a function to execute in the child process as an
argument and does nothing but fork/setuid/call the function. That
function would then contain *all* of the file operations,
including creating/opening/closing the file. But that's too large of a
change to contemplate so soon before a release, and this functionality
is necessary for two important bug fixes (mentioned above), so...


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]