proot 5.1.0\u003a chroot\u002c mount --bind\u002c and binfmt_misc without privilege\u002fsetup.\n\nUsage\u003a\n proot [option] ... [command]\n\n\nRegular options\u003a\n -r path\u002c --rootfs\u003dpath\n Use path as the new guest root file-system\u002c default is \u002f.\n\n The specified path typically contains a Linux distribution where\n all new programs will be confined. The default rootfs is \u002f\n when none is specified\u002c this makes sense when the bind mechanism\n is used to relocate host files and directories\u002c see the -b\n option and the Examples section for details.\n\n It is recommended to use the -R or -S options instead.\n\n -b path\u002c --bind\u003dpath\u002c -m path\u002c --mount\u003dpath\n Make the content of path accessible in the guest rootfs.\n\n This option makes any file or directory of the host rootfs\n accessible in the confined environment just as if it were part of\n the guest rootfs. By default the host path is bound to the same\n path in the guest rootfs but users can specify any other location\n with the syntax\u003a -b host_path\u003aguest_location. If the\n guest location is a symbolic link\u002c it is dereferenced to ensure\n the new content is accessible through all the symbolic links that\n point to the overlaid content. In most cases this default\n behavior shouldn't be a problem\u002c although it is possible to\n explicitly not dereference the guest location by appending it the\n ! character\u003a -b host_path\u003aguest_location!.\n\n -q command\u002c --qemu\u003dcommand\n Execute guest programs through QEMU as specified by command.\n\n Each time a guest program is going to be executed\u002c PRoot inserts\n the QEMU user-mode command in front of the initial request.\n That way\u002c guest programs actually run on a virtual guest CPU\n emulated by QEMU user-mode. The native execution of host programs\n is still effective and the whole host rootfs is bound to\n \u002fhost-rootfs in the guest environment.\n\n -w path\u002c --pwd\u003dpath\u002c --cwd\u003dpath\n Set the initial working directory to path.\n\n Some programs expect to be launched from a given directory but do\n not perform any chdir by themselves. This option avoids the\n need for running a shell and then entering the directory manually.\n\n --kill-on-exit\n Kill all processes on command exit.\n\n When the executed command leaves orphean or detached processes\n around\u002c proot waits until all processes possibly terminate. This option forces\n the immediate termination of all tracee processes when the main command exits.\n\n -v value\u002c --verbose\u003dvalue\n Set the level of debug information to value.\n\n The higher the integer value is\u002c the more detailed debug\n information is printed to the standard error stream. A negative\n value makes PRoot quiet except on fatal errors.\n\n -V\u002c --version\u002c --about\n Print version\u002c copyright\u002c license and contact\u002c then exit.\n\n -h\u002c --help\u002c --usage\n Print the version and the command-line usage\u002c then exit.\n\n\nExtension options\u003a\n -k string\u002c --kernel-release\u003dstring\n Make current kernel appear as kernel release string.\n\n If a program is run on a kernel older than the one expected by its\n GNU C library\u002c the following error is reported\u003a "FATAL\u003a kernel too\n old". To be able to run such programs\u002c PRoot can emulate some of\n the features that are available in the kernel release specified by\n string but that are missing in the current kernel.\n\n -0\u002c --root-id\n Make current user appear as "root" and fake its privileges.\n\n Some programs will refuse to work if they are not run with "root"\n privileges\u002c even if there is no technical reason for that. This\n is typically the case with package managers. This option allows\n users to bypass this kind of limitation by faking the user\u002fgroup\n identity\u002c and by faking the success of some operations like\n changing the ownership of files\u002c changing the root directory to\n \u002f\u002c ... Note that this option is quite limited compared to\n fakeroot.\n\n -i string\u002c --change-id\u003dstring\n Make current user and group appear as string "uid\u003agid".\n\n This option makes the current user and group appear as uid and\n gid. Likewise\u002c files actually owned by the current user and\n group appear as if they were owned by uid and gid instead.\n Note that the -0 option is the same as -i 0\u003a0.\n\n --link2symlink\u002c -l\n Replace hard links with symlinks\u002c pretending they are really hardlinks\n\n Emulates hard links with symbolic links when SELinux policies\n do not allow hard links.\n\n --sysvipc\n Handle System V IPC syscalls in proot\n\n Handles System V IPC syscalls (shmget\u002c semget\u002c msgget\u002c etc.)\n syscalls inside proot. IPC is handled inside proot and launching 2 proot instances\n will lead to 2 different IPC Namespaces\n\n --ashmem-memfd\n Emulate memfd_create support through ashmem and simulate fstat.st_size for ashmem\n\n -H\n Hide files and directories starting with '.proot.' .\n\n -p\n Modify bindings to protected ports to use a higher port number.\n\n -L\n Correct the size returned from lstat for symbolic links.\n\n\nAlias options\u003a\n -R path\n Alias\u003a -r path + a couple of recommended -b.\n\n Programs isolated in path\u002c a guest rootfs\u002c might still need to\n access information about the host system\u002c as it is illustrated in\n the Examples section of the manual. These host information\n are typically\u003a user\u002fgroup definition\u002c network setup\u002c run-time\n information\u002c users' files\u002c ... On all Linux distributions\u002c they\n all lie in a couple of host files and directories that are\n automatically bound by this option\u003a\n\n * \u002fetc\u002fhost.conf\n * \u002fetc\u002fhosts\n * \u002fetc\u002fhosts.equiv\n * \u002fetc\u002fmtab\n * \u002fetc\u002fnetgroup\n * \u002fetc\u002fnetworks\n * \u002fetc\u002fpasswd\n * \u002fetc\u002fgroup\n * \u002fetc\u002fnsswitch.conf\n * \u002fetc\u002fresolv.conf\n * \u002fetc\u002flocaltime\n * \u002fdev\u002f\n * \u002fsys\u002f\n * \u002fproc\u002f\n * \u002ftmp\u002f\n * \u002frun\u002f\n * \u002fvar\u002frun\u002fdbus\u002fsystem_bus_socket\n * $HOME\n\n -S path\n Alias\u003a -0 -r path + a couple of recommended -b.\n\n This option is useful to safely create and install packages into\n the guest rootfs. It is similar to the -R option expect it\n enables the -0 option and binds only the following minimal set\n of paths to avoid unexpected changes on host files\u003a\n\n * \u002fetc\u002fhost.conf\n * \u002fetc\u002fhosts\n * \u002fetc\u002fnsswitch.conf\n * \u002fetc\u002fresolv.conf\n * \u002fdev\u002f\n * \u002fsys\u002f\n * \u002fproc\u002f\n * \u002ftmp\u002f\n * \u002frun\u002fshm\n * $HOME\n\nVisit http\u003a\u002f\u002fproot.me for help\u002c bug reports\u002c suggestions\u002c patchs\u002c ...\nCopyright (C) 2015 STMicroelectronics\u002c licensed under GPL v2 or later.

proot 5.1.0: 无需特权或设置即可使用 chroot、mount --bind 和 binfmt_misc 的工具