mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-06 20:00:05 +00:00
Revert "Change label of fusefs mounted at /proc/meminfo in lxc containers"
This reverts commit 940c6f1085c3aafced51152b17a044af8c42b16e.
This commit is contained in:
parent
a2619bb1ff
commit
7bebd88871
@ -52,10 +52,6 @@
|
||||
# include <blkid/blkid.h>
|
||||
#endif
|
||||
|
||||
#if WITH_SELINUX
|
||||
# include <selinux/selinux.h>
|
||||
#endif
|
||||
|
||||
#include "virerror.h"
|
||||
#include "virlog.h"
|
||||
#include "lxc_container.h"
|
||||
@ -769,26 +765,6 @@ static int lxcContainerMountProcFuse(virDomainDefPtr def,
|
||||
def->name)) < 0)
|
||||
return ret;
|
||||
|
||||
# if WITH_SELINUX
|
||||
if (is_selinux_enabled() > 0) {
|
||||
security_context_t scon;
|
||||
ret = getfilecon("/proc/meminfo", &scon);
|
||||
if (ret < 0) {
|
||||
virReportSystemError(errno,
|
||||
_("Failed to get security context of %s for /proc/meminfo mount point"),
|
||||
meminfo_path);
|
||||
return ret;
|
||||
}
|
||||
ret = setfilecon(meminfo_path, scon);
|
||||
freecon(scon);
|
||||
if (ret < 0) {
|
||||
virReportSystemError(errno,
|
||||
_("Failed to set security context of %s for /proc/meminfo mount point"),
|
||||
meminfo_path);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
# endif
|
||||
if ((ret = mount(meminfo_path, "/proc/meminfo",
|
||||
NULL, MS_BIND, NULL)) < 0) {
|
||||
virReportSystemError(errno,
|
||||
|
Loading…
x
Reference in New Issue
Block a user