RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1425568 - systemtap task_dentry_path crashes under chroot
Summary: systemtap task_dentry_path crashes under chroot
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: systemtap
Version: 7.3
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: rc
: ---
Assignee: Frank Ch. Eigler
QA Contact: Martin Cermak
URL:
Whiteboard:
Depends On:
Blocks: 1420851
TreeView+ depends on / blocked
 
Reported: 2017-02-21 18:25 UTC by Joe Wright
Modified: 2021-06-10 11:57 UTC (History)
9 users (show)

Fixed In Version: systemtap-3.1-3.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-01 09:34:40 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2301 0 normal SHIPPED_LIVE systemtap bug fix and enhancement update 2017-08-01 12:41:08 UTC

Description Joe Wright 2017-02-21 18:25:12 UTC
Description of problem:
- Unless we're doing this wrong, if you try to resolve a path under a chrooted environment, it goes into an infinite loop that crashes the script with a MAXACTION safety check.

Version-Release number of selected component (if applicable):
- systemtap-3.0-7.el7.x86_64

How reproducible:

Reproducer - look up a process working directory:
$ sudo stap -e 'probe kprocess.exit {t=task_current(); println(task_dentry_path(t, @cast(t, "task_struct")->fs->pwd->dentry,@cast(t,"task_struct")->fs->pwd->mnt))}' -c 'perl -e "chroot(qw(/tmp))"'
ERROR: MAXACTION exceeded near identifier 'real_mount' at /usr/share/systemtap/tapset/linux/dentry.stp:158:10
WARNING: Number of errors: 1, skipped probes: 0
WARNING: /usr/bin/staprun exited with status: 1
Pass 5: run failed.  [man error::pass5]

Actual results:
- ERROR: MAXACTION exceeded near identifier 'real_mount' at /usr/share/systemtap/tapset/linux/dentry.stp:158:10

Expected results:


Additional info:

Comment 2 David Smith 2017-03-10 16:27:38 UTC
Fixed in upstream commit 6b4d1fc: 

<https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=commit;h=6b4d1fcbfa2e9706749cd549ea30df2b67716a0f>

Thanks for the great reproducer. I added it as a test case.

Comment 5 Joe Wright 2017-06-26 13:56:08 UTC
Customer has requested a test package. Is it possible to provide one?

Comment 15 Joe Wright 2017-07-06 19:45:25 UTC
Cusomter has confirmed patch addresses identified issue.

Comment 16 Frank Ch. Eigler 2017-07-06 20:04:33 UTC
Thanks for letting us know!

Comment 17 errata-xmlrpc 2017-08-01 09:34:40 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:2301


Note You need to log in before you can comment on or make changes to this bug.