salt icon indicating copy to clipboard operation
salt copied to clipboard

master_job_cache: mysql in master file causing warning with every Salt command

Open ssgward opened this issue 11 years ago • 7 comments

  1. add master_job_cache: mysql to /etc/salt/master file
  2. restart salt-master service
  3. run any command i.e. salt '*' test.ping

Get this warning:

[ WARNING ] Returner unavailable: MySQL returner could not connect to database: (1045, "Access denied for user 'root'@'localhost' (using password: YES)") 

I'm guessing that we don't want this message to be displayed.

ssgward avatar Feb 27 '15 22:02 ssgward

Sorry, forgot: getting this on 2015.2, latest

ssgward avatar Feb 27 '15 22:02 ssgward

Are we sure this is a Salt bug? The mysql database is telling us that the credentials Salt is sending it are not valid.

cro avatar Feb 28 '15 19:02 cro

This warning is probably due to the environment I was testing in. I'll check a couple of things and then close this issue if it is environment related or add more detail if I find out something further that supports this being a valid bug.

ssgward avatar Mar 09 '15 16:03 ssgward

If root has a password then this message goes away.

No root password = message appears

ssgward avatar Mar 10 '15 17:03 ssgward

One question that has come up is why are we trying to connect using root, when the DB was installed via a different user? In this case saltadmin. Database is accessible and can be accessed, so not sure why this message is coming up saying it can't connect unless some root password is implied, but then, how would Salt know what the root password is? Or are we just checking to see if any password exists and if one does exist not displaying the warning?

ssgward avatar Mar 11 '15 16:03 ssgward

Now I'm getting that message when root has a password.

Any salt command now displays

[WARNING ] Returner unavailable: MySQL returner could not connect to database: (1045, "Access denied for user 'root'@'localhost' (using password: YES)")

Testing on latest 2015.2

ssgward avatar Mar 13 '15 20:03 ssgward

This has been fixed. Closing.

ssgward avatar Mar 17 '15 23:03 ssgward