Путеводитель по Руководству Linux

  User  |  Syst  |  Libr  |  Device  |  Files  |  Other  |  Admin  |  Head  |



   prctl    ( 2 )

операции над процессом или потоком (operations on a process or thread)

  Name  |  Synopsis  |  Description  |  Return value  |    Error    |  Versions  |  Conforming to  |  See also  |

Ошибки (Error)

EACCES option is PR_SET_SECCOMP and arg2 is SECCOMP_MODE_FILTER, but the process does not have the CAP_SYS_ADMIN capability or has not set the no_new_privs attribute (see the discussion of PR_SET_NO_NEW_PRIVS above).

EACCES option is PR_SET_MM, and arg3 is PR_SET_MM_EXE_FILE, the file is not executable.

EBADF option is PR_SET_MM, arg3 is PR_SET_MM_EXE_FILE, and the file descriptor passed in arg4 is not valid.

EBUSY option is PR_SET_MM, arg3 is PR_SET_MM_EXE_FILE, and this the second attempt to change the /proc/pid/exe symbolic link, which is prohibited.

EFAULT arg2 is an invalid address.

EFAULT option is PR_SET_SECCOMP, arg2 is SECCOMP_MODE_FILTER, the system was built with CONFIG_SECCOMP_FILTER, and arg3 is an invalid address.

EFAULT option is PR_SET_SYSCALL_USER_DISPATCH and arg5 has an invalid address.

EINVAL The value of option is not recognized, or not supported on this system.

EINVAL option is PR_MCE_KILL or PR_MCE_KILL_GET or PR_SET_MM, and unused prctl() arguments were not specified as zero.

EINVAL arg2 is not valid value for this option.

EINVAL option is PR_SET_SECCOMP or PR_GET_SECCOMP, and the kernel was not configured with CONFIG_SECCOMP.

EINVAL option is PR_SET_SECCOMP, arg2 is SECCOMP_MODE_FILTER, and the kernel was not configured with CONFIG_SECCOMP_FILTER.

EINVAL option is PR_SET_MM, and one of the following is true

* arg4 or arg5 is nonzero;

* arg3 is greater than TASK_SIZE (the limit on the size of the user address space for this architecture);

* arg2 is PR_SET_MM_START_CODE, PR_SET_MM_END_CODE, PR_SET_MM_START_DATA, PR_SET_MM_END_DATA, or PR_SET_MM_START_STACK, and the permissions of the corresponding memory area are not as required;

* arg2 is PR_SET_MM_START_BRK or PR_SET_MM_BRK, and arg3 is less than or equal to the end of the data segment or specifies a value that would cause the RLIMIT_DATA resource limit to be exceeded.

EINVAL option is PR_SET_PTRACER and arg2 is not 0, PR_SET_PTRACER_ANY, or the PID of an existing process.

EINVAL option is PR_SET_PDEATHSIG and arg2 is not a valid signal number.

EINVAL option is PR_SET_DUMPABLE and arg2 is neither SUID_DUMP_DISABLE nor SUID_DUMP_USER.

EINVAL option is PR_SET_TIMING and arg2 is not PR_TIMING_STATISTICAL.

EINVAL option is PR_SET_NO_NEW_PRIVS and arg2 is not equal to 1 or arg3, arg4, or arg5 is nonzero.

EINVAL option is PR_GET_NO_NEW_PRIVS and arg2, arg3, arg4, or arg5 is nonzero.

EINVAL option is PR_SET_THP_DISABLE and arg3, arg4, or arg5 is nonzero.

EINVAL option is PR_GET_THP_DISABLE and arg2, arg3, arg4, or arg5 is nonzero.

EINVAL option is PR_CAP_AMBIENT and an unused argument (arg4, arg5, or, in the case of PR_CAP_AMBIENT_CLEAR_ALL, arg3) is nonzero; or arg2 has an invalid value; or arg2 is PR_CAP_AMBIENT_LOWER, PR_CAP_AMBIENT_RAISE, or PR_CAP_AMBIENT_IS_SET and arg3 does not specify a valid capability.

EINVAL option was PR_GET_SPECULATION_CTRL or PR_SET_SPECULATION_CTRL and unused arguments to prctl() are not 0. EINVAL option is PR_PAC_RESET_KEYS and the arguments are invalid or unsupported. See the description of PR_PAC_RESET_KEYS above for details.

EINVAL option is PR_SVE_SET_VL and the arguments are invalid or unsupported, or SVE is not available on this platform. See the description of PR_SVE_SET_VL above for details.

EINVAL option is PR_SVE_GET_VL and SVE is not available on this platform.

EINVAL option is PR_SET_SYSCALL_USER_DISPATCH and one of the following is true:

* arg2 is PR_SYS_DISPATCH_OFF and the remaining arguments are not 0;

* arg2 is PR_SYS_DISPATCH_ON and the memory range specified is outside the address space of the process.

* arg2 is invalid.

EINVAL option is PR_SET_TAGGED_ADDR_CTRL and the arguments are invalid or unsupported. See the description of PR_SET_TAGGED_ADDR_CTRL above for details.

EINVAL option is PR_GET_TAGGED_ADDR_CTRL and the arguments are invalid or unsupported. See the description of PR_GET_TAGGED_ADDR_CTRL above for details.

ENODEV option was PR_SET_SPECULATION_CTRL the kernel or CPU does not support the requested speculation misfeature.

ENXIO option was PR_MPX_ENABLE_MANAGEMENT or PR_MPX_DISABLE_MANAGEMENT and the kernel or the CPU does not support MPX management. Check that the kernel and processor have MPX support.

ENXIO option was PR_SET_SPECULATION_CTRL implies that the control of the selected speculation misfeature is not possible. See PR_GET_SPECULATION_CTRL for the bit fields to determine which option is available.

EOPNOTSUPP option is PR_SET_FP_MODE and arg2 has an invalid or unsupported value.

EPERM option is PR_SET_SECUREBITS, and the caller does not have the CAP_SETPCAP capability, or tried to unset a "locked" flag, or tried to set a flag whose corresponding locked flag was set (see capabilities(7)).

EPERM option is PR_SET_SPECULATION_CTRL wherein the speculation was disabled with PR_SPEC_FORCE_DISABLE and caller tried to enable it again.

EPERM option is PR_SET_KEEPCAPS, and the caller's SECBIT_KEEP_CAPS_LOCKED flag is set (see capabilities(7)).

EPERM option is PR_CAPBSET_DROP, and the caller does not have the CAP_SETPCAP capability.

EPERM option is PR_SET_MM, and the caller does not have the CAP_SYS_RESOURCE capability.

EPERM option is PR_CAP_AMBIENT and arg2 is PR_CAP_AMBIENT_RAISE, but either the capability specified in arg3 is not present in the process's permitted and inheritable capability sets, or the PR_CAP_AMBIENT_LOWER securebit has been set.

ERANGE option was PR_SET_SPECULATION_CTRL and arg3 is not PR_SPEC_ENABLE, PR_SPEC_DISABLE, PR_SPEC_FORCE_DISABLE, nor PR_SPEC_DISABLE_NOEXEC.