On 16.2.2010 21:44, Brian K. White wrote:
Hi,
Hi Brian, please use the opensuse-kernel mailing list (an pick a better subject next time...). I also added Jiri, who maintains the lxc package in Factory.
cgroup support is missing from the desktop kernel. Is this intentional or accidental?
Intentional, see https://features.opensuse.org/305694 and http://gitorious.org/opensuse/kernel-source/commit/c065c52q1 .
It breaks LXC which requires it. All other LXC options are enabled in the desktop kernel but the one can't work without the other so you might as well turn the other lxc options off also, or turn cgroup on.
BTW, which are these options?
I'm checking now to see if the previous desktop kernel had cgroup or not. I don't remember seeing this problem before, but I have only started using lxc since 11.2 and I normally override the default and install the now mis-named "default" kernel anyways so I don't know maybe this has always been the case and maybe I only just now noticed.
That said, regardless if the desktop kernel is intended or not, or continues or not, to to include cgroup support, since there are packages that depend on the feature, and there is no file I know of that can be checked for in a spec file Requires: field, I think there should be a flag in the spec/rpm files for the kernels that says they provide the feature or not, so that other packages can say "Requires: cgroup" and they don't care which specific kernel you install, merely that you are running a kernel that includes the facility. There are ways to check the running kernel of course like "grep cgroup /proc/filesystems" but I don't think a spec file can be told to run a test like that as part of the "requires:" field. Maybe %pre or %prein are the place for a test like that? But putting a dependency in Requires: ensures that even when the user goes to install some other kernel later after lxc is already installed, if the new kernel is not also "kernel-default" rpm will notice and try to either prevent the install or remove lxc along with the old kernel to maintain a consistent system.
The problem with userspace packages depending on certain kernel features or versions is that it doesn't really do what you want. You can express a dependency on an installed package, but what really matters is the running kernel, which rpm can't test for. Also if you depend on a certain kernel flavor (or some virtual capability provided by some flavors), the effect would be that the installer would install the desired kernel flavor _alongside_ with the "wrong" flavor, because different kernel flavors don't conflict with each other. Just something to keep in mind.
Currently for my own updated lxc package in build service home:aljex, I am specifying "Requires: kernel-default" which is wrong but ensures that lxc will work. And then I am also performing the /proc/filesystems check at run-time in my lxc init script just to be sure.
Thanks
Michal -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-kernel+help@opensuse.org