https://ibmimedia.com/blog/64/solve-strace-operation-not-permitted-error
Strace Operation not permitted error occurs if the current user doesn't have enough permissions to trace a running process. Also, if strace is already running then it will throw this error.
Allow users to strace other processes with the same uid To do so, it requires a root-level change (aka: a root level admin needs to change this). If you change kernel. yama. ptrace_scope to 0 and reboot the system, you'll now be allowed to strace processes of your own uid.