Adding 'Running and debugging salt states' section. That shows off the salt-call command, to help you debug. Also shows you how in the world to run a .sls file, which is always a good thing :)

This commit is contained in:
peacetara 2012-06-28 11:51:25 -07:00
parent 8e51797e0f
commit 2f54587cbc

View file

@ -462,4 +462,18 @@ This clearly illustrates, that not only is using the YAML renderer a wise
decision as the default, but that unbridled power can be obtained where
needed by using a pure Python SLS.
Running and debugging salt states.
----------------------------------
after writing out your top.sls file, to run it you call
``salt '*' state.highstate``. If you get back just the hostnames with
a : after, but no return, then chances are there is a problem with the sls
files. To debug these, to see what's going on, and see the errors, use the
``salt-call`` command like so: ``salt-call state.highstate -l debug``. This
should help you figure out what's going wrong. You can also start the minions
in the foreground in debug mode, as a possible way to help debug as well.
To start the minion in debug mode call it like this: ``salt-minion -l debug``.
Now onto the :doc:`States tutorial, part 1</topics/tutorials/states_pt1>`.