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 2062681 - xml.parsers.expat.ExpatError: out of memory: line 1, column 0
Summary: xml.parsers.expat.ExpatError: out of memory: line 1, column 0
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: expat
Version: 8.6
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: Tomas Korbar
QA Contact: František Hrdina
URL:
Whiteboard:
Depends On:
Blocks: 2026666 2062765
TreeView+ depends on / blocked
 
Reported: 2022-03-10 10:56 UTC by mhou
Modified: 2022-03-16 13:12 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2062765 (view as bug list)
Environment:
Last Closed: 2022-03-16 11:17:58 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-115173 0 None None None 2022-03-10 11:01:04 UTC

Description mhou 2022-03-10 10:56:32 UTC
Description of problem:
import xml module and use parsers function got error

Version-Release number of selected component (if applicable):
kernel version: 4.18.0-367.el8.kpq0.x86_64
# rpm -qa | grep python
python3-pip-wheel-9.0.3-22.el8.noarch
python3-linux-procfs-0.7.0-1.el8.noarch
python3-gpg-1.13.1-11.el8.x86_64
python3-chardet-3.0.4-7.el8.noarch
python3-libcomps-0.1.18-1.el8.x86_64
python3-libxml2-2.9.7-13.el8.x86_64
python3-firewall-0.9.3-13.el8.noarch
python3-requests-2.20.0-2.1.el8_1.noarch
platform-python-setuptools-39.2.0-6.el8.noarch
python3-decorator-4.2.1-2.el8.noarch
python3-setuptools-wheel-39.2.0-6.el8.noarch
python3-syspurpose-1.28.28-1.el8.x86_64
python3-pyudev-0.21.0-7.el8.noarch
python3-dbus-1.2.4-15.el8.x86_64
python3-gobject-base-3.28.3-2.el8.x86_64
python3-libdnf-0.63.0-7.el8.x86_64
python3-librepo-1.14.2-1.el8.x86_64
python3-ethtool-0.14-5.el8.x86_64
python3-inotify-0.9.6-13.el8.noarch
python3-dnf-4.7.0-7.el8.noarch
python3-dnf-plugins-core-4.0.21-10.el8.noarch
python3-libselinux-2.9-5.el8.x86_64
python3-slip-dbus-0.6.4-11.el8.noarch
python3-dmidecode-3.12.2-15.el8.x86_64
python3-nftables-0.9.3-25.el8.x86_64
python3-perf-4.18.0-367.el8.kpq0.x86_64
python3-urllib3-1.24.2-5.el8.noarch
python3-cloud-what-1.28.28-1.el8.x86_64
python3-pyyaml-3.12-12.el8.x86_64
platform-python-pip-9.0.3-22.el8.noarch
python3-libs-3.6.8-45.el8.x86_64
platform-python-3.6.8-45.el8.x86_64
python3-six-1.11.0-8.el8.noarch
python3-dateutil-2.6.1-6.el8.noarch
python3-iniparse-0.4-31.el8.noarch
python3-setuptools-39.2.0-6.el8.noarch
python3-pip-9.0.3-22.el8.noarch
python3-unbound-1.7.3-17.el8.x86_64
python36-3.6.8-38.module+el8.5.0+12207+5c5719bc.x86_64
python3-hawkey-0.63.0-7.el8.x86_64
python3-rpm-4.14.3-22.el8.x86_64
python3-idna-2.5-5.el8.noarch
python3-slip-0.6.4-11.el8.noarch
python3-magic-5.33-20.el8.noarch
python3-pysocks-1.6.8-3.el8.noarch
python3-subscription-manager-rhsm-1.28.28-1.el8.x86_64



How reproducible: 100%


Steps to Reproduce:
# python3
Python 3.6.8 (default, Jan 14 2022, 11:04:20) 
[GCC 8.5.0 20210514 (Red Hat 8.5.0-7)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from xml.parsers import expat
>>> parser = expat.ParserCreate(namespace_separator=':')
>>> parser.Parse('<foo></foo>', True)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
xml.parsers.expat.ExpatError: out of memory: line 1, column 0


Actual results:
use parsers function got out of memory

Expected results:
the function can be used as well

Additional info:
upstream issue: https://github.com/libexpat/libexpat/issues/572

Comment 1 Charalampos Stratakis 2022-03-10 13:45:54 UTC
The issue needs to be fixed in the expat package.

Comment 2 mhou 2022-03-10 14:23:10 UTC
I see that tuned tool is also affected by similar issues on rhel8.6 kernel.

tuned-adm profile realtime-virtual-host
^CError: Failed to stop log capture. Restart the TuneD daemon to prevent a memory leak.
Traceback (most recent call last):
  File "/usr/sbin/tuned-adm", line 119, in <module>
    result = admin.action(action_name, **options)
  File "/usr/lib/python3.9/site-packages/tuned/admin/admin.py", line 85, in action
    res = self._controller.run()
  File "/usr/lib/python3.9/site-packages/tuned/admin/dbus_controller.py", line 68, in run
    self._main_loop.run()
  File "/usr/lib/python3.9/site-packages/gi/overrides/GLib.py", line 497, in run
    super(MainLoop, self).run()
  File "/usr/lib64/python3.9/contextlib.py", line 126, in __exit__
    next(self.gen)
  File "/usr/lib64/python3.9/site-packages/gi/_ossighelper.py", line 237, in register_sigint_fallback
    signal.default_int_handler(signal.SIGINT, None)


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