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

[DOCS] Salt Master Cluster Tutorial - Cache Directory #66264

Closed
clayoster opened this issue Mar 23, 2024 · 0 comments · Fixed by #66265
Closed

[DOCS] Salt Master Cluster Tutorial - Cache Directory #66264

clayoster opened this issue Mar 23, 2024 · 0 comments · Fixed by #66265
Labels
Documentation Relates to Salt documentation needs-triage

Comments

@clayoster
Copy link
Contributor

Description
The suggested setting for moving the master cache to the shared filesystem appears to be incorrect. I have tried using cache_dir but nothing was written to my shared filesystem location. Errors are also generated about not being able to find jobs initiated by other masters and the path in the error indicates the default master cache path is still being used.

2024-03-23 10:12:58,395 [salt.master      :2093][ERROR   ][160450] Error in function _return:
Traceback (most recent call last):
  File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/returners/local_cache.py", line 309, in get_load
    with salt.utils.files.fopen(minions_path, "rb") as rfh:
  File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/files.py", line 393, in fopen
    f_handle = open(*args, **kwargs)  # pylint: disable=resource-leakage
FileNotFoundError: [Errno 2] No such file or directory: '/var/cache/salt/master/jobs/d1/a5bd1ec0b4d790c092cd9d243e6d78c0e5f716e9a76968e2c4871e67d59761/.minions.p'

Using the cachedir setting instead causes master cache data to be written to my shared filesystem as expected and the error shown above was no longer seen.

Suggested Fix
Change cache_dir to cachedir in the Master Cluster tutorial.

Type of documentation
Tutorial

Location or format of documentation
https://docs.saltproject.io/en/master/topics/tutorials/master-cluster.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Relates to Salt documentation needs-triage
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant