You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
Using salt 3006.9 on a Rocky Linux 8.10 test salt master the salt-ssh tool fails to install packages on a Rocky Linux 8.10 test minion and gives and error that "'pkg.install' is not available" or 'pkg.installed' was not found.
Setup
Create 2 Rocky Linux 8.10 virtual machines, install salt with bootstrap on both, start salt-master service on one and salt-minion service on the other. Edit the /etc/salt/master file on the minion to set master: to the fqdn of the master vm.
on-prem machine
[ x ] VM (OpenNebula, KVM)
VM running on a cloud service, please be explicit and add details
container (Kubernetes, Docker, containerd, etc. please specify)
or a combination, please be explicit
jails if it is FreeBSD
classic packaging
[ x ] onedir packaging
[ x ] used bootstrap to install
Steps to Reproduce the behavior
This errors: salt-ssh -i minion.fqdn pkg.install nmap as follows:
----------
retcode:
255
stderr:
/var/tmp/.root_2bbfa8_salt/pyall/salt/utils/psutil_compat.py:18: DeprecationWarning: Please stop importing 'salt.utils.psutil_compat' and instead import 'psutil' directly as there's no longer a need for a compatability layer. The 'salt.utils.psutil_compat' will go away on Salt 3008.0 (Argon).
"Please stop importing 'salt.utils.psutil_compat' and instead import "
/var/tmp/.root_2bbfa8_salt/pyall/salt/modules/x509.py:100: DeprecationWarning: The x509 modules are deprecated. Please migrate to the replacement modules (x509_v2). They are the default from Salt 3008 (Argon) onwards.
"The x509 modules are deprecated. Please migrate to the replacement "
'pkg.install' is not available.
stdout:
Or as follows if using a salt state, salt-ssh -i minion.fqdn state.sls installsalt.update
ID: install nmap to test
Function: pkg.installed
Name: nmap
Result: False
Comment: State 'pkg.installed' was not found in SLS 'installsalt.update'
Reason: 'pkg' __virtual__ returned False: pkg module could not be loaded
Changes:
The salt state contains the following in it in case relevant.
install nmap to test:
pkg.installed:
- name: nmap
Using salt directly, i.e. no salt-ssh, e.g. salt hprc-guest-114-230.tchpc.tcd.ie state.sls installsalt.update, works though.
So the issue seems to be limited to salt-ssh.
It also does not occur from a salt master running salt version 3005.5. I can get pkg.install to work with salt-ssh from a 3005.5 master.
As per I have set the pkg provider to yumpkg in /etc/salt/minion on the minion host as follows:
providers:
pkg: yumpkg
I've also tried updating the state file to set the provider as follows:
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!
This is probably #67091. You can try applying the patch in #67152 and regenerating your thin package before trying your command again or downgrading to 3006.8.
The divergence between regular Salt and Salt-SSH is caused by Salt-SSH needing to use the (outdated) system Python, while regular Salt can bring its own Python environment.
Description
Using salt 3006.9 on a Rocky Linux 8.10 test salt master the salt-ssh tool fails to install packages on a Rocky Linux 8.10 test minion and gives and error that "'pkg.install' is not available" or 'pkg.installed' was not found.
Setup
Create 2 Rocky Linux 8.10 virtual machines, install salt with bootstrap on both, start
salt-master
service on one andsalt-minion
service on the other. Edit the/etc/salt/master
file on the minion to setmaster:
to the fqdn of the master vm.Steps to Reproduce the behavior
This errors:
salt-ssh -i minion.fqdn pkg.install nmap
as follows:Or as follows if using a salt state,
salt-ssh -i minion.fqdn state.sls installsalt.update
The salt state contains the following in it in case relevant.
Using salt directly, i.e. no salt-ssh, e.g.
salt hprc-guest-114-230.tchpc.tcd.ie state.sls installsalt.update
, works though.So the issue seems to be limited to salt-ssh.
It also does not occur from a salt master running salt version 3005.5. I can get pkg.install to work with salt-ssh from a 3005.5 master.
As per I have set the pkg provider to yumpkg in
/etc/salt/minion
on the minion host as follows:I've also tried updating the state file to set the provider as follows:
This does not resolve the issue though.
Debug outputs.
salt-ssh-pkg.install.txt is the output of command
salt-ssh -l debug -i 'minion.fqdn' pkg.install nmap
.salt-ssh-state.sls.txt is the output of command
salt-ssh -l debug -i 'hprc-guest-114-230.tchpc.tcd.ie' state.sls installsalt.update
.Expected behaviour
pkg.install
will install packages.Versions Report
Thanks in advance.
The text was updated successfully, but these errors were encountered: