How To Install python3-mysqlclient on Rocky Linux 8
Introduction
In this tutorial we learn how to install python3-mysqlclient
on Rocky Linux 8.
What is python3-mysqlclient
MySQLdb is an interface to the popular MySQL database server that provides the Python database API.
We can use yum
or dnf
to install python3-mysqlclient
on Rocky Linux 8. In this tutorial we discuss both methods but you only need to choose one of method to install python3-mysqlclient.
Install python3-mysqlclient on Rocky Linux 8 Using dnf
Update yum database with dnf
using the following command.
sudo dnf makecache --refresh
After updating yum database, We can install python3-mysqlclient
using dnf
by running the following command:
sudo dnf -y install python3-mysqlclient
Install python3-mysqlclient on Rocky Linux 8 Using yum
Update yum database with yum
using the following command.
sudo yum makecache --refresh
After updating yum database, We can install python3-mysqlclient
using yum
by running the following command:
sudo yum -y install python3-mysqlclient
How To Uninstall python3-mysqlclient on Rocky Linux 8
To uninstall only the python3-mysqlclient
package we can use the following command:
sudo dnf remove python3-mysqlclient
python3-mysqlclient Package Contents on Rocky Linux 8
/usr/lib/.build-id
/usr/lib/.build-id/76
/usr/lib/.build-id/76/e3dd08bb1f456988a240201cb47fdcff1f844f
/usr/lib64/python3.6/site-packages/MySQLdb
/usr/lib64/python3.6/site-packages/MySQLdb/__init__.py
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/__init__.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/__init__.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/_exceptions.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/_exceptions.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/compat.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/compat.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/connections.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/connections.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/converters.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/converters.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/cursors.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/cursors.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/release.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/release.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/times.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/__pycache__/times.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/_exceptions.py
/usr/lib64/python3.6/site-packages/MySQLdb/_mysql.cpython-36m-x86_64-linux-gnu.so
/usr/lib64/python3.6/site-packages/MySQLdb/compat.py
/usr/lib64/python3.6/site-packages/MySQLdb/connections.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants
/usr/lib64/python3.6/site-packages/MySQLdb/constants/CLIENT.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants/CR.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants/ER.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants/FIELD_TYPE.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants/FLAG.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__init__.py
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/CLIENT.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/CLIENT.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/CR.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/CR.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/ER.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/ER.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/FIELD_TYPE.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/FIELD_TYPE.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/FLAG.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/FLAG.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/__init__.cpython-36.opt-1.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/constants/__pycache__/__init__.cpython-36.pyc
/usr/lib64/python3.6/site-packages/MySQLdb/converters.py
/usr/lib64/python3.6/site-packages/MySQLdb/cursors.py
/usr/lib64/python3.6/site-packages/MySQLdb/release.py
/usr/lib64/python3.6/site-packages/MySQLdb/times.py
/usr/lib64/python3.6/site-packages/mysqlclient-1.4.6-py3.6.egg-info
/usr/lib64/python3.6/site-packages/mysqlclient-1.4.6-py3.6.egg-info/PKG-INFO
/usr/lib64/python3.6/site-packages/mysqlclient-1.4.6-py3.6.egg-info/SOURCES.txt
/usr/lib64/python3.6/site-packages/mysqlclient-1.4.6-py3.6.egg-info/dependency_links.txt
/usr/lib64/python3.6/site-packages/mysqlclient-1.4.6-py3.6.egg-info/top_level.txt
/usr/share/doc/python3-mysqlclient
/usr/share/doc/python3-mysqlclient/HISTORY.rst
/usr/share/doc/python3-mysqlclient/README.md
/usr/share/licenses/python3-mysqlclient
/usr/share/licenses/python3-mysqlclient/LICENSE
References
Summary
In this tutorial we learn how to install python3-mysqlclient
on Rocky Linux 8 using yum and dnf.