How To Install libpfm-python.x86_64 on Amazon Linux 2

In this tutorial we learn how to install libpfm-python.x86_64 in Amazon Linux 2. libpfm-python.x86_64 is Python bindings for libpfm and perf_event_open system call

Introduction

In this tutorial we learn how to install libpfm-python.x86_64 on Amazon Linux 2.

What is libpfm-python.x86_64

Python bindings for libpfm4 and perf_event_open system call.

We can use yum to install libpfm-python.x86_64 on Amazon Linux 2. In this tutorial we discuss both methods but you only need to choose one of method to install libpfm-python.x86_64.

Install libpfm-python.x86_64 on Amazon Linux 2 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install libpfm-python.x86_64 using yum by running the following command:

sudo yum -y install libpfm-python.x86_64

How To Uninstall libpfm-python.x86_64 on Amazon Linux 2

To uninstall only the libpfm-python.x86_64 package we can use the following command:

sudo yum remove libpfm-python.x86_64

libpfm-python.x86_64 Package Contents on Amazon Linux 2

/usr/lib64/python2.7/site-packages/perfmon
/usr/lib64/python2.7/site-packages/perfmon-4.0-py2.7.egg-info
/usr/lib64/python2.7/site-packages/perfmon/__init__.py
/usr/lib64/python2.7/site-packages/perfmon/__init__.pyc
/usr/lib64/python2.7/site-packages/perfmon/__init__.pyo
/usr/lib64/python2.7/site-packages/perfmon/_perfmon_int.so
/usr/lib64/python2.7/site-packages/perfmon/perfmon_int.py
/usr/lib64/python2.7/site-packages/perfmon/perfmon_int.pyc
/usr/lib64/python2.7/site-packages/perfmon/perfmon_int.pyo
/usr/lib64/python2.7/site-packages/perfmon/pmu.py
/usr/lib64/python2.7/site-packages/perfmon/pmu.pyc
/usr/lib64/python2.7/site-packages/perfmon/pmu.pyo
/usr/lib64/python2.7/site-packages/perfmon/session.py
/usr/lib64/python2.7/site-packages/perfmon/session.pyc
/usr/lib64/python2.7/site-packages/perfmon/session.pyo

References

Summary

In this tutorial we learn how to install libpfm-python.x86_64 on Amazon Linux 2 using yum.