Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1339609

Summary: Multiple unhandled syscalls when running systemd under valgrind in nspawn on ppc64[le]
Product: Red Hat Enterprise Linux 7 Reporter: Frantisek Sumsal <fsumsal>
Component: valgrindAssignee: Mark Wielaard <mjw>
Status: CLOSED ERRATA QA Contact: Miloš Prchlík <mprchlik>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.2CC: bblaskov, jakub, mbenitez, mcermak, mprchlik, ohudlick
Target Milestone: rc   
Target Release: ---   
Hardware: ppc64   
OS: Unspecified   
Whiteboard:
Fixed In Version: valgrind-3.11.0-22.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1339628 (view as bug list) Environment:
Last Closed: 2016-11-04 02:56:21 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Valgrind log from ppc64 machine
none
Valgrind log from ppc64le machine none

Description Frantisek Sumsal 2016-05-25 12:41:54 UTC
Created attachment 1161402 [details]
Valgrind log from ppc64 machine

Description of problem:
When running systemd under valgrind in nspawn container, on some architectures (ppc64, ppc64 and aarch64) boot process ends with an error due to unhandled syscalls. Running systemd without valgrind works as expected.

Version-Release number of selected component (if applicable):
valgrind-3.10.0-16.el7.ppc64

How reproducible:
## Create a minimal nspawn container
# mkdir vm
# yum -y --nogpgcheck --installroot $PWD/vm groupinstall minimal
# cp -f /etc/yum.repos.d/* vm/etc/yum.repos.d/
# yum -y --nogpgcheck --installroot $PWD/vm install valgrind
## Run systemd under valgrind in nspawn container
# systemd-nspawn -D vm/ valgrind --leak-check=full --log-file=valgrind.log /usr/lib/systemd/systemd

Actual results:
Boot process ends with an error:
Failed to enable ctrl-alt-del handling: Function not implemented
Failed to wait for system-generators: Function not implemented
...
Failed to run main loop: Function not implemented
[!!!!!!] Failed to run main loop, freezing.

Expected results:
Container should boot successfully as tested on x86_64 and s390x architectures.

Additional info:
Valgrind log with unhandled syscalls is included in the attachment.

Comment 2 Frantisek Sumsal 2016-05-25 13:05:03 UTC
Created attachment 1161419 [details]
Valgrind log from ppc64le machine

The second 'ppc64' in my previous comment should be 'ppc64le'.

Comment 3 Mark Wielaard 2016-05-25 13:07:36 UTC
The specific ppc64 syscalls mentioned in the attachment are:

WARNING: unhandled syscall: 272 (waitid)
WARNING: unhandled syscall: 345 (name_to_handle_at)
WARNING: unhandled syscall: 359 (getrandom)
WARNING: unhandled syscall: 36  (sync)
WARNING: unhandled syscall: 88  (reboot)

All are indeed not implemented for ppc64 valgrind upstream.
Except for reboot they seem to have been implemented for other arches. So making them (except reboot) work for ppc64 should not be too hard.

Could you open a different bug for aarch64? With a similar log attached?
ppc64/ppc64le are mostly similar, but aarch64 really should have its own bug report.

Comment 4 Frantisek Sumsal 2016-05-25 13:12:30 UTC
Definitely. I'm preparing an aarch64 test machine right now, so I'll create a separate bug report when I get valgrind's log.

Comment 5 Mark Wielaard 2016-05-30 20:18:30 UTC
Missing syscalls added for ppc64 in upstream valgrind svn r15888.

Comment 9 Miloš Prchlík 2016-06-08 11:56:23 UTC
Verified for build valgrind-3.11.0-22.el7.

Comment 11 errata-xmlrpc 2016-11-04 02:56:21 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://rhn.redhat.com/errata/RHEA-2016-2297.html