From: Charles Duffy Date: Thu, 4 Jun 2009 07:45:04 +0000 (+0100) Subject: Use --rbind rather than --bind for bind mounting /dev (to get /dev/pts). X-Git-Tag: 1.0.39~2 X-Git-Url: http://git.annexia.org/?a=commitdiff_plain;h=80e15757879c4cf21e0511c62e57c19efb4aab63;p=libguestfs.git Use --rbind rather than --bind for bind mounting /dev (to get /dev/pts). --- diff --git a/daemon/command.c b/daemon/command.c index 1a50264..1a9bebb 100644 --- a/daemon/command.c +++ b/daemon/command.c @@ -53,11 +53,11 @@ do_command (char * const * const argv) * We deliberately allow these commands to fail silently, BUT * if a mount fails, don't unmount the corresponding mount. */ - r = command (NULL, NULL, "mount", "--bind", "/dev", "/sysroot/dev", NULL); + r = command (NULL, NULL, "mount", "--rbind", "/dev", "/sysroot/dev", NULL); dev_ok = r != -1; - r = command (NULL, NULL, "mount", "--bind", "/proc", "/sysroot/proc", NULL); + r = command (NULL, NULL, "mount", "--rbind", "/proc", "/sysroot/proc", NULL); proc_ok = r != -1; - r = command (NULL, NULL, "mount", "--bind", "/sys", "/sysroot/sys", NULL); + r = command (NULL, NULL, "mount", "--rbind", "/sys", "/sysroot/sys", NULL); sys_ok = r != -1; CHROOT_IN;