saltstack / salt

Software to automate the management and configuration of any infrastructure or application at scale. Get access to the Salt software package repository here:
https://repo.saltproject.io/
Apache License 2.0
14k stars 5.47k forks source link

DeprecationWarning: The x509 modules are deprecated. Please migrate to the replacement #66508

Open hsh-it opened 1 month ago

hsh-it commented 1 month ago

Hello, I have a virtual machine with Ubuntu 22.04 on an ESXI host.

I use Uyuni as a patch management server and on some virtual systems I have the problem that the venv-salt-minion shows me errors: $ sudo systemctl status venv-salt-minion.service

● venv-salt-minion.service - The venvjailed Salt Minion
     Loaded: loaded (/lib/systemd/system/venv-salt-minion.service; disabled; vendor preset: enabled)
     Active: active (running) since Tue 2024-04-30 08:37:51 CEST; 1 week 6 days ago
   Main PID: 6187 (python.original)
      Tasks: 5 (limit: 19048)
     Memory: 62.8M
        CPU: 41min 51.709s
     CGroup: /system.slice/venv-salt-minion.service
             ├─6187 /usr/lib/venv-salt-minion/bin/python.original /usr/lib/venv-salt-minion/bin/salt-minion
             └─6198 /usr/lib/venv-salt-minion/bin/python.original /usr/lib/venv-salt-minion/bin/salt-minion

Mai 02 11:22:18 v0091 salt-minion[23665]: /usr/lib/venv-salt-minion/lib/python3.10/site-packages/salt/states/x509.py:212: DeprecationWarning: The x509 modules are deprecated. Please migrate to the replacement>
Mai 02 11:22:18 v0091 salt-minion[23665]:   salt.utils.versions.warn_until(
Mai 02 11:28:36 v0091 salt-minion[24365]: /usr/lib/venv-salt-minion/lib/python3.10/site-packages/salt/states/x509.py:212: DeprecationWarning: The x509 modules are deprecated. Please migrate to the replacement>
Mai 02 11:28:36 v0091 salt-minion[24365]:   salt.utils.versions.warn_until(
Notice: journal has been rotated since unit was started, output may be incomplete.

$ sudo venv-salt-minion --version

venv-salt-minion 3006.0 (Sulfur)

Via uyuni i spreading this repo: https://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Stable:/Ubuntu2204-Uyuni-Client-Tools/xUbuntu_22.04/amd64/

I am not sure how I should and can interpret this message. What should I do here?

Thank you all for spendung your time

welcome[bot] commented 1 month ago

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 saltproject@vmware.com. We’re glad you’ve joined our community and look forward to doing awesome things with you!

voyvodov commented 1 month ago

You should migrate to x509_v2. If not wrong x509 will be removed in version 3008 and x509_v2 will become default one. To switch/activate follow this documentation.

hsh-it commented 1 month ago

If x509 is removed with version 3008 and x509_v2 becomes standard, can I leave it as it is until then and the change will take effect without intervention or will there have to be manual intervention in any case?

voyvodov commented 1 month ago

I'll recommend you to manually switch as there are some breaking changes before upgrading salt to 3008. It will not be nice if all of your stuff stops working during the upgrade. However, until then, it's up to you if you want to use v1 or v2, but if you go with v2, be sure that you're running at least v3006.4 as there are major fixes in 3006.3/4 related to x509 modules.