All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] selinux: umount $NEWROOT/dev and its submounts
@ 2013-06-18  5:58 WANG Chao
       [not found] ` <20130618055804.GA3612-UAAZkH0G2Ts1naxU1pY8ZxcY2uh10dtjAL8bYrjMMd8@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: WANG Chao @ 2013-06-18  5:58 UTC (permalink / raw)
  To: Harald Hoyer, Baoquan He, Dave Young; +Cc: initramfs-u79uwXL29TY76Z2rM5mHXA

$NEWROOT/dev and its submounts should be umounted after we use it.
Otherwise it fails other scripts that umount /sysroot only.

Signed-off-by: WANG Chao <chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
---
 modules.d/98selinux/selinux-loadpolicy.sh | 1 +
 1 file changed, 1 insertion(+)

diff --git a/modules.d/98selinux/selinux-loadpolicy.sh b/modules.d/98selinux/selinux-loadpolicy.sh
index 5dddfc2..436ee6b 100755
--- a/modules.d/98selinux/selinux-loadpolicy.sh
+++ b/modules.d/98selinux/selinux-loadpolicy.sh
@@ -48,6 +48,7 @@ rd_load_policy()
             [ -e "$NEWROOT"/.autorelabel ] && LANG=C /usr/sbin/setenforce 0
             mount --rbind /dev "$NEWROOT/dev"
             LANG=C chroot "$NEWROOT" /sbin/restorecon -R /dev
+            umount -R "$NEWROOT/dev"
             return 0
         fi
 
-- 
1.8.2.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] selinux: umount $NEWROOT/dev and its submounts
       [not found] ` <20130618055804.GA3612-UAAZkH0G2Ts1naxU1pY8ZxcY2uh10dtjAL8bYrjMMd8@public.gmane.org>
@ 2013-06-18  7:01   ` Harald Hoyer
  0 siblings, 0 replies; 2+ messages in thread
From: Harald Hoyer @ 2013-06-18  7:01 UTC (permalink / raw)
  To: WANG Chao; +Cc: Baoquan He, Dave Young, initramfs-u79uwXL29TY76Z2rM5mHXA

On 06/18/2013 07:58 AM, WANG Chao wrote:
> $NEWROOT/dev and its submounts should be umounted after we use it.
> Otherwise it fails other scripts that umount /sysroot only.
> 
> Signed-off-by: WANG Chao <chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
> ---
>  modules.d/98selinux/selinux-loadpolicy.sh | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/modules.d/98selinux/selinux-loadpolicy.sh b/modules.d/98selinux/selinux-loadpolicy.sh
> index 5dddfc2..436ee6b 100755
> --- a/modules.d/98selinux/selinux-loadpolicy.sh
> +++ b/modules.d/98selinux/selinux-loadpolicy.sh
> @@ -48,6 +48,7 @@ rd_load_policy()
>              [ -e "$NEWROOT"/.autorelabel ] && LANG=C /usr/sbin/setenforce 0
>              mount --rbind /dev "$NEWROOT/dev"
>              LANG=C chroot "$NEWROOT" /sbin/restorecon -R /dev
> +            umount -R "$NEWROOT/dev"
>              return 0
>          fi
>  
> 


Thanks! Pushed.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-06-18  7:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-18  5:58 [PATCH] selinux: umount $NEWROOT/dev and its submounts WANG Chao
     [not found] ` <20130618055804.GA3612-UAAZkH0G2Ts1naxU1pY8ZxcY2uh10dtjAL8bYrjMMd8@public.gmane.org>
2013-06-18  7:01   ` Harald Hoyer

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.