Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] salt-ssh fails to find platform-python Python interpreter on EL8 #62235

Closed
lastmikoi opened this issue Jun 28, 2022 · 1 comment · Fixed by #62236
Closed

[BUG] salt-ssh fails to find platform-python Python interpreter on EL8 #62235

lastmikoi opened this issue Jun 28, 2022 · 1 comment · Fixed by #62236
Labels
Bug broken, incorrect, or confusing behavior needs-triage RHEL Related to running salt on or targeting Red Had Enterprise Linux Salt-SSH

Comments

@lastmikoi
Copy link
Contributor

Description
salt-ssh fails to find python on a freshly installed EL8 host, even though salt is installed on the host, with a compatible python3 interpreter.

Setup

  1. On a local host, set up salt-ssh 3004.2.
  2. On a remote host (VM), set up a fresh RockyLinux 8 install (should also work for RHEL8 or derivatives).
  3. Add the SaltStack RHEL 8 repo (https://repo.saltproject.io/#rhel) to that host.
  4. Run dnf install salt-minion to install the salt-minion package.

No need to start the minion.

Steps to Reproduce the behavior
Run test.ping from local host using salt-ssh:

$ salt-ssh "target_host" -w -t test.ping
target_host:
    ----------
    retcode:
        10
    stderr:
        ERROR: Unable to locate appropriate python command
    stdout:
        ERROR: Python version error. Recommendation(s) follow:
        - Install Python 3 on the target machine(s)
        - You can use ssh_pre_flight or raw shell (-r) to install Python 3

Even though running test.ping on the remote host directly (using salt-call) works fine:

[root@target_host]# salt-call --local test.ping
local:
    True

Expected behavior
salt-ssh should be able to locate the remote Python 3 interpreter used by salt (here: /usr/libexec/platform-python)

Versions Report

salt --versions-report (Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)

Local host:

Salt Version:
          Salt: 3004.2
 
Dependency Versions:
          cffi: 1.14.5
      cherrypy: Not Installed
      dateutil: Not Installed
     docker-py: Not Installed
         gitdb: Not Installed
     gitpython: Not Installed
        Jinja2: 3.0.3
       libgit2: 1.1.0
      M2Crypto: Not Installed
          Mako: Not Installed
       msgpack: 1.0.3
  msgpack-pure: Not Installed
  mysql-python: Not Installed
     pycparser: 2.20
      pycrypto: 2.6.1
  pycryptodome: 3.13.0
        pygit2: 1.5.0
        Python: 3.6.12 (default, Nov 17 2021, 21:43:08)
  python-gnupg: Not Installed
        PyYAML: 6.0
         PyZMQ: 21.0.2
         smmap: Not Installed
       timelib: Not Installed
       Tornado: 4.5.3
           ZMQ: 4.3.3
 
System Versions:
          dist: arch  
        locale: UTF-8
       machine: x86_64
       release: 5.18.6-arch1-1
        system: Linux
       version: Arch Linux  

Remote host (using salt-call):

Salt Version:
          Salt: 3004.2
 
Dependency Versions:
          cffi: Not Installed
      cherrypy: Not Installed
      dateutil: 2.6.1
     docker-py: Not Installed
         gitdb: Not Installed
     gitpython: Not Installed
        Jinja2: 2.10.1
       libgit2: Not Installed
      M2Crypto: 0.35.2
          Mako: Not Installed
       msgpack: 0.6.2
  msgpack-pure: Not Installed
  mysql-python: Not Installed
     pycparser: Not Installed
      pycrypto: Not Installed
  pycryptodome: Not Installed
        pygit2: Not Installed
        Python: 3.6.8 (default, Apr 12 2022, 06:55:39)
  python-gnupg: Not Installed
        PyYAML: 3.12
         PyZMQ: 19.0.0
         smmap: Not Installed
       timelib: Not Installed
       Tornado: 4.5.3
           ZMQ: 4.3.4
 
System Versions:
          dist: rocky 8.6 Green Obsidian
        locale: UTF-8
       machine: x86_64
       release: 4.18.0-372.9.1.el8.x86_64
        system: Linux
       version: Rocky Linux 8.6 Green Obsidian
@lastmikoi lastmikoi added Bug broken, incorrect, or confusing behavior needs-triage labels Jun 28, 2022
@welcome
Copy link

welcome bot commented Jun 28, 2022

Hi there! Welcome to the Salt Community! Thank you for making your first contribution. We have a lengthy process for issues and PRs. Someone from the Core Team will follow up as soon as possible. In the meantime, here’s some information that may help as you continue your Salt journey.
Please be sure to review our Code of Conduct. Also, check out some of our community resources including:

There are lots of ways to get involved in our community. Every month, there are around a dozen opportunities to meet with other contributors and the Salt Core team and collaborate in real time. The best way to keep track is by subscribing to the Salt Community Events Calendar.
If you have additional questions, email us at [email protected]. We’re glad you’ve joined our community and look forward to doing awesome things with you!

@lastmikoi lastmikoi changed the title [BUG] [BUG] salt-ssh fails to find Python interpreter on EL8 Jun 28, 2022
@lastmikoi lastmikoi changed the title [BUG] salt-ssh fails to find Python interpreter on EL8 [BUG] salt-ssh fails to find platform-python Python interpreter on EL8 Jun 28, 2022
@OrangeDog OrangeDog added Salt-SSH RHEL Related to running salt on or targeting Red Had Enterprise Linux labels Jun 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug broken, incorrect, or confusing behavior needs-triage RHEL Related to running salt on or targeting Red Had Enterprise Linux Salt-SSH
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants