Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

445
Vistas
gdb in docker container returns "ptrace: Operation not permitted."

I've checked /proc/sys/kernel/yama/ptrace_scope in the container and on the host - both report the value as zero but when attached to pid one gdb reports

Reading symbols from /opt/my-web-proxy/bin/my-web-proxy...done.
Attaching to program: /opt/my-web-proxy/bin/my-web-proxy, process 1
ptrace: Operation not permitted.

I've also tried attached to the container with the privileged flag

docker exec --privileged -it mywebproxy_my-proxy_1 /bin/bash

Host OS is Fedora 25 with docker from their repos and container is a official centos6.8

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

I discovered the answer - the container needs to be started with strace capabilities

Adding this to my docker-compose.yml file allows GDB to work

cap_add:
    - SYS_PTRACE

Or it can also be passed on the docker command line with --cap-add=SYS_PTRACE

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda