Repository navigation
Description
Description
Posted details of the issue here: https://groups.google.com/g/salt-users/c/5DEzzb5xLq4
I can gladly paste it here if that is the desire.
Setup
Please be as specific as possible and give set-up details.
- on-prem machine
- container (master is on docker using pypi)
- classic packaging (with pypi)
Steps to Reproduce the behavior
Set UMask=022 on the salt-minion.service file, restart the service and see salt minion1 cmd.run 'umask' report 077 instead.
When i create a file on all the minions the permissions are mixed:
salt \* cmd.run "ls -al file1.txt"
jid: 20240213155817815117
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-------. 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw-r--r-- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:57 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
<redactedminion_name>:
-rw------- 1 root root 0 Feb 13 15:58 file1.txt
Expected behavior
cmd.run 'umask' should report 022 and newly created file permissions should also be according to the umask set. salt minion1 cmd.run 'touch file.txt' , salt minion1 cmd.run 'ls -al file.txt'
Screenshots
If applicable, add screenshots to help explain your problem.
Versions Report
salt --versions-report (master inside docker)
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Salt Version:
Salt: 3006.6
Python Version:
Python: 3.9.18 (main, Jan 27 2024, 07:41:26)
Dependency Versions:
cffi: 1.16.0
cherrypy: unknown
dateutil: 2.8.2
docker-py: Not Installed
gitdb: Not Installed
gitpython: Not Installed
Jinja2: 3.1.3
libgit2: Not Installed
looseversion: 1.3.0
M2Crypto: Not Installed
Mako: Not Installed
msgpack: 1.0.7
msgpack-pure: Not Installed
mysql-python: Not Installed
packaging: 23.2
pycparser: 2.21
pycrypto: Not Installed
pycryptodome: 3.20.0
pygit2: Not Installed
python-gnupg: Not Installed
PyYAML: 6.0.1
PyZMQ: 25.1.2
relenv: Not Installed
smmap: Not Installed
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.4
Salt Extensions:
salt-nornir: 0.21.0
System Versions:
dist: alpine 3.19.1
locale: utf-8
machine: x86_64
release: 5.14.0-362.18.1.el9_3.x86_64
system: Linux
version: Alpine Linux 3.19.1salt-minion --versions-report (minion rocky8)
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Salt Version:
Salt: 3006.6
Python Version:
Python: 3.9.18 (main, Nov 18 2023, 01:00:14)
Dependency Versions:
cffi: 1.15.1
cherrypy: 18.8.0
dateutil: 2.8.2
docker-py: 6.1.3
gitdb: 4.0.10
gitpython: 3.1.31
Jinja2: 3.1.2
libgit2: Not Installed
looseversion: 1.2.0
M2Crypto: Not Installed
Mako: Not Installed
msgpack: 1.0.5
msgpack-pure: Not Installed
mysql-python: Not Installed
packaging: 23.1
pycparser: 2.21
pycrypto: Not Installed
pycryptodome: 3.18.0
pygit2: Not Installed
python-gnupg: 0.5.0
PyYAML: 5.4.1
PyZMQ: 25.0.2
relenv: Not Installed
smmap: 5.0.0
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.4
System Versions:
dist: rocky 8.8 Green Obsidian
locale: utf-8
machine: x86_64
release: 4.18.0-477.15.1.el8_8.x86_64
system: Linux
version: Rocky Linux 8.8 Green Obsidiansalt-minion --versions-report (minion rocky9)
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Salt Version:
Salt: 3006.6
Python Version:
Python: 3.9.18 (main, Jan 4 2024, 00:00:00)
Dependency Versions:
cffi: Not Installed
cherrypy: Not Installed
dateutil: 2.8.1
docker-py: 6.1.3
gitdb: Not Installed
gitpython: Not Installed
Jinja2: 3.1.2
libgit2: Not Installed
looseversion: 1.3.0
M2Crypto: Not Installed
Mako: Not Installed
msgpack: 1.0.5
msgpack-pure: Not Installed
mysql-python: Not Installed
packaging: 23.1
pycparser: Not Installed
pycrypto: Not Installed
pycryptodome: 3.18.0
pygit2: Not Installed
python-gnupg: 0.5.1
PyYAML: 6.0.1
PyZMQ: 25.0.2
relenv: Not Installed
smmap: Not Installed
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.4
System Versions:
dist: rocky 9.3 Blue Onyx
locale: utf-8
machine: x86_64
release: 5.14.0-362.18.1.el9_3.x86_64
system: Linux
version: Rocky Linux 9.3 Blue OnyxAdditional context
As stated in the google groups link, I get mixed results. Sometimes after a service restart or a stop/start, salt-minion report the correct umask as declared in the service file, but other times it does not. I have to continually restart the minion service until it finally consistently reports umask as 022.
Activity
davama commentedon Apr 3, 2024
Just to update
upgraded minions and master to v3007.0 via pip and still had this issue with some of my minions not running with umask=022
after running below several times on affected minions, umask is now 022
davama commentedon Apr 9, 2024
Update
had to revert to 3006.7 because many of my minions would no longer be responding.
see minion logs below:
This of course cause me to pkill/stop/restart salt-minion process until umask=022...