# Error - "No Package MySQL-python avaiable". How to fix this?

**URL:** <https://forum.ansible.com/t/error-no-package-mysql-python-avaiable-how-to-fix-this/34048>\
**Category:** Ansible Project\
**Created:** [October 17, 2020, 5:21pm UTC](https://forum.ansible.com/t/error-no-package-mysql-python-avaiable-how-to-fix-this/34048 "2020-10-17T17:21:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prabhakaran\_Karuppai](https://avatars.discourse-cdn.com/v4/letter/p/c4cdca/32.png) [@Prabhakaran\_Karuppai](https://forum.ansible.com/u/Prabhakaran_Karuppai)\
**Post date:** [October 17, 2020, 5:21pm UTC](https://forum.ansible.com/t/error-no-package-mysql-python-avaiable-how-to-fix-this/34048/1 "2020-10-17T17:21:01Z")

</div>

[root@localhost playbooks]# ansible-playbook starfish.yml  
[DEPRECATION WARNING]: The firewalld module has been moved to the ansible.posix  
collection. This feature will be removed from community.general in version  
2.0.0. Deprecation warnings can be disabled by setting  
deprecation\_warnings=False in ansible.cfg.

PLAY [starfish] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

TASK [Gathering Facts] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
ok: [localhost]

TASK [Install epel-release] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
ok: [localhost]

TASK [Install dependencies] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
fatal: [localhost]: FAILED! =\> {“changed”: false, “failures”: [“No package MySQL-python available.”], “msg”: “Failed to install some of the specified packages”, “rc”: 1, “results”: }

PLAY RECAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
localhost : ok=2 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0

[root@localhost playbooks]#

---

<div class="post-metadata">

**Author:** ![Dick\_Visser](https://avatars.discourse-cdn.com/v4/letter/d/d9b06d/32.png) [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Post date:** [October 17, 2020, 6:38pm UTC](https://forum.ansible.com/t/error-no-package-mysql-python-avaiable-how-to-fix-this/34048/2 "2020-10-17T18:38:46Z")

</div>

With the amount of context you’ve given it’s not possible to tell.  
Share the playbook, at least.

---

<div class="post-metadata">

**Author:** ![Prabhakaran\_Karuppai](https://avatars.discourse-cdn.com/v4/letter/p/c4cdca/32.png) [@Prabhakaran\_Karuppai](https://forum.ansible.com/u/Prabhakaran_Karuppai)\
**Post date:** [October 18, 2020, 12:18am UTC](https://forum.ansible.com/t/error-no-package-mysql-python-avaiable-how-to-fix-this/34048/3 "2020-10-18T00:18:02Z")

</div>



---

<div class="post-metadata">

**Author:** ![Dick\_Visser](https://avatars.discourse-cdn.com/v4/letter/d/d9b06d/32.png) [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Post date:** [October 19, 2020, 4:15am UTC](https://forum.ansible.com/t/error-no-package-mysql-python-avaiable-how-to-fix-this/34048/4 "2020-10-19T04:15:27Z")

</div>

Something is wrong with the yum/dnf setup on your host. Perhaps wrong repo(s) configured, exclude patterns, or something like that. In any way not something ansible related but a host problem.  
Once you fixed that it might be a good idea to include that fix in your playbook. Or just start with clean host in known-good state where this works (as it should).
