Sync new proxy
using Salt |
using Pepper |
|
salt-run saltutil.sync_all saltenv="base" salt 'PROXY_NAME' saltutil.sync_all saltenv="base" salt 'PROXY_NAME' saltutil.refresh_pillar |
|
|
pepper --client runner saltutil.sync_all saltenv="base" pepper 'PROXY_NAME' saltutil.sync_all saltenv="base" pepper 'PROXY_NAME' saltutil.sync_states saltenv="base" |
|
PROXY_NAME – can be * for all or router-x* for all routers that start with router-x
run show command on device
For example – Juniper device version
using Salt |
using Pepper |
|
salt 'PROXY_NAME' net.cli 'show version' |
|
|
pepper 'PROXY_NAME' net.cli 'show version' |
|
Get info from proxy
for example device model
using Salt |
using Pepper |
|
salt 'PROXY_NAME' grains.get "model" |
|
|
pepper 'PROXY_NAME' grains.get "model" |
|
Validate and apply new config
show pillar
using Salt |
using Pepper |
|
salt 'PROXY_NAME' pillar.get PILLAR_NAME |
|
|
pepper 'PROXY_NAME' pillar.get PILLAR_NAME |
|
Load a template to network device
using Salt |
using Pepper |
|
salt 'PROXY_NAME' net.load_template salt://PATH_TO_TEMPLATE debug=True saltenv="base" commit=False |
|
|
pepper 'PROXY_NAME' net.load_template salt://PATH_TO_TEMPLATE debug=True saltenv="base" commit=False |
|
Run state
using Salt |
using Pepper |
|
salt 'PROXY_NAME' state.apply STATE_NAME saltenv="base" |
|
|
pepper 'PROXY_NAME' state.apply STATE_NAME saltenv="base" |
|
Troubleshooting
Re-sync proxy with latest device configuration
In case state.apply or net.load_template says that the config is already configured and it not,
and in case that configuration has been changed manually and Salt do not aware of that
using Salt |
using Pepper |
|
salt 'PROXY_NAME' napalm.reconnect force=True |
|
|
pepper 'PROXY_NAME' napalm.reconnect force=True |
|
Check if pillar rendered OK
(In case of error in pillar rendering it will be shown at the beginning of pillar.items)
using Salt |
using Pepper |
|
salt 'PROXY_NAME' pillar.items| head |
|
|
pepper 'PROXY_NAME' pillar.items| head |
|
view pillar info from the master
In case there is a problem in proxy config
using Salt |
using Pepper |
|
salt-run pillar.show_pillar 'PROXY_NAME' |
|
|
pepper --client runner pillar.show_pillar 'PROXY_NAME' |
|
Kill all running jobs
In case a new job can’t be start doe to some old stuck job
using Salt |
using Pepper |
|
salt 'PROXY_NAME' saltutil.kill_all_jobs |
|
|
pepper 'PROXY_NAME' saltutil.kill_all_jobs |
|