Re: [libvirt] [PATCH v2] LXC: Detect fs support. Mount only supported filesystems

2013-10-06 Thread Gao feng
On 10/07/2013 11:44 AM, Gao feng wrote: > On 10/04/2013 07:33 PM, Purcareata Bogdan-B43198 wrote: > +/* + * This function attempts to detect kernel support + * for a specific filesystem type. This is done by + * inspecting /proc/filesystems. + */ +static int lxcCheckF

Re: [libvirt] [PATCH v2] LXC: Detect fs support. Mount only supported filesystems

2013-10-06 Thread Gao feng
On 10/04/2013 07:33 PM, Purcareata Bogdan-B43198 wrote: >>> +/* >>> + * This function attempts to detect kernel support >>> + * for a specific filesystem type. This is done by >>> + * inspecting /proc/filesystems. >>> + */ >>> +static int lxcCheckFSSupport(const char *fs_type) >>> +{ >>> +FILE

Re: [libvirt] [PATCH v2] LXC: Detect fs support. Mount only supported filesystems

2013-10-04 Thread Purcareata Bogdan-B43198
> -Original Message- > From: Gao feng [mailto:gaof...@cn.fujitsu.com] > Sent: Friday, October 04, 2013 12:55 PM > To: Purcareata Bogdan-B43198 > Cc: libvir-list@redhat.com > Subject: Re: [libvirt] [PATCH v2] LXC: Detect fs support. Mount only supported > filesystems

Re: [libvirt] [PATCH v2] LXC: Detect fs support. Mount only supported filesystems

2013-10-04 Thread Gao feng
On 10/02/2013 10:05 PM, Bogdan Purcareata wrote: > Kept ((access(dstpath, R_OK) < 0) || (!lxcCheckFSSupport(mnt->type))) > when determining support for the mount. Even if the filesystem type is > supported, there is still a chance to fail when building the dstpath > (virFileMakePath). If that call

[libvirt] [PATCH v2] LXC: Detect fs support. Mount only supported filesystems

2013-10-02 Thread Bogdan Purcareata
Kept ((access(dstpath, R_OK) < 0) || (!lxcCheckFSSupport(mnt->type))) when determining support for the mount. Even if the filesystem type is supported, there is still a chance to fail when building the dstpath (virFileMakePath). If that call fails, starting the container will fail. Specifically enc