Title says it all. I have installed salt on a master and a few minions. On the master I only installed the basic salt components (not including salt-minion) and ran the update.
I pointed the minions at the master's IP, but they weren't showing up. Upon further investigation it seemed the reason for that problem is "The salt master is not running".
So I go to run "salt-master -d" to start it and I get:
WARNING: Unable to bind socket 0.0.0.0:4505, error: [Errno 98] Address already in use; Is there another salt-master running?
The salt master is shutdown. The ports are not available to bind"salt-master -l debug" gives me
[DEBUG ] Reading configuration from /etc/salt/master
[DEBUG ] Configuration file path: /etc/salt/master
[WARNING ] Insecure logging configuration detected! Sensitive data may be logged.
[INFO ] Setting up the Salt Master
[WARNING ] Unable to bind socket 0.0.0.0:4505, error: [Errno 98] Address already in use; Is there another salt-master running?
[INFO ] The Salt Master is shut down
[INFO ] PIDfile could not be deleted: /var/run/salt-master.pid
[DEBUG ] Stopping the multiprocessing logging queue listener
[DEBUG ] closing multiprocessing queue
[DEBUG ] joining multiprocessing queue thread
[DEBUG ] Stopped the multiprocessing logging queue listenerThere is definitely not another master running. Top shows lots of salt processes are indeed running, and following some internet advice I tried killall and starting over. This time it seemed to work but when I tried to run literally any command I get
[ERROR ] An un-handled exception was caught by salt's global exception handler:
KeyError: 'consul.list'I have no idea what is happening and I'm about to go toast the server and get fresh installs of everything, because nothing is working. But I have a sneaking suspicion that it will not be different the second time.
The master is running Ubuntu 18.04 server if that helps, with the Py3 version of SaltStack.
1 Answer
Searching through SaltStack Troubleshooting Docs I found:
For the master, TCP ports 4505 and 4506 need to be open. If you've put both your Salt master and minion in debug mode and don't see an acknowledgment that your minion has connected, it could very well be a firewall interfering with the connection.
You can find firewall rules in /etc/ufw/applications.d/salt.ufw and enable with ufw allow salt