Linux-man Archive on lore.kernel.org
 help / color / Atom feed
* Re: pivot_root.2: new_root must be a mountpoint
       [not found] <20190919053801.bwqWTilN@vla3-2bcfd5e94671.qloud-c.yandex.net>
@ 2019-09-19  6:34 ` Michael Kerrisk (man-pages)
  0 siblings, 0 replies; only message in thread
From: Michael Kerrisk (man-pages) @ 2019-09-19  6:34 UTC (permalink / raw)
  To: Yang Bo; +Cc: mtk.manpages, linux-man

Hello Yang Bo,

On 9/19/19 4:38 AM, Yang Bo wrote:
> The man page says that new_root does not have be a mountpoint
> but it must be, I tried to pivot_root into a non-mountpoint
> directory and always failed with EINVAL, the kernel source
> fs/namespace.c confirms that, to quote a comment from this file:
> 
> - it's okay to pick a root that isn't the root of a file system, e.g.
> - /nfs/my_root where /nfs is the mount point. It must be a mountpoint,
> - though, so you may need to say mount --bind /nfs/my_root /nfs/my_root
> - first.

Yes, you are correct. There are in fact many problems in the
current pivot_root(2) page, and I am in the process of 
substantially revising it.

Thanks

Michael


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, back to index

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20190919053801.bwqWTilN@vla3-2bcfd5e94671.qloud-c.yandex.net>
2019-09-19  6:34 ` pivot_root.2: new_root must be a mountpoint Michael Kerrisk (man-pages)

Linux-man Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-man/0 linux-man/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-man linux-man/ https://lore.kernel.org/linux-man \
		linux-man@vger.kernel.org
	public-inbox-index linux-man

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-man


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git