minutils
Software
www.skarnet.org
The pivotchroot program
pivotchroot performs a pivot_root system call,
then changes root to the new root filesystem and executes a program.
Interface
pivotchroot newroot putold prog...
- pivotchroot sets the root filesystem to newroot,
which must be a mounted filesystem entry point. The old root filesystem
will be available under putold (relative to the old root).
- pivotchroot changes directory to the new root, performs
a chroot system call to the new root, and executes prog
with its arguments. prog is searched under the new root.
- pivotchroot exits 111 on a temporary error.