<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: fatal: [192.168.0.120]: FAILED! =&amp;gt; {&amp;quot;changed&amp;quot;: false, &amp;quot;msg&amp;quot;: &amp;quot;Missing required library \&amp;quot;pandevice\&amp;quot;.&amp;quot;} in Automation/API Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/410262#M2674</link>
    <description>&lt;P&gt;As Gfreeman is saying if you run python --version what you see as the default version? You may installed "pan-os-python" under python2 or python3 (pip2 or pip3) but not under the default version of python.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://linuxize.com/post/how-to-install-pip-on-ubuntu-20.04/" target="_blank"&gt;https://linuxize.com/post/how-to-install-pip-on-ubuntu-20.04/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://dev.to/meetsohail/change-the-python3-default-version-in-ubuntu-1ekb" target="_blank"&gt;https://dev.to/meetsohail/change-the-python3-default-version-in-ubuntu-1ekb&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can also create docker image and a container with ansible and the corect python than changing things and environmentals in your main operational system:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;A href="https://phoenixnap.com/kb/how-to-commit-changes-to-docker-image" target="_blank"&gt;https://phoenixnap.com/kb/how-to-commit-changes-to-docker-image&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 01 Jun 2021 07:42:06 GMT</pubDate>
    <dc:creator>nikoolayy1</dc:creator>
    <dc:date>2021-06-01T07:42:06Z</dc:date>
    <item>
      <title>fatal: [192.168.0.120]: FAILED! =&gt; {"changed": false, "msg": "Missing required library \"pandevice\"."}</title>
      <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/401911#M2645</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I'm using using ansible collections "&lt;SPAN&gt;paloaltonetworks.panos"&amp;nbsp;&lt;/SPAN&gt;and ended up with the below error.&lt;/P&gt;&lt;P&gt;TASK [retireve api-key]&lt;/P&gt;&lt;P&gt;fatal: [192.168.0.120]: FAILED! =&amp;gt; {"changed": false, "msg": "Missing required library \"pandevice\"."}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm still wonder why its pointing to pandevice when I already installed pan-os-python. I thought pandevice is only for role-&amp;nbsp;PaloAltoNetworks.paloaltonetworks. does pandevice required for collections as well?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Its really confusing which modules will support which library( pan-python, pandevice, pan-os-python)&lt;/P&gt;&lt;P&gt;Playbook&lt;/P&gt;&lt;P&gt;---&lt;BR /&gt;&amp;nbsp; - hosts: palo&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; gather_facts: true&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; collections:&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; - paloaltonetworks.panos&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; tasks:&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; - name: Grab Credentials&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; include_vars: 'secrets.yml'&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; no_log: 'yes'&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; - name: retireve api-key&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; panos_api_key:&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;provider: '{{ palo_provider }}'&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; register: auth&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; any_errors_fatal: true&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you someone help me?&lt;/P&gt;</description>
      <pubDate>Mon, 26 Apr 2021 13:14:11 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/401911#M2645</guid>
      <dc:creator>sridhar15</dc:creator>
      <dc:date>2021-04-26T13:14:11Z</dc:date>
    </item>
    <item>
      <title>Re: fatal: [192.168.0.120]: FAILED! =&gt; {"changed": false, "msg": "Missing required library \"pandevice\"."}</title>
      <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/402268#M2646</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/179748"&gt;@sridhar15&lt;/a&gt;, the below worked for me, taking your playbook as the groundwork.&lt;/P&gt;&lt;P&gt;There is a repo of example playbooks here which might help you:&amp;nbsp;&lt;A href="https://github.com/PaloAltoNetworks/ansible-playbooks" target="_blank"&gt;https://github.com/PaloAltoNetworks/ansible-playbooks&lt;/A&gt;&lt;BR /&gt;More details on&amp;nbsp;pandevice -&amp;gt; pan-os-python here:&amp;nbsp;&lt;A href="https://github.com/PaloAltoNetworks/pan-os-python#upgrade-from-pandevice" target="_blank"&gt;https://github.com/PaloAltoNetworks/pan-os-python#upgrade-from-pandevice&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;---
- hosts: '{{ target | default("firewall") }}'
  connection: local

  gather_facts: true

  collections:
            - paloaltonetworks.panos

  vars:
    palo_provider:
      ip_address: '{{ ip_address }}'
      username: '{{ username | default(omit) }}'
      password: '{{ password | default(omit) }}'
      api_key: '{{ api_key | default(omit) }}'

  tasks:
      - name: Grab Credentials
        include_vars: 'secrets.yml'
        no_log: 'yes'

      - name: retireve api-key
        panos_api_key:
              provider: '{{ palo_provider }}'
        register: auth
        any_errors_fatal: true&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Apr 2021 13:50:36 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/402268#M2646</guid>
      <dc:creator>JimmyHolland</dc:creator>
      <dc:date>2021-04-27T13:50:36Z</dc:date>
    </item>
    <item>
      <title>Re: fatal: [192.168.0.120]: FAILED! =&gt; {"changed": false, "msg": "Missing required library \"pandevice\"."}</title>
      <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/402296#M2647</link>
      <description>&lt;P&gt;The error message hasn't been updated to say "pan-os-python" yet, but it is indeed checking for the pan-os-python library &lt;A href="https://github.com/PaloAltoNetworks/pan-os-ansible/blob/develop/plugins/module_utils/panos.py#L37-L56" target="_self"&gt;first&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since you say pan-os-python is installed but Ansible is not finding it, this likely means that you have multiple python environments setup (knowingly or unknowingly), and the python environment that Ansible is running in does not have pan-os-python installed.&lt;/P&gt;</description>
      <pubDate>Tue, 27 Apr 2021 15:52:20 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/402296#M2647</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2021-04-27T15:52:20Z</dc:date>
    </item>
    <item>
      <title>Re: fatal: [192.168.0.120]: FAILED! =&gt; {"changed": false, "msg": "Missing required library \"pandevice\"."}</title>
      <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/410262#M2674</link>
      <description>&lt;P&gt;As Gfreeman is saying if you run python --version what you see as the default version? You may installed "pan-os-python" under python2 or python3 (pip2 or pip3) but not under the default version of python.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://linuxize.com/post/how-to-install-pip-on-ubuntu-20.04/" target="_blank"&gt;https://linuxize.com/post/how-to-install-pip-on-ubuntu-20.04/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://dev.to/meetsohail/change-the-python3-default-version-in-ubuntu-1ekb" target="_blank"&gt;https://dev.to/meetsohail/change-the-python3-default-version-in-ubuntu-1ekb&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can also create docker image and a container with ansible and the corect python than changing things and environmentals in your main operational system:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;A href="https://phoenixnap.com/kb/how-to-commit-changes-to-docker-image" target="_blank"&gt;https://phoenixnap.com/kb/how-to-commit-changes-to-docker-image&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jun 2021 07:42:06 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/automation-api-discussions/fatal-192-168-0-120-failed-gt-quot-changed-quot-false-quot-msg/m-p/410262#M2674</guid>
      <dc:creator>nikoolayy1</dc:creator>
      <dc:date>2021-06-01T07:42:06Z</dc:date>
    </item>
  </channel>
</rss>

