salt: State pkg.purged doesn't purge packages on at least Debian 8 to 11
Description of Issue/Question
State pkg.purged doesn’t purge packages on at least Debian 8 and 9
Steps to Reproduce Issue
/srv/salt# cat purge.sls
---
purge exim:
pkg.purged:
- pkgs:
- exim4
- exim4-base
- exim4-config
exim4-daemon-light:
pkg.purged
/srv/salt# salt-call state.apply purge
local:
----------
ID: purge exim
Function: pkg.purged
Result: True
Comment: All specified packages are already absent
Started: 11:24:27.199039
Duration: 323.465 ms
Changes:
----------
ID: exim4-daemon-light
Function: pkg.purged
Result: True
Comment: All specified packages are already absent
Started: 11:24:27.526847
Duration: 8.509 ms
Changes:
Summary for local
------------
Succeeded: 2
Failed: 0
------------
Total states run: 2
Total run time: 331.974 ms
/srv/salt# dpkg -l|grep exim
rc exim4 4.89-2+deb9u1 all metapackage to ease Exim MTA (v4) installation
rc exim4-base 4.89-2+deb9u1 amd64 support files for all Exim MTA (v4) packages
rc exim4-config 4.89-2+deb9u1 all configuration for the Exim MTA (v4)
rc exim4-daemon-light 4.89-2+deb9u1 amd64 lightweight Exim MTA (v4) daemon
Versions Report
/srv/salt# salt-call --versions-report
Salt Version:
Salt: 2016.11.6
Dependency Versions:
cffi: Not Installed
cherrypy: Not Installed
dateutil: 2.5.3
docker-py: Not Installed
gitdb: 2.0.0
gitpython: 2.1.1
ioflo: Not Installed
Jinja2: 2.9.4
libgit2: Not Installed
libnacl: Not Installed
M2Crypto: Not Installed
Mako: Not Installed
msgpack-pure: Not Installed
msgpack-python: 0.4.8
mysql-python: 1.3.7
pycparser: Not Installed
pycrypto: 2.6.1
pycryptodome: Not Installed
pygit2: Not Installed
Python: 2.7.13 (default, Jan 19 2017, 14:48:08)
python-gnupg: Not Installed
PyYAML: 3.12
PyZMQ: 16.0.2
RAET: Not Installed
smmap: 2.0.1
timelib: Not Installed
Tornado: 4.4.3
ZMQ: 4.2.1
System Versions:
dist: debian 9.0
machine: x86_64
release: 4.9.0-3-amd64
system: Linux
version: debian 9.0
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 27 (11 by maintainers)
@tkae Well from https://github.com/saltstack/salt/pull/5503 and its associated https://github.com/saltstack/salt/issues/4972, looks like functionality was broken long ago circa 2016.11 or before, probably in the transition from apt.py module to aptpkg.py, which is very long ago.
This will take some time to wade through to see the breakage, will re-open Have to check if the removal of this functionality was intentional or not, which is problematic given the age of the issue, Salt version. 2016.11.6