Subject: Re: [vserver] Unable to set vshelper 3.18
From: Corey Wright <undefined@pobox.com>
Date: Tue, 3 Feb 2015 10:45:52 -0600
Tue, 3 Feb 2015 10:45:52 -0600
On Tue, 3 Feb 2015 07:49:28 -0600
Corey Wright <undefined@pobox.com> wrote:

> On Tue, 3 Feb 2015 07:33:34 -0600
> Corey Wright <undefined@pobox.com> wrote:
> 
> > On Sun, 01 Feb 2015 15:36:33 +0100
> > Oliver Welter <mail@oliwel.de> wrote:
> > 
> > > Hi Bertl,
> > > 
> > > with the 3.18 patch I dont have a node /proc/sys/kernel/vshelper and the
> > > vserver scripts complain about that.
> > 
> > see attached patch.
> 
> forget that patch.

see attached patch.

take 2, now with testing! ;)

this patch is modeled after 3.14's linux-vserver patch where vshelper is
patched in between uevent_helper and sg-big-buff entires in kern_table[].

sorry for the delay, but i had to work out the initrd error about no
permission to write to /sys/kernel/uevent_helper (ie wheezy's udev still
requires CONFIG_UEVENT_HELPER=y, though turned-off in debian's 3.18 config in
experimental).

corey
--
undefined@pobox.com

> that patch moved the vshelper array entry out of the CONFIG_COMPACTION
> preprocessor conditional but not out of the vm_table array and into
> kern_table array (to it appears under /sys/kernel and not /sys/vm).
> 
> new patch coming up (unless herbert beats me to it).
> 
> corey
> --
> undefined@pobox.com
> 
> > thanks to AlexanderS on irc for his comment that tipped me off to where the
> > problem was (which was probably a bit faster than grepping for vshelper).
> > 
> > haven't run-time tested it (been busy debugging why lxc-start mounts
> > filesystems in a container on a non-vserver kernel but not on a vserver
> > kernel, though root can do it without problem within the container), but it
> > compiles.
> > 
> > corey
> > --
> > undefined@pobox.com
> > 
> > > There is I good chance that I missed something during setting up the
> > > test system, any ideas? If that matters - I used 3.18.5 instead of
> > > 3.18.4 as base.
> > > 
> > > Oli
> > > -- 
> > > Protect your environment -  close windows and adopt a penguin!





diff -urNpd linux-3.18.5-vs2.3.7.1.orig/kernel/sysctl.c linux-3.18.5-vs2.3.7.1/kernel/sysctl.c
--- linux-3.18.5-vs2.3.7.1.orig/kernel/sysctl.c	2015-01-30 13:33:10.000000000 -0600
+++ linux-3.18.5-vs2.3.7.1/kernel/sysctl.c	2015-02-03 07:51:03.000000000 -0600
@@ -665,6 +665,13 @@ static struct ctl_table kern_table[] = {
 		.proc_handler	= proc_dostring,
 	},
 #endif
+	{
+		.procname	= "vshelper",
+		.data		= &vshelper_path,
+		.maxlen		= 256,
+		.mode		= 0644,
+		.proc_handler	= &proc_dostring,
+	},
 #ifdef CONFIG_CHR_DEV_SG
 	{
 		.procname	= "sg-big-buff",
@@ -1301,13 +1308,6 @@ static struct ctl_table vm_table[] = {
 		.extra1		= &min_extfrag_threshold,
 		.extra2		= &max_extfrag_threshold,
 	},
-	{
-		.procname	= "vshelper",
-		.data		= &vshelper_path,
-		.maxlen		= 256,
-		.mode		= 0644,
-		.proc_handler	= &proc_dostring,
-	},
 
 #endif /* CONFIG_COMPACTION */
 	{