puppet之dashboard安装及优化
puppet的dashboard可以比较直观的看到puppet运行详细状态。也是puppet中比较重要的一块,那么我们开始安装和优化它!
pptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/puppet/multi-environment]2015-04-1715:59:07root@pts/0#yuminstallruby-mysqlmysql-serverpuppet-dashboard-yroot@pts/0#/etc/rc.d/init.d/mysqldrestartStoppingmysqld:[OK]Startingmysqld:[OK]pptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/puppet/multi-environment]2015-04-1716:06:10root@pts/0#chkconfigmysqldonpptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/puppet/multi-environment]2015-04-1716:06:17root@pts/0#mysqladmin-urootpasswordyypuppet.compptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/puppet/multi-environment]2015-04-1716:06:23root@pts/0#mysql-pyypuppet.comWelcometotheMySQLmonitor.Commandsendwith;or\g.YourMySQLconnectionidis5Serverversion:5.1.73SourcedistributionCopyright(c)2000,2013,Oracleand/oritsaffiliates.Allrightsreserved.OracleisaregisteredtrademarkofOracleCorporationand/oritsaffiliates.Othernamesmaybetrademarksoftheirrespectiveowners.Type'help;'or'\h'forhelp.Type'\c'toclearthecurrentinputstatement.mysql>createdatabasedashboardcharactersetutf8;QueryOK,1rowaffected(0.00sec)mysql>grantallondashboard.*to'dashboard'@'localhost'identifiedby"yypuppet.com";QueryOK,0rowsaffected(0.00sec)mysql>flushprivileges;QueryOK,0rowsaffected(0.00sec)mysql>pptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/puppet/multi-environment]2015-04-1718:12:48root@pts/0#mysql-udashboard-pyypuppet.comWelcometotheMySQLmonitor.Commandsendwith;or\g.YourMySQLconnectionidis767Serverversion:5.1.73SourcedistributionCopyright(c)2000,2013,Oracleand/oritsaffiliates.Allrightsreserved.OracleisaregisteredtrademarkofOracleCorporationand/oritsaffiliates.Othernamesmaybetrademarksoftheirrespectiveowners.Type'help;'or'\h'forhelp.Type'\c'toclearthecurrentinputstatement.mysql>quitByepptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/yum.repos.d]2015-04-1718:24:08root@pts/0#rpm-ivhhttp://yum.puppetlabs.com/puppetlabs-release-el-6.noarch.rpmRetrievinghttp://yum.puppetlabs.com/puppetlabs-release-el-6.noarch.rpmwarning:/var/tmp/rpm-tmp.BLTu8l:HeaderV4RSA/SHA1Signature,keyID4bd6ec30:NOKEYPreparing...###########################################[100%]1:puppetlabs-release###########################################[100%]root@pts/0#vim/usr/share/puppet-dashboard/config/database.ymlpptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/etc/yum.repos.d]2015-04-1718:31:46root@pts/0#cd/usr/share/puppet-dashboardpptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[/usr/share/puppet-dashboard]2015-04-1718:31:58root@pts/0#rakegems:refresh_specsroot@pts/0#mysql-udashboard-pyypuppet.comWelcometotheMySQLmonitor.Commandsendwith;or\g.YourMySQLconnectionidis114Serverversion:5.1.73SourcedistributionCopyright(c)2000,2013,Oracleand/oritsaffiliates.Allrightsreserved.OracleisaregisteredtrademarkofOracleCorporationand/oritsaffiliates.Othernamesmaybetrademarksoftheirrespectiveowners.Type'help;'or'\h'forhelp.Type'\c'toclearthecurrentinputstatement.mysql>usedashboard;ReadingtableinformationforcompletionoftableandcolumnnamesYoucanturnoffthisfeaturetogetaquickerstartupwith-ADatabasechangedmysql>showtables;+------------------------------+|Tables_in_dashboard|+------------------------------+|delayed_job_failures||delayed_jobs|。。。pptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[~]2015-04-2013:56:31root@pts/0#/etc/init.d/httpdstoppptserver_wangsu_bj_192.168.3.68.centos.yypuppet.com[~]2015-04-2013:56:34root@pts/0#/etc/rc.d/init.d/puppetmasterrestartStoppingpuppetmaster:[OK]Startingpuppetmaster:[OK]root@pts/0#/etc/rc.d/init.d/puppet-dashboardstartStartingPuppetDashboard:=>BootingWEBrick=>Rails2.3.17applicationstartingonhttp://0.0.0.0:3000[OK]
访问http://192.168.3.68:3000/ 即可看到dashboard页面。
目前的架构
访问http://192.168.3.68:3000/ 即可看到dashboard页面。还有比较的大的优化空间,本文暂略过,以后补充哦
使用nginx+passenger:
http://www.watters.ws/mediawiki/index.php/Configure_puppet_master_using_nginx_and_mod_passenger
http://z0mbix.github.io/blog/2012/03/01/use-nginx-and-passenger-to-power-your-puppet-master/
http://tech.ddvip.com/2013-05/1367938652195038.html
http://www.tuicool.com/articles/Fz2URv
声明:本站所有文章资源内容,如无特殊说明或标注,均为采集网络资源。如若本站内容侵犯了原著者的合法权益,可联系本站删除。