Linux Operating System (MOSC)

MOSC Banner

How to enable ptrace?

edited Nov 28, 2023 3:42AM in Linux Operating System (MOSC) 1 commentAnswered

Dear community

Have you ever enabled ptrace in oracle linux?

server:

Red Hat Enterprise Linux Server release 7.9

oracle kernel 3.10.0-1160.95.1.el7.x86_64


Issue:

sysctl kernel.yama.ptrace_scope

must return 0 or 1 to be enabled, i've got 3

Everywhere I try to edit / change it to 0 is unsuccessful.


here

[root@<REMOVED> boot]# less config-3.10.0-1160.95.1.el7.x86_64 | grep -i yama

CONFIG_SECURITY_YAMA=y

CONFIG_SECURITY_YAMA_STACKED=y


or even here

[root@<REMOVED> sysctl.d]# grep -i yama *

10-kernel-hardening.conf:kernel.yama.ptrace_scope = 0

10-network-security.conf.9533.2023-02-08@09:59:45~:kernel.yama.ptrace_scope = 0

[root@<REMOVED> sysctl.d]# pwd

/etc/sysctl.d

[root@<REMOVED> sysctl.d]#

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center