# No package matching 'python-pip' is available ubuntu 20.04 LTS

**URL:** <https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546>\
**Category:** Ansible Project\
**Tags:** ubuntu\
**Created:** [January 31, 2021, 9:15am UTC](https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546 "2021-01-31T09:15:30Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Syed\_Ejaz\_Ahmed\_Hash](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Syed\_Ejaz\_Ahmed\_Hash](https://forum.ansible.com/u/Syed_Ejaz_Ahmed_Hash)\
**Post date:** [January 31, 2021, 9:15am UTC](https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546/1 "2021-01-31T09:15:30Z")

</div>

We have full functional ansible on Ubuntu 18.04 LTS and all our playbooks are running successfully without any issue on ubuntu 18.04 LTS.

We are trying to run the playbook on ubuntu 20.04 LTS and run the playbook which install some apt packages on the remote server but we getting

Fatal error msg: No package matching ‘python-pip’ is available

However the package and dependencies are install when the remote OS is ubuntu 18.04

Can you please guide us now to resolve this issue ?

 ![errors.png](https://us1.discourse-cdn.com/ansible/original/2X/5/541be9e5f91a1d48097d3aefefae4e4d41bbebb0.png) ![error-2.png](https://us1.discourse-cdn.com/ansible/original/2X/b/b976adad7e214dbe1a444da6576d3168ff29d93f.png)

---

<div class="post-metadata">

**Author:** ![Syed\_Ejaz\_Ahmed\_Hash](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Syed\_Ejaz\_Ahmed\_Hash](https://forum.ansible.com/u/Syed_Ejaz_Ahmed_Hash)\
**Post date:** [January 31, 2021, 9:18am UTC](https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546/2 "2021-01-31T09:18:00Z")

</div>

![errors.png](https://us1.discourse-cdn.com/ansible/original/2X/5/541be9e5f91a1d48097d3aefefae4e4d41bbebb0.png)

---

<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:** [January 31, 2021, 3:32pm UTC](https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546/3 "2021-01-31T15:32:37Z")

</div>

This is correct. So far you've implicitly used python2 as the  
interpreter on the target host.  
Python2 has been EOL for a while, and starting with Ubuntu 20.04 it is  
not available anymore.  
Solution: start using python3 as the interpreter.  
This might mean you have to change the python3 version of whatever pip  
packages you used to use on Ubuntu 18.04.  
You can set this for this target OS only.  
[https://docs.ansible.com/ansible/latest/reference\_appendices/interpreter\_discovery.html](https://docs.ansible.com/ansible/latest/reference_appendices/interpreter_discovery.html)

If all your target hosts have python3 (Ubuntu 18.04 LTS does), you can  
also start using python3 for all your target, avoiding extra  
configuration drift with mixed python2/python3.  
Unless of course your target hosts include hosts with OSes that ONLY  
run python2.

---

<div class="post-metadata">

**Author:** ![Syed\_Ejaz\_Ahmed\_Hash](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Syed\_Ejaz\_Ahmed\_Hash](https://forum.ansible.com/u/Syed_Ejaz_Ahmed_Hash)\
**Post date:** [January 31, 2021, 3:42pm UTC](https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546/4 "2021-01-31T15:42:06Z")

</div>

Thank you the the tip let me try it

we have all OS using python 2

---

<div class="post-metadata">

**Author:** ![Syed\_Ejaz\_Ahmed\_Hash](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Syed\_Ejaz\_Ahmed\_Hash](https://forum.ansible.com/u/Syed_Ejaz_Ahmed_Hash)\
**Post date:** [January 31, 2021, 4:48pm UTC](https://forum.ansible.com/t/no-package-matching-python-pip-is-available-ubuntu-20-04-lts/34546/5 "2021-01-31T16:48:18Z")

</div>

it worked thank you
