- 论坛徽章:
- 0
|
一、命令puppet 用于执行用户所写独立的mainfests文件用法:puppet [-h|--help] [-V|--version] [-d|--debug] [-v|--verbose][--detailed-exitcodes] [-l|--logdest ]# puppet -l /tmp/manifest.log manifest.pppuppetd 运行在被管理主机上的客户端程序用法:puppetd [-D|--daemonize|--no-daemonize] [-d|--debug] [--disable] [--enable][-h|--help] [--fqdn ] [-l|--logdest syslog||console][-o|--onetime] [--serve ] [-t|--test] [--noop][-V|--version] [-v|--verbose] [-w|--waitforcert ]# puppetd –server puppet.domain.compuppetmasterd 运行在管理机上的服务器程序用法:puppetmasterd [-D|--daemonize|--no-daemonize] [-d|--debug] [-h|--help][-l|--logdest |console|syslog] [--nobucket] [--nonodes][-v|--verbose] [-V|--version]# puppetmasterdpuppetca puppet认证程序用法:puppetca [-h|--help] [-V|--version] [-d|--debug] [-v|--verbose][-g|--generate] [-l|--list] [-s|--sign] [-r|--revoke][-p|--print] [-c|--clean] [--verify] [host]# puppetca -lculain.madstop.com# puppetca -s culain.madstop.compuppetrun 用于连接客户端,强制运行在本地配置文件下用法:puppetrun [-a|--all] [-c|--class ] [-d|--debug] [-f|--foreground][-h|--help] [--host ] [--no-fqdn] [--ignoreschedules][-t|--tag ] [--test] [-p|--ping]# puppetrun -p 10 –host host1 –host host2 -t remotefile -t webserverfilebucket 客户端用于发送文件到puppet file bucket的工具用法:filebucket [-h|--help] [-V|--version] [-d|--debug] [-v|--verbose][-l|--local] [-r|--remote][-s|--server ] [-b|--bucket ] …# filebucket -b /tmp/filebucket /my/fileralsh 转换配置信息到puppet配置代码用法:ralsh [-h|--help] [-d|--debug] [-v|--verbose] [-e|--edit] [-H|--host ][-p|--param] [-t|--types] type# ralsh user lukeuser { ‘luke’:home => ‘/home/luke’,uid => ‘100′,ensure => ‘present’,comment => ‘Luke Kanies,,,’,gid => ‘1000′,shell => ‘/bin/bash’,groups => ['sysadmin','audio','video','puppet']}puppetdoc 打印puppet参考文档用法:puppetdoc [-a|--all] [-h|--help] [-o|--outputdir ][-m|--mode ][-r|--reference ] [manifest-file]# puppetdoc -r type > /tmp/type_reference.rst# puppetdoc –outputdir /tmp/rdoc –mode rdoc /path/to/manifests# puppetdoc /etc/puppet/manifests/site.pp生成服务器与客户端的配置文件# puppetmasterd –genconfig > puppet.conf# puppetd –genconfig > puppet.conf二、配置文件puppet.conf默认情况下,配置文件位于/etc/puppet目录下,文件名为puppet.conf配置文件命名空间main 通用配置选项puppetd 客户端配置选项puppetmasterd 服务端配置选项main命名空间选项confdir 配置文件目录,默认在/etc/puppetvardir 动态数据目录,默认在/var/puppetlogdir 日志目录,默认在$vardir/logrundir puppet PID目录,默认在$vardir/runstatedir state目录,默认在$vardir/statestatefile state文件,默认在$statedir/state.yamlssldir SSL证书目录,默认在$confdir/ssltrace 发生错误时显示跟踪信息,默认falsefiletimeout 检测配置文件状态改变的时间周期,单位秒,默认15秒syslogfacility 指定syslog功能为user级,默认为daemon级puppetmasterd命名空间选项user 后台进程执行的用户group 后台进程执行的组mainfestdir mainfests文件存储目录,默认为$confdir/mainfestsmainfest mainfest站点文件的名字,默认为site.ppbindaddress 后台进程绑定的网卡地址接口masterport 后台进程执行的端口,默认为8140puppet命名空间选项server puppet puppet服务器,默认为puppetruninterval seconds puppet应用配置的时间间隔,默认1800秒(0.5小时)puppetdlockfie file puppet lock文件位置,默认$statedir/puppetdlockpuppetport port 后台进程执行的端口,默认8139来源:
http://www.puppeter.cn/?p=636
作者:骡骡 //总结的非常不错!在此表示感谢!
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u3/99907/showart_2162416.html |
|