From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 11F363AAA008; Thu, 10 Jun 2021 07:44:55 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 11F363AAA008 From: "q1875486458 at gmail dot com" To: systemtap@sourceware.org Subject: [Bug uprobes/27975] New: could systemtap probe user process running in docker(overlay2 fs)? Date: Thu, 10 Jun 2021 07:44:54 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: uprobes X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: q1875486458 at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: systemtap@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Systemtap mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 Jun 2021 07:44:55 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D27975 Bug ID: 27975 Summary: could systemtap probe user process running in docker(overlay2 fs)? Product: systemtap Version: unspecified Status: UNCONFIRMED Severity: normal Priority: P2 Component: uprobes Assignee: systemtap at sourceware dot org Reporter: q1875486458 at gmail dot com Target Milestone: --- ## version info systemtap version: 4.0/0.176 kernel version: 3.10.0-1160.25.1.el7.x86_64 os: CentOS Linux 7 (Core) ```bash stap -V Systemtap translator/driver (version 4.0/0.176, rpm 4.0-13.el7) enabled features: AVAHI BOOST_STRING_REF DYNINST BPF JAVA PYTHON2 LIBRPM LIBSQLITE3 LIBVIRT LIBXML2 NLS NSS READLINE ``` ## what i want=20 i'm try to probe nginx(has debuginfo) which running in docker. ## what i have do since nginx running in docker,so i just find the hostpath of the nginx in docker and run=20 `stap -x 27368 -e 'probe process.syscall {printf("%s %d %s\n", execname(), pid(), pp())} probe process("/var/lib/docker/overlay2/{a-long-long-string}/merged/usr/local/ope= nresty/nginx/sbin/nginx").function("*") {printf("%s",probefunc())}'=20 `process.syscall` works find,but nginx probe just nothing happen. and=20 `stap -x 27368 -e 'probe process.syscall {printf("%s %d %s\n", execname(), pid(), pp())} probe process("/usr/local/openresty/nginx/sbin/nginx").function("*") {printf("%s",probefunc())}' --sysroot=3D/var/lib/docker/overlay2/{a-long-long-string}/merged/ `=20 report err like=20 `WARNING: probe process("/usr/local/openresty/nginx/sbin/nginx").function("ngx_write_fd@src= /os/unix/ngx_files.h:145") inode-offset 0000000000041e55 registration error (rc -22)` ## what i searched i find some says [systemtap does not support overlays/union filesystems](https://stackoverflow.com/questions/57487292/systemtap-failed-= to-probe-the-functions-registration-error) there is samiler question asked in stackoverflow,but have to meanning answer [smailer question but no answer](https://stackoverflow.com/questions/29314665/systemtapwhile-resolvi= ng-probe-point-identifier-process-at-source-probe-pro) [SystemTap_Beginners_Guide chapter 4 userspace-probing](https://www.sourceware.org/systemtap/SystemTap_Beginners= _Guide/userspace-probing.html) just say you to point the exepath of the process. ## what i want to know is that true? how should i probe user process which run in docker?=20 what should i know to fix this question? how to know what happen when uprobe just echo nothing? ## other info ```bash docker top a0bb57 UID PID PPID C=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 STIME TTY TIME CMD root 20807 20755 0=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 11:19 ? 00:00:00 /sbin/tini -- /run.sh root 20852 20807 0=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 11:19 ? 00:00:00 sh /run.sh root 27368 20807 0=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 11:20 ? 00:00:00 nginx: master process /usr/local/openresty/nginx/sbin/nginx -c /usr/local/openresty/nginx/conf/nginx.conf root 27369 27368 4=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 11:20 ? 00:10:00 nginx: worker process root 27370 27368 0=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 11:20 ? 00:01:46 nginx: worker process ``` i have copy /lib/modules/3.10.0-1160.25.1.el7.x86_64/ to /var/lib/docker/overlay2/{a-long-long-string}/merged/ --=20 You are receiving this mail because: You are the assignee for the bug.=