[3/3] libvzctl-4.14: do not mount sysfs in container

Submitted by Stanislav Kinsburskiy on Jan. 10, 2018, 4:15 p.m.

Details

Message ID 20180110161535.12838.74807.stgit@skinsbursky-vz7.qa.sw.ru
State New
Series "libvzctl: a set a patches to make CT running on 4.14 kernel"
Headers show

Commit Message

Stanislav Kinsburskiy Jan. 10, 2018, 4:15 p.m.
Our current approach is to use one sysfs mount for all the containers, but set
limited visibility to sysfs dentries in a container.

Signed-off-by: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
---
 lib/env.c |    3 ---
 1 file changed, 3 deletions(-)

Patch hide | download patch | download mbox

diff --git a/lib/env.c b/lib/env.c
index 1b03ce4..a284ec9 100644
--- a/lib/env.c
+++ b/lib/env.c
@@ -772,9 +772,6 @@  int pre_setup_env(const struct start_param *param)
 	if (setup_devtmpfs())
 		return VZCTL_E_SYSTEM;
 
-	if (stat_file("/sys"))
-		mount("sysfs", "/sys", "sysfs", 0, 0);
-
 	if (env->features->mask & VE_FEATURE_NFSD) {
 		mount("nfsd", "/proc/fs/nfsd", "nfsd", 0, 0);
 		make_dir("/var/lib/nfs/rpc_pipefs", 1);