Does Salt have the equivalent of Puppet's last_run_summary.yaml? If not, what's the suggested way to monitor the success or failure of executions on individual salt minions?


I think I found a reasonable way to get this information written to the file system. We can modify the minion config (on Linux I believe the default location is /etc/salt/minion) to add:

returners: rawfile_json

This will result in one JSON object per line being logged. Documented here. The default output file location for this is /var/log/salt/events. The JSON object has fields which we can use: retcode, success, and fun (the function name). In my case I want to filter for fun = "state.apply".


I think you can use the jobs.exit_success command to do so

The only thing is you need to retrieve the job_id first

salt-run jobs.list_jobs
salt-run jobs.exit_success <jobid>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.