-
Notifications
You must be signed in to change notification settings - Fork 23.8k
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
apt module upgrade resets apt-hold values #71036
Comments
Files identified in the description: If these files are incorrect, please update the |
I am unable to reproduce this issue - root@d0ce3181cfee:/# apt-mark showhold
passwd
tar
root@d0ce3181cfee:/# dpkg -l |grep passwd
ii base-passwd 3.5.52build1 amd64 Debian base system master password and group files
hi passwd 1:4.8.1-2ubuntu2.1 amd64 change and administer password and group data
root@d0ce3181cfee:/# ansible-playbook main.yml -v
[WARNING]: You are running the development version of Ansible. You should only run
Ansible from "devel" if you are modifying the Ansible engine, or trying out features
under development. This is a rapidly changing source of code and can become unstable at
any point.
No config file found; using defaults
[WARNING]: No inventory was parsed, only implicit localhost is available
[WARNING]: provided hosts list is empty, only localhost is available. Note that the
implicit localhost does not match 'all'
PLAY [localhost] ************************************************************************
TASK [Gathering Facts] ******************************************************************
ok: [localhost]
TASK [apt] ******************************************************************************
ok: [localhost] => {"changed": false, "msg": "Reading package lists...\nBuilding dependency tree...\nReading state information...\nCalculating upgrade...\nThe following packages have been kept back:\n passwd\n0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.\n", "stderr": "", "stderr_lines": [], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading state information...\nCalculating upgrade...\nThe following packages have been kept back:\n passwd\n0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.\n", "stdout_lines": ["Reading package lists...", "Building dependency tree...", "Reading state information...", "Calculating upgrade...", "The following packages have been kept back:", " passwd", "0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded."]}
PLAY RECAP ******************************************************************************
localhost : ok=2 changed=0 unreachable=0 failed=0 skipped=0 rescued=0 ignored=0
root@d0ce3181cfee:/# apt-mark showhold
passwd
tar
root@d0ce3181cfee:/# dpkg -l |grep passwd
ii base-passwd 3.5.52build1 amd64 Debian base system master password and group files
hi passwd 1:4.8.1-2ubuntu2.1 amd64 change and administer password and group data |
It's probably fine to close then, this was so long ago and with such an ancient Ansible version I'm not even sure it affects us anymore. |
@joshuaboniface Thanks for providing this additional information. Please feel free to open a new issue if the problem persists. Thanks. |
SUMMARY
Running an apt with
upgrade: safe
while packages are held results in the package holds being cleared. This should not occur.ISSUE TYPE
COMPONENT NAME
apt
ANSIBLE VERSION
CONFIGURATION
OS / ENVIRONMENT
Debian 10.X
STEPS TO REPRODUCE
apt-hold mark <package>
against several packages:EXPECTED RESULTS
The apt module should both not clear these holds and respect them (I'm not certain which issue comes first). Held packages should not be touched under any circumstances by this module as it entirely defeats the purpose of holding them.
ACTUAL RESULTS
See reproduction steps above. The output of the command even with multiple
-v
flags shows nothing abnormal, it's as if the hold is not respected at all.The text was updated successfully, but these errors were encountered: