an issue after Salt upgrade

30 views
Skip to first unread message

Risto Vaarandi

unread,
Jun 11, 2024, 5:50:38 PMJun 11
to Salt-users
hi all,

my apologies if I am asking something very obvious, since I am not a Salt expert. Recently, I upgraded an old Salt installation (3004) to 3007, and after changing one of the centrally managed files, I am no longer able to distribute it to minions.

My /etc/salt/pillar/top.sls file has the following definition:

base:
  'myhost.mydomain':
    - myhost

Also, /etc/salt/pillar/myhost.sls contains the following lines:

mysw:
  config: salt://mysw/mysw.yaml-internal

And /etc/salt/mysw.sls  contains the following lines:

Create mysw configfile:
  file.managed:
    - name: /etc/mysw/mysw.yaml
    - source: {{ pillar['mysw']['config'] }}

That configuration worked with previous version of Salt, but after modifying /etc/salt/mysw/mysw.yaml-internal today, distributing the modified file to the minion produced an error:

salt -E 'myhost' state.apply mysw

ID: Create mysw configfile
Function: file.managed
Name: /etc/mysw/mysw.yaml
Result: False
Comment: Source file salt://mysw/mysw.yaml-internal not found in saltenv 'base'
Started: 22:55:53.307314
Duration: 5.411 ms
Changes:  

Also, there are several other managed files that have not been modified, and for them no error messages are produced.

Unfortunately, I am only an occasional Salt user and it is thus fairly difficult to figure out what could be wrong here. I did google the error message above and did not get much useful information. Any ideas how to fix that problem?

kind regards,
risto

Phipps, Thomas

unread,
Jun 11, 2024, 6:58:15 PMJun 11
to salt-...@googlegroups.com
check the permissions. one change that happened between 3004 and 3006 was that the master no longer runs as root. it defaults to the salt user.

--
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/salt-users/350c74a1-3af8-4824-a275-17e0ce0ac0f7n%40googlegroups.com.

Aaron Greengrass

unread,
Jun 11, 2024, 7:19:34 PMJun 11
to salt-...@googlegroups.com
also symlinks no longer work, if you have your formulas symlinked into your tree, they'll be ignored.  everything must either exist in the path relative to the salt root, or be bind mounted in.


------ Original Message ------
From "'Phipps, Thomas' via Salt-users" <salt-...@googlegroups.com>
Date 2024-06-11 3:57:49 PM
Subject Re: [salt-users] an issue after Salt upgrade

Risto Vaarandi

unread,
Jun 12, 2024, 1:51:12 PMJun 12
to Salt-users
hi all,
it turned out to be a file permission issue.-- as I discovered a few hours after posting my question, only the root-user was able to access mysw.yaml-internal, and making it readable for user 'salt' fixed the problem.
kind regards,
risto
Reply all
Reply to author
Forward
0 new messages