Modules
1:查看所有module列表:
salt 'jcfx-4' sys.list_modules

jcfx-4:
- acl
- aliases
- alternatives
- apache
- archive
- artifactory
- at
- beacons
- bigip
- blockdev
- bridge
- btrfs

2:查看指定module的所有function
salt 'jcfx-4' sys.list_functions cp

jcfx-4:
- cp.cache_dir
- cp.cache_file
- cp.cache_files
- cp.cache_local_file
- cp.cache_master
- cp.get_dir
- cp.get_file
- cp.get_file_str
- cp.get_template
- cp.get_url
- cp.hash_file
- cp.is_cached
- cp.list_master
- cp.list_master_dirs
- cp.list_master_symlinks
- cp.list_minion
- cp.list_states
- cp.push
- cp.push_dir
- cp.recv

3:查看指定module用法:
salt 'jcfx-4' sys.doc cp.get_file

cp.get_file:

Used to get a single file from the salt master

CLI Example:

salt '*' cp.get_file salt://path/to/file /minion/dest

Template rendering can be enabled on both the source and destination file
names like so:

salt '*' cp.get_file "salt://{{grains.os}}/vimrc" /etc/vimrc template=jinja

This example would instruct all Salt minions to download the vimrc from a
directory with the same name as their os grain and copy it to /etc/vimrc

For larger files, the cp.get_file module also supports gzip compression.
Because gzip is CPU-intensive, this should only be used in scenarios where
the compression ratio is very high (e.g. pretty-printed JSON or YAML
files).

Use the *gzip* named argument to enable it. Valid values are 1..9, where 1
is the lightest compression and 9 the heaviest. 1 uses the least CPU on
the master (and minion), 9 uses the most.

States
1:查看所有states列表:
salt 'jcfx-4' sys.list_state_modules

jcfx-4:
- acl
- alias
- alternatives
- apache
- archive
- artifactory
- at
- beacon
- blockdev
- buildout
- cloud
- cmd
- composer
- cron

2:查看指定states的所有function
salt 'jcfx-4' sys.list_state_functions file

jcfx-4:
- file.absent
- file.accumulated
- file.append
- file.blockreplace
- file.comment
- file.copy
- file.directory
- file.exists
- file.line
- file.managed
- file.missing
- file.mknod
- file.mod_run_check_cmd
- file.patch
- file.prepend
- file.recurse
- file.rename
- file.replace
- file.serialize
- file.symlink
- file.touch
- file.uncomment

3:查看指定states用法:
salt 'jcfx-4' sys.state_doc file
输出略;
4:查看states指定function用法:
salt 'jcfx-4' sys.state_doc file.managed
输出略;

SaltStack管理从这里开始的更多相关文章

  1. saltstack管理八之常用执行模块

    所有执行模块: http://docs.saltstack.cn/zh_CN/latest/ref/states/all/index.html 常用模块:cmd, cron, file, mount, ...

  2. 四、saltstack如何管理对象?

    实验前环境: [root@super65 ~]# salt-key -L[root@super65 ~]# salt-key -a super65.cn -y salt管理对象简介: saltstac ...

  3. redis的管理工具

    phpredisadmin工具 rdbtools管理工具 saltstack管理redis 通过codis完成redis管理 一:phpredisadmin工具:类似于mysqladmin管理mysq ...

  4. saltstack运维软件

    一.saltstack介绍 1.介绍 SaltStack管理工具允许管理员对多个操作系统创建一个一致的管理系统,包括VMware vSphere环境. SaltStack是一个服务器基础架构集中化管理 ...

  5. SaltStack自动化运维工具

    一.SaltStack的了解 SaltStack管理工具允许管理员对多个操作系统创建一个一致的管理系统,包括VMware vSphere环境. SaltStack作用于仆从和主拓扑.SaltStack ...

  6. 自动化运维与Saltstack

    一.自动化运维介绍 1.自动化运维产生背景   传统的IT运维是将数据中心中的网络设备.服务器.数据库.中间件.存储.虚拟化.硬件等资源进行统一监控,当资源出现告警时,运维人员通过工具或者基于经验进行 ...

  7. SaltStack(自动化运维工具)

    SaltStack管理工具允许管理员对多个操作系统创建一个一致的管理系统,包括VMware vSphere环境.SaltStack作用于仆从和主拓扑.SaltStack与特定的命令结合使用可以在一个或 ...

  8. 七天学会 SALT STACK 自动化运维 (1)

    七天学会 SALT STACK 自动化运维 (1) 简单理解 SALTSTACK 安装与配置 基本的使用方法 结束语 引用资源 简单理解 SALT STACK 笔者是初次接触 自动化运维 这一技术领域 ...

  9. CEPH监控软件

    概述 目前主流的Ceph开源监控软件有:Calamari.VSM.Inkscope.Ceph-Dash.Zabbix等,下面简单介绍下各个开源组件. Calamari 概述 Calamari对外提供了 ...

随机推荐

  1. hibernate annotation注解 columnDefinition用法

    column注解中的columnDefinition属性用于覆盖数据库DDL中的语句:(MySql) @Column(columnDefinition = "int(11) DEFAULT ...

  2. http://www.cnblogs.com/amboyna/archive/2008/03/08/1096024.html

    http://www.cnblogs.com/amboyna/archive/2008/03/08/1096024.html

  3. 你不知道的pogo pin连接器

    pogo pin连接器是一种带弹簧的探针式连接器,pogo pin连接器结构看起来非常简单,但其制造工艺要求极其的精细与复杂,从车床加工,电镀,组装等每道工序,如果没有一个有良好品质控制和完善的制造水 ...

  4. 安装Hadoop系列 — eclipse plugin插件编译安装配置

    [一].环境参数 eclipse-java-kepler-SR2-linux-gtk-x86_64.tar.gz //现在改为eclipse-jee-kepler-SR2-linux-gtk-x86_ ...

  5. Java API ——Object类

    1.Object类概述 1)类层次结构的根类.       2)所有类都直接或者间接的继承自该类. 3)构造方法            · public Object()            · 子 ...

  6. PHP 简单的加密解密算法

    <?php /** * * @创建时间:2015-3-12 下午2:07:33 * @作者:YuMing * @描述:异或加密解密类 */ class Yihuo extends CI_Cont ...

  7. *gravity的取值详表

    android有 android:layout_gravity 和 android:gravity,前者设置相对父控件布局,后者是设置自己内部的控件的布局. Value Description top ...

  8. C语言计算程序运行时间

    #include<stdio.h>#include<stdlib.h> #include "time.h" int main( void )  {     ...

  9. poj 3007 Organize Your Train part II(二叉排序树)

    题目:http://poj.org/problem?id=3007 题意:按照图示的改变字符串,问有多少种..字符串.. 思路:分几种排序的方法,,刚开始用map 超时(map效率不高啊..),后来搜 ...

  10. 3月下旬剩余poj题解

    poj1700 数学推导+简单dp poj2390 水题不说什么了 poj3260 先对找的钱做完全背包,在对能付的钱做多重背包,注意这道题能付的钱数的上界 poj2516 裸的最小费用最大流了没什么 ...