{"id":3328,"date":"2014-05-07T15:49:02","date_gmt":"2014-05-07T07:49:02","guid":{"rendered":"http:\/\/blog.hmouse.tk\/?p=3328"},"modified":"2015-06-07T10:57:14","modified_gmt":"2015-06-07T02:57:14","slug":"foreman%e7%9b%b8%e5%85%b3","status":"publish","type":"post","link":"https:\/\/www.hmouse.cn\/?p=3328","title":{"rendered":"foreman\u76f8\u5173"},"content":{"rendered":"<p>\u53c2\u8003url:<a title=\"http:\/\/theforeman.org\/manuals\/1.4\/quickstart_guide.html\" href=\"http:\/\/theforeman.org\/manuals\/1.4\/quickstart_guide.html\">http:\/\/theforeman.org\/manuals\/1.4\/quickstart_guide.html<\/a><\/p>\n<p>foreman\u662fpuppet\u7ba1\u7406\u76f8\u5173\u3002<\/p>\n<p>\u5b89\u88c5<\/p>\n<p>Red Hat Enterprise Linux 6 and derivatives (CentOS, Scientific Linux)<\/p>\n<ul>\n<li><a href=\"http:\/\/fedoraproject.org\/wiki\/EPEL\/FAQ#How_can_I_install_the_packages_from_the_EPEL_software_rep\">EPEL<\/a> is required<\/li>\n<li>On RHEL 6, additionally the Optional and RHSCL 1.0 repositories\/channels:\n<ul>\n<li><code>yum-config-manager --enable rhel-6-server-optional-rpms rhel-server-rhscl-6-rpms<\/code><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>For <strong>Red Hat variants<\/strong>, run this (replace &#8216;el6&#8217; with &#8216;f19&#8217; if appropriate):<\/p>\n<p><code>yum -y install http:\/\/yum.theforeman.org\/releases\/1.4\/el6\/x86_64\/foreman-release.rpm yum -y install foreman-installer <\/code><\/p>\n<p>&nbsp;<\/p>\n<h6>Running the installer<\/h6>\n<pre><code>foreman-installer<\/code><\/pre>\n<p><span style=\"background-color: #ff0000;\">\u9ed8\u8ba4\u7684\u8d26\u53f7\u548c\u5bc6\u7801\uff1a<em>\u9ed8\u8ba4<\/em>\u7528\u6237 admin; <em>\u9ed8\u8ba4\u5bc6\u7801<\/em> changeme<\/span><\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman \u5bfc\u5165\u5df2\u6709\u4e3b\u673a<\/span><br \/>\n[root@puppet ~]#\u00a0 foreman-rake\u00a0\u00a0 puppet:import:hosts_and_facts<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman \u62a5\u9519Error retrieving node redis71.test.com: Net::HTTPForbidden<\/span><\/p>\n<p>[root@puppet conf.d]# \/etc\/puppet\/node.rb redis71.test.com<br \/>\n&#8212; false<br \/>\nError retrieving node redis71.test.com: Net::HTTPForbidden<\/p>\n<p>\u67e5\u770b\u9519\u8bef\u65e5\u5fd7<\/p>\n<p>tail -f \/var\/log\/foreman\/production.log<\/p>\n<p>No smart proxy server found on [&#8220;puppet.test.com&#8221;] and is not in trusted_puppetmaster_hosts<br \/>\nRedirected to <a href=\"https:\/\/puppet.test.com\/users\/login\">https:\/\/puppet.test.com\/users\/login<\/a><br \/>\nFilter chain halted as :require_puppetmaster_or_login rendered or redirected<br \/>\nCompleted 403 Forbidden in 107ms (ActiveRecord: 1.6ms)<\/p>\n<p>\u53c2\u8003\u5b98\u7f51\uff1a<a title=\"http:\/\/theforeman.org\/manuals\/1.2\/\" href=\"http:\/\/theforeman.org\/manuals\/1.2\/\">http:\/\/theforeman.org\/manuals\/1.2\/<\/a><\/p>\n<p><em>No smart proxy server found on $HOST<\/em> indicates Foreman has no smart proxy registered for the source host, add it to the Smart Proxies page in Foreman. A common cause of this issue is the hostname in the URL doesn&#8217;t match the hostname seen here in the log file &#8211; change the registered proxy URL to match. If no smart proxy is available or can be installed, use <em>trusted_puppetmaster_hosts<\/em> and add this hostname to the whitelist.<\/p>\n<p>\u53d1\u73b0hostname\u662f\u4e0d\u5bf9\u7684 \u3002\u5c06hostname\u66f4\u6539\u6210 puppet.test.com ,\u7136\u540e\u91cd\u542f\u89e3\u51b3\u95ee\u9898\u3002\uff08\u5176\u5b9e\u540e\u6765\u53d1\u73b0\u6ca1\u6709\u89e3\u51b3\u95ee\u9898\uff09<\/p>\n<p>\u540e\u6765\u53d1\u73b0\u4ee5\u4e0a\u89e3\u51b3\u65b9\u6848\u4e0d\u884c\uff0c\u53d1\u73b0use <em>trusted_puppetmaster_hosts<\/em> and add this hostname to the whitelist.\u6211\u5728\u8bbe\u7f6e\u4e2d\u53d1\u73b0\u6709trusted_puppetmaster_hosts\u00a0 \u6dfb\u52a0\u4e2a\u5373\u53ef\u3002<\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/05\/image.png\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"image\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/05\/image_thumb.png\" alt=\"image\" width=\"244\" height=\"137\" border=\"0\" \/><\/a><\/p>\n<p><span style=\"color: #ff0000;\">foreman\u00a0 \u8fd0\u884cpuppet \u7684\u95ee\u9898<\/span><\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image.png\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"image\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image_thumb.png\" alt=\"image\" width=\"244\" height=\"66\" border=\"0\" \/><\/a><\/p>\n<p>\u5176\u5b9e\u662f\u901a\u8fc7 puppet kick \u53bb\u5b9e\u73b0\u5ba2\u6237\u7aef\u7684\u66f4\u65b0\u3002\u9047\u5230\u4e00\u4f4d\u9ad8\u4ebaNewpTone\u00a0 \u7684\u6307\u70b9\uff0c\u8bf4\u8bf4\u6211\u7684\u7406\u89e3\u5427\u3002<\/p>\n<p>puppet run \uff08\u5176\u5b9e\u662fpuppet kick \uff09 \u4e0e mcollective\u7684\u5bf9\u6bd4<\/p>\n<p>\u4ee5\u4e0b\u662fNewpTone\u00a0 \u7684\u89e3\u91ca\u3002\u5f88\u8d34\u5207\u3002<\/p>\n<p>++++++++++++<\/p>\n<p>puppet run\u4e5f\u5c31\u662f\u5c01\u88c5\u4e86puppet kick,\u662fpuppet 2.x\u7248\u672c\u4e2d\u4e3a\u4e86\u5f25\u8865\u6ca1\u6709\u7f16\u6392\u5de5\u5177\uff0c\u641e\u5f97\u4e00\u4e2a\u7279\u6027<\/p>\n<p>mcollective\u662f\u540e\u6765\u51fa\u73b0\u7684\u7f16\u7a0b\u5de5\u5177\uff0c\u652f\u6301\u591a\u79cdcms\u5de5\u5177\uff0c\u4e5f\u5305\u62ecpuppet\uff0c<\/p>\n<p>\u6240\u4ee5\u4ece3.x\u5f00\u59cb\uff0cpuppet kick\u88ab\u6807\u8bb0\u4e3a\u5e9f\u5f03\uff0c<\/p>\n<p>\u56e0\u4e3aMcollective\u6bd4puppet kick\u5b9e\u73b0\u7684\u529f\u80fd\u66f4\u5f3a\u5927\uff0c\u72ec\u7acb\u51fa\u6765\u4f5c\u4e3a\u4e00\u5957Orchestration framework\u3002<\/p>\n<p>puppet kick\u5bf9\u4e8emco\u6765\u8bf4\uff0c\u53ea\u662f\u4e00\u4e2aplugin\u800c\u5df2<\/p>\n<p>\u6700\u65b0\u7248\u672c\u7684foreman\u6709\u4e00\u4e2a\u63d2\u4ef6\u652f\u6301mco plugin\uff0c<\/p>\n<p>\u4f46\u662f\u6709bug\uff0c\u9700\u8981\u7a0d\u5fae\u6539\u4e0b\u90a3\u4e2a\u63d2\u4ef6\u7684\u4ee3\u7801<\/p>\n<p>\u4f60\u70b9foreman\u9762\u677f\u4e0a\u7684run puppet\u6309\u94ae\uff0c\u5b9e\u9645\u7684\u6267\u884c\u662f\u8fd9\u6837\u7684: foreman -&gt; foreman-proxy \u2013&gt; puppet<\/p>\n<p>++++++++++++<\/p>\n<p>&nbsp;<\/p>\n<p>\u5148\u8bf4\u4e0b\u600e\u4e48\u5b9e\u73b0 puppet kick \u4e0e foreman \u7684\u6574\u5408\u5427\u3002<\/p>\n<p>\u76f8\u5173url\uff1a<a title=\"http:\/\/www.cnblogs.com\/yuxc\/archive\/2012\/09\/28\/2706631.html\" href=\"http:\/\/www.cnblogs.com\/yuxc\/archive\/2012\/09\/28\/2706631.html\">http:\/\/www.cnblogs.com\/yuxc\/archive\/2012\/09\/28\/2706631.html<\/a><\/p>\n<p>1.\u9996\u5148\uff0c\u9700\u8981\u5728Foreman\u7684setting\u4e2d\u5c06puppetrun\u8bbe\u4e3atrue<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/pic002.cnblogs.com\/images\/2012\/288756\/2012092809311422.png\" alt=\"\" \/><\/p>\n<p>2.\u7136\u540e\u914d\u7f6e\u4f60\u7684puppet agent\u8282\u70b9\uff0c\u5728puppet.conf\u91cc\u6dfb\u52a0\u4e00\u884c\uff1a<\/p>\n<pre>listen = true<\/pre>\n<p>3.\u914d\u7f6eauth.conf\uff1a<\/p>\n<pre>path \/run \r\nmethod save \r\nallow * \r\npath \/ \r\nauth any<\/pre>\n<p>OK\uff0c\u5f00\u542fpuppet\u8fdb\u7a0b\u3002\u70b9\u51fbRun puppet\uff0c\u6267\u884c\u5b8c\u6210\u3002\u5982\u679c\u63d0\u793aNo proxy found\uff0c\u8bf7\u70b9Edit\u7136\u540e\u70b9submit\u66f4\u65b0\u6570\u636e\u5e93\uff0c\u8fd9\u662f\u4e00\u4e2a\u5df2\u77e5\u7684Bug\u3002<\/p>\n<p>\u6211\u5728\u64cd\u4f5c\u7684\u65f6\u5019\u9047\u5230\u4e00\u4e2a\u95ee\u9898\uff1a<\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/UCAFJ2M3PQ6NG7CE.jpg\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"UC{AF)J{2[M3~PQ6N$]G7CE\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/UCAFJ2M3PQ6NG7CE_thumb.jpg\" alt=\"UC{AF)J{2[M3~PQ6N$]G7CE\" width=\"244\" height=\"95\" border=\"0\" \/><\/a><\/p>\n<p>\u5176\u5b9e\u540e\u6765\u53d1\u73b0hostname\u7684\u95ee\u9898\uff0c\u5c06hostname \u6362\u6210 puppet.test.com \u5c31\u597d\u4e86\u3002<\/p>\n<p>\u8fd8\u6709\u4e00\u4e2a\u95ee\u9898\u5c31\u662f\u5f88\u70e6\u4eba\u7684 puppet kick \u7684\u95ee\u9898\u3002<\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image1.png\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"image\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image_thumb1.png\" alt=\"image\" width=\"244\" height=\"43\" border=\"0\" \/><\/a><\/p>\n<p>status is running<br \/>\nHost cobar3.test.com is already running<br \/>\ncobar3.test.com finished with exit code 3<\/p>\n<p>\u540e\u6765\u5728\u7f51\u4e0a\u53d1\u73b0\u4e00\u4e2a\u6587\u7ae0\uff1a<a title=\"http:\/\/www.51testing.com\/html\/00\/130600-853955.html\" href=\"http:\/\/www.51testing.com\/html\/00\/130600-853955.html\">http:\/\/www.51testing.com\/html\/00\/130600-853955.html<\/a><\/p>\n<p>14\u3001puppet kick\u4e3b\u52a8\u901a\u77e5\u5ba2\u6237\u7aef\u63d0\u793a\u9519\u8bef\u53f73<\/p>\n<p>\u95ee\u9898\u63cf\u8ff0\uff1a<\/p>\n<p>puppet kick\u6267\u884c\u4e00\u6b21\u540e\uff0c\u518d\u6b21\u6267\u884c\uff0c\u4f1a\u63d0\u793a\u9519\u8bef\u53f73\u3002<\/p>\n<p># puppet kick -p 10 &#8211;host puppetclient1.com<\/p>\n<p>Warning: Puppet kick is deprecated. See http:\/\/links.puppetlabs.com\/puppet-kick-deprecation<\/p>\n<p>Warning: Failed to load ruby LDAP library. LDAP functionality will not be available<\/p>\n<p>Triggering puppetclient1.com<\/p>\n<p>Getting status<\/p>\n<p>status is running<\/p>\n<p>Host puppetclient1.com is already running<\/p>\n<p>puppetclient1.com finished with exit code 3<\/p>\n<p>Failed: puppetclient1.com<\/p>\n<p>\u8fd9\u65f6\u5ba2\u6237\u7aef\u6267\u884c# puppet agent -t<\/p>\n<p>Notice: Ignoring &#8211;listen on onetime run<\/p>\n<p>Notice: Run of Puppet configuration client already in progress; skipping\u00a0 (\/var\/lib\/puppet\/state\/agent_catalog_run.lock exists)<\/p>\n<p>\u89e3\u51b3\u65b9\u6cd5\uff1a<\/p>\n<p>\/var\/lib\/puppet\/state\/agent_catalog_run.lock\u5b58\u653e\u7684\u662fpuppet agent\u8fdb\u7a0b\u7684pid<\/p>\n<p>\u4f7f\u7528puppet agent &#8211;no-client\u65b9\u5f0f\u8fdb\u884c\u542f\u52a8\uff0c\u4f1a\u751f\u6210\u8be5lock\u6587\u4ef6\uff1b<\/p>\n<p>\u65b9\u6cd5\u4e00\uff1a<\/p>\n<p>rm -rf \/var\/lib\/puppet\/state\/agent_catalog_run.lock<\/p>\n<p>\u4f46\u6b64\u65b9\u6cd5\u4e0d\u65b9\u4fbf\uff0c\u7279\u522b\u662f\u5728\u53ea\u4f7f\u7528puppet kick\u8fdb\u884c\u4e3b\u52a8\u901a\u77e5\u7684\u90e8\u7f72\u65b9\u6848\u4e2d\uff1b<\/p>\n<p>\u65b9\u6cd5\u4e8c\uff1a<\/p>\n<p>\u66f4\u65b0ruby\u4e3a2.0.0\u7248\u672c\uff0cfacter\/puppet\u4e5f\u9700\u8981\u518d\u91cd\u88c5\u6b21\uff1b<\/p>\n<p>\u4f7f\u7528ruby2.0.0\uff0c\u591a\u6b21\u6267\u884cpuppet kick\u90fd\u662f\u6b63\u5e38\uff0c\u4e0d\u4f1a\u751f\u6210\u8be5.lock\u6587\u4ef6\uff1b<\/p>\n<p>\u5177\u4f53\u539f\u56e0\u4e0d\u592a\u6e05\u695a\u4e86\uff0c\u4f46\u5b9e\u9a8c\u7ed3\u679c\u662f\u8fd9\u6837\u7684\u3002<\/p>\n<p>\u53ea\u6709\u65b9\u6cd5\u4e8c\uff0c\u624d\u80fd\u89e3\u51b3\uff0c\u5f88\u9ebb\u70e6\uff0c\u96be\u9053\u53ea\u80fd\u7528mcollective\uff1f<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman\u66f4\u6539name\u7684\u540d\u79f0\u6362\u6210hostname<\/span><\/p>\n<p>\u66f4\u6539 node.rb \u6587\u4ef6<\/p>\n<p>hostname\u00a0\u00a0\u00a0\u00a0 = puppet_facts[&#8216;values&#8217;][&#8216;fqdn&#8217;] || certname<\/p>\n<p>{&#8216;facts&#8217; =&gt; puppet_facts[&#8216;values&#8217;], &#8216;name&#8217; =&gt; hostname, &#8216;certname&#8217; =&gt; certname}<\/p>\n<p>\u56e0\u4e3a\u4ed6\u662f\u83b7\u53d6&#8217;fqdn&#8217;\u7684\u503c \u8d4b\u503c\u7ed9hostname\uff0c\u518d\u8d4b\u503c\u7ed9name<\/p>\n<p>\u53ef\u4ee5\u76f4\u63a5\u66f4\u6539\u6210<\/p>\n<p>hostname\u00a0\u00a0\u00a0\u00a0 = puppet_facts[&#8216;values&#8217;][hostname] || certname<\/p>\n<p>\u5373\u53ef\u3002\u6d4b\u8bd5name\u53d8\u6210\u4e86hostname\uff0c\u7136\u540e\u57df\u95ee\u9898\u4e5f\u53ef\u4ee5\u4e0d\u6307\u5b9a\u4e86\u3002<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman \u7684 mysql\u5b58\u50a8<\/span><\/p>\n<p>\u4e4b\u524d\u770b\u7f51\u4e0a\u6587\u6863\u6709\u5f88\u591a\u8bef\u5bfc\u4e86\u3002\u4ee5\u4e3aforeman\u5f88\u6e23\u3002\u540e\u6765\u53d1\u73b0\u90fd\u662f\u81ea\u5df1\u7684\u95ee\u9898\u3002<\/p>\n<p>\u5efa\u8bae\u53bb\u5b98\u7f51\u770b\uff1a<a title=\"http:\/\/theforeman.org\/manuals\/1.1\/index.html#3.5.3DatabaseSetup\" href=\"http:\/\/theforeman.org\/manuals\/1.1\/index.html#3.5.3DatabaseSetup\">http:\/\/theforeman.org\/manuals\/1.1\/index.html#3.5.3DatabaseSetup<\/a><\/p>\n<p>\u91cc\u9762\u8bf4\u4e86<\/p>\n<p>Edit your config\/database.yml and modify:<\/p>\n<pre><code>production:\r\n  adapter: mysql\r\n  database: puppet\r\n  username: puppet\r\n  password: password\r\n  host: localhost\r\n  socket: \"\/var\/run\/mysqld\/mysqld.sock\"\r\n<\/code><\/pre>\n<p><span style=\"color: #ff0000;\">If you use foreman 1.0 with foreman-mysql2 use &#8216;adapter: mysql2&#8217; instead<\/span><\/p>\n<p>\u5176\u4e2d\u8981\u6c42\u4f60\u88c5mysql2 \u6240\u4ee5\u914d\u7f6e\u4e2d adapter: mysql\u00a0 \u6362\u6210 adapter: mysql2<\/p>\n<p>\u9996\u5148\u4f60\u8981\u5b89\u88c5 yum -y install foreman-mysql*<\/p>\n<p>\u5b89\u88c5\u5b8c\u4e4b\u540e \u8bbf\u95ee\u9875\u9762 \u4f1a\u6709\u00a0 gem install activerecord-mysql2-adapter \u7684\u63d0\u793a\u3002<\/p>\n<p>\u6211\u901a\u8fc7gem install activerecord-mysql2-adapter\u00a0 \u5b89\u88c5\u4e86\uff0c\u5e76\u4e14\u901a\u8bf4gem list \u4e5f\u770b\u5230\u5b89\u88c5\u4e86\uff0c\u4e00\u76f4\u8fd8\u662f\u62a5gem install activerecord-mysql2-adapter\u00a0 \u7684\u9519\u8bef\uff0c\u4e4b\u524d\u4e00\u76f4\u6ca1\u60f3\u901a\uff0c\u540e\u6765\u53d1\u73b0 \u6211\u7684\u73af\u5883\u662f ruby193 \u800c\u4e0d\u662fruby \u3002\u6211\u5c1d\u8bd5\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 scl enable ruby193 &#8216;gem install rails&#8217; \u7136\u540e\u901a\u8fc7 scl enable ruby193 &#8216;gem list&#8217; \u770b\u5230\u5df2\u5b89\u88c5\u3002 \u91cd\u65b0\u767b\u5f55\u9875\u9762\u53d1\u73b0\u6ca1\u95ee\u9898\u4e86\u3002<\/p>\n<p>PS\uff1a \u7f51\u4e0a\u6709\u8ddf\u591a\u7528 rake db:migrate \u521d\u59cb\u5316\u7684 \uff0c\u6211\u7684rake\u597d\u50cf\u6709\u95ee\u9898\uff0c\u4e00\u76f4\u6ca1\u521d\u59cb\u5316\uff0c\u4f46\u662f\u901a\u8fc7\u9875\u9762\u8bbf\u95ee\u53ef\u4ee5\u76f4\u63a5\u521d\u59cb\u5316\uff0c\u5f88\u667a\u80fd\u3002<\/p>\n<p>\u611f\u609f\uff1a<\/p>\n<p>1\uff1a\u4e00\u5b9a\u8981\u770b\u73af\u5883\uff0c\u5982\u679c\u7a0b\u5e8f\u8fd8\u662f\u63d0\u793a\u540c\u6837\u7684\u9519\u8bef\uff0c\u53ef\u80fd\u4f60\u7684\u73af\u5883\u4e0d\u5bf9\u3002<\/p>\n<p>2\uff1a\u8981\u591a\u770b\u5b98\u7f51\u6587\u6863\uff0c\u7f51\u4e0a\u7684\u6587\u6863\u53ef\u80fd\u6709\u65f6\u4f1a\u6bd4\u8f83\u8001\uff0c\u4ece\u800c\u8bef\u5bfc\u4f60\u3002<\/p>\n<p>PS \u5207\u6362ruby<\/p>\n<pre>scl enable ruby193 bash<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u53c2\u8003url:<a title=\"http:\/\/theforeman.org\/manuals\/1.4\/quickstart_guide.html\" href=\"http:\/\/theforeman.org\/manuals\/1.4\/quickstart_guide.html\">http:\/\/theforeman.org\/manuals\/1.4\/quickstart_guide.html<\/a><\/p>\n<p>foreman\u662fpuppet\u7ba1\u7406\u76f8\u5173\u3002<\/p>\n<p>\u5b89\u88c5<\/p>\n<p>Red Hat Enterprise Linux 6 and derivatives (CentOS, Scientific Linux)<\/p>\n<ul>\n<li><a href=\"http:\/\/fedoraproject.org\/wiki\/EPEL\/FAQ#How_can_I_install_the_packages_from_the_EPEL_software_rep\">EPEL<\/a> is required<\/li>\n<li>On RHEL 6, additionally the Optional and RHSCL 1.0 repositories\/channels:\n<ul>\n<li><code>yum-config-manager --enable rhel-6-server-optional-rpms rhel-server-rhscl-6-rpms<\/code><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>For <strong>Red Hat variants<\/strong>, run this (replace &#8216;el6&#8217; with &#8216;f19&#8217; if appropriate):<\/p>\n<p><code>yum -y install http:\/\/yum.theforeman.org\/releases\/1.4\/el6\/x86_64\/foreman-release.rpm yum -y install foreman-installer <\/code><\/p>\n<p>&nbsp;<\/p>\n<h6>Running the installer<\/h6>\n<pre><code>foreman-installer<\/code><\/pre>\n<p><span style=\"background-color: #ff0000;\">\u9ed8\u8ba4\u7684\u8d26\u53f7\u548c\u5bc6\u7801\uff1a<em>\u9ed8\u8ba4<\/em>\u7528\u6237 admin; <em>\u9ed8\u8ba4\u5bc6\u7801<\/em> changeme<\/span><\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman \u5bfc\u5165\u5df2\u6709\u4e3b\u673a<\/span><br \/>\n[root@puppet ~]#\u00a0 foreman-rake\u00a0\u00a0 puppet:import:hosts_and_facts<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman \u62a5\u9519Error retrieving node redis71.test.com: Net::HTTPForbidden<\/span><\/p>\n<p>[root@puppet conf.d]# \/etc\/puppet\/node.rb redis71.test.com<br \/>\n&#8212; false<br \/>\nError retrieving node redis71.test.com: Net::HTTPForbidden<\/p>\n<p>\u67e5\u770b\u9519\u8bef\u65e5\u5fd7<\/p>\n<p>tail -f \/var\/log\/foreman\/production.log<\/p>\n<p>No smart proxy server found on [&#8220;puppet.test.com&#8221;] and is not in trusted_puppetmaster_hosts<br \/>\nRedirected to <a href=\"https:\/\/puppet.test.com\/users\/login\">https:\/\/puppet.test.com\/users\/login<\/a><br \/>\nFilter chain halted as :require_puppetmaster_or_login rendered or redirected<br \/>\nCompleted 403 Forbidden in 107ms (ActiveRecord: 1.6ms)<\/p>\n<p>\u53c2\u8003\u5b98\u7f51\uff1a<a title=\"http:\/\/theforeman.org\/manuals\/1.2\/\" href=\"http:\/\/theforeman.org\/manuals\/1.2\/\">http:\/\/theforeman.org\/manuals\/1.2\/<\/a><\/p>\n<p><em>No smart proxy server found on $HOST<\/em> indicates Foreman has no smart proxy registered for the source host, add it to the Smart Proxies page in Foreman. A common cause of this issue is the hostname in the URL doesn&#8217;t match the hostname seen here in the log file &#8211; change the registered proxy URL to match. If no smart proxy is available or can be installed, use <em>trusted_puppetmaster_hosts<\/em> and add this hostname to the whitelist.<\/p>\n<p>\u53d1\u73b0hostname\u662f\u4e0d\u5bf9\u7684 \u3002\u5c06hostname\u66f4\u6539\u6210 puppet.test.com ,\u7136\u540e\u91cd\u542f\u89e3\u51b3\u95ee\u9898\u3002\uff08\u5176\u5b9e\u540e\u6765\u53d1\u73b0\u6ca1\u6709\u89e3\u51b3\u95ee\u9898\uff09<\/p>\n<p>\u540e\u6765\u53d1\u73b0\u4ee5\u4e0a\u89e3\u51b3\u65b9\u6848\u4e0d\u884c\uff0c\u53d1\u73b0use <em>trusted_puppetmaster_hosts<\/em> and add this hostname to the whitelist.\u6211\u5728\u8bbe\u7f6e\u4e2d\u53d1\u73b0\u6709trusted_puppetmaster_hosts\u00a0 \u6dfb\u52a0\u4e2a\u5373\u53ef\u3002<\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/05\/image.png\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"image\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/05\/image_thumb.png\" alt=\"image\" width=\"244\" height=\"137\" border=\"0\" \/><\/a><\/p>\n<p><span style=\"color: #ff0000;\">foreman\u00a0 \u8fd0\u884cpuppet \u7684\u95ee\u9898<\/span><\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image.png\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"image\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image_thumb.png\" alt=\"image\" width=\"244\" height=\"66\" border=\"0\" \/><\/a><\/p>\n<p>\u5176\u5b9e\u662f\u901a\u8fc7 puppet kick \u53bb\u5b9e\u73b0\u5ba2\u6237\u7aef\u7684\u66f4\u65b0\u3002\u9047\u5230\u4e00\u4f4d\u9ad8\u4ebaNewpTone\u00a0 \u7684\u6307\u70b9\uff0c\u8bf4\u8bf4\u6211\u7684\u7406\u89e3\u5427\u3002<\/p>\n<p>puppet run \uff08\u5176\u5b9e\u662fpuppet kick \uff09 \u4e0e mcollective\u7684\u5bf9\u6bd4<\/p>\n<p>\u4ee5\u4e0b\u662fNewpTone\u00a0 \u7684\u89e3\u91ca\u3002\u5f88\u8d34\u5207\u3002<\/p>\n<p>++++++++++++<\/p>\n<p>puppet run\u4e5f\u5c31\u662f\u5c01\u88c5\u4e86puppet kick,\u662fpuppet 2.x\u7248\u672c\u4e2d\u4e3a\u4e86\u5f25\u8865\u6ca1\u6709\u7f16\u6392\u5de5\u5177\uff0c\u641e\u5f97\u4e00\u4e2a\u7279\u6027<\/p>\n<p>mcollective\u662f\u540e\u6765\u51fa\u73b0\u7684\u7f16\u7a0b\u5de5\u5177\uff0c\u652f\u6301\u591a\u79cdcms\u5de5\u5177\uff0c\u4e5f\u5305\u62ecpuppet\uff0c<\/p>\n<p>\u6240\u4ee5\u4ece3.x\u5f00\u59cb\uff0cpuppet kick\u88ab\u6807\u8bb0\u4e3a\u5e9f\u5f03\uff0c<\/p>\n<p>\u56e0\u4e3aMcollective\u6bd4puppet kick\u5b9e\u73b0\u7684\u529f\u80fd\u66f4\u5f3a\u5927\uff0c\u72ec\u7acb\u51fa\u6765\u4f5c\u4e3a\u4e00\u5957Orchestration framework\u3002<\/p>\n<p>puppet kick\u5bf9\u4e8emco\u6765\u8bf4\uff0c\u53ea\u662f\u4e00\u4e2aplugin\u800c\u5df2<\/p>\n<p>\u6700\u65b0\u7248\u672c\u7684foreman\u6709\u4e00\u4e2a\u63d2\u4ef6\u652f\u6301mco plugin\uff0c<\/p>\n<p>\u4f46\u662f\u6709bug\uff0c\u9700\u8981\u7a0d\u5fae\u6539\u4e0b\u90a3\u4e2a\u63d2\u4ef6\u7684\u4ee3\u7801<\/p>\n<p>\u4f60\u70b9foreman\u9762\u677f\u4e0a\u7684run puppet\u6309\u94ae\uff0c\u5b9e\u9645\u7684\u6267\u884c\u662f\u8fd9\u6837\u7684: foreman -&gt; foreman-proxy \u2013&gt; puppet<\/p>\n<p>++++++++++++<\/p>\n<p>&nbsp;<\/p>\n<p>\u5148\u8bf4\u4e0b\u600e\u4e48\u5b9e\u73b0 puppet kick \u4e0e foreman \u7684\u6574\u5408\u5427\u3002<\/p>\n<p>\u76f8\u5173url\uff1a<a title=\"http:\/\/www.cnblogs.com\/yuxc\/archive\/2012\/09\/28\/2706631.html\" href=\"http:\/\/www.cnblogs.com\/yuxc\/archive\/2012\/09\/28\/2706631.html\">http:\/\/www.cnblogs.com\/yuxc\/archive\/2012\/09\/28\/2706631.html<\/a><\/p>\n<p>1.\u9996\u5148\uff0c\u9700\u8981\u5728Foreman\u7684setting\u4e2d\u5c06puppetrun\u8bbe\u4e3atrue<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/pic002.cnblogs.com\/images\/2012\/288756\/2012092809311422.png\" alt=\"\" \/><\/p>\n<p>2.\u7136\u540e\u914d\u7f6e\u4f60\u7684puppet agent\u8282\u70b9\uff0c\u5728puppet.conf\u91cc\u6dfb\u52a0\u4e00\u884c\uff1a<\/p>\n<pre>listen = true<\/pre>\n<p>3.\u914d\u7f6eauth.conf\uff1a<\/p>\n<pre>path \/run \r\nmethod save \r\nallow * \r\npath \/ \r\nauth any<\/pre>\n<p>OK\uff0c\u5f00\u542fpuppet\u8fdb\u7a0b\u3002\u70b9\u51fbRun puppet\uff0c\u6267\u884c\u5b8c\u6210\u3002\u5982\u679c\u63d0\u793aNo proxy found\uff0c\u8bf7\u70b9Edit\u7136\u540e\u70b9submit\u66f4\u65b0\u6570\u636e\u5e93\uff0c\u8fd9\u662f\u4e00\u4e2a\u5df2\u77e5\u7684Bug\u3002<\/p>\n<p>\u6211\u5728\u64cd\u4f5c\u7684\u65f6\u5019\u9047\u5230\u4e00\u4e2a\u95ee\u9898\uff1a<\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/UCAFJ2M3PQ6NG7CE.jpg\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"UC{AF)J{2[M3~PQ6N$]G7CE\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/UCAFJ2M3PQ6NG7CE_thumb.jpg\" alt=\"UC{AF)J{2[M3~PQ6N$]G7CE\" width=\"244\" height=\"95\" border=\"0\" \/><\/a><\/p>\n<p>\u5176\u5b9e\u540e\u6765\u53d1\u73b0hostname\u7684\u95ee\u9898\uff0c\u5c06hostname \u6362\u6210 puppet.test.com \u5c31\u597d\u4e86\u3002<\/p>\n<p>\u8fd8\u6709\u4e00\u4e2a\u95ee\u9898\u5c31\u662f\u5f88\u70e6\u4eba\u7684 puppet kick \u7684\u95ee\u9898\u3002<\/p>\n<p><a href=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image1.png\"><img loading=\"lazy\" decoding=\"async\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-width: 0px;\" title=\"image\" src=\"https:\/\/www.hmouse.cn\/wp-content\/uploads\/2014\/06\/image_thumb1.png\" alt=\"image\" width=\"244\" height=\"43\" border=\"0\" \/><\/a><\/p>\n<p>status is running<br \/>\nHost cobar3.test.com is already running<br \/>\ncobar3.test.com finished with exit code 3<\/p>\n<p>\u540e\u6765\u5728\u7f51\u4e0a\u53d1\u73b0\u4e00\u4e2a\u6587\u7ae0\uff1a<a title=\"http:\/\/www.51testing.com\/html\/00\/130600-853955.html\" href=\"http:\/\/www.51testing.com\/html\/00\/130600-853955.html\">http:\/\/www.51testing.com\/html\/00\/130600-853955.html<\/a><\/p>\n<p>14\u3001puppet kick\u4e3b\u52a8\u901a\u77e5\u5ba2\u6237\u7aef\u63d0\u793a\u9519\u8bef\u53f73<\/p>\n<p>\u95ee\u9898\u63cf\u8ff0\uff1a<\/p>\n<p>puppet kick\u6267\u884c\u4e00\u6b21\u540e\uff0c\u518d\u6b21\u6267\u884c\uff0c\u4f1a\u63d0\u793a\u9519\u8bef\u53f73\u3002<\/p>\n<p># puppet kick -p 10 &#8211;host puppetclient1.com<\/p>\n<p>Warning: Puppet kick is deprecated. See http:\/\/links.puppetlabs.com\/puppet-kick-deprecation<\/p>\n<p>Warning: Failed to load ruby LDAP library. LDAP functionality will not be available<\/p>\n<p>Triggering puppetclient1.com<\/p>\n<p>Getting status<\/p>\n<p>status is running<\/p>\n<p>Host puppetclient1.com is already running<\/p>\n<p>puppetclient1.com finished with exit code 3<\/p>\n<p>Failed: puppetclient1.com<\/p>\n<p>\u8fd9\u65f6\u5ba2\u6237\u7aef\u6267\u884c# puppet agent -t<\/p>\n<p>Notice: Ignoring &#8211;listen on onetime run<\/p>\n<p>Notice: Run of Puppet configuration client already in progress; skipping\u00a0 (\/var\/lib\/puppet\/state\/agent_catalog_run.lock exists)<\/p>\n<p>\u89e3\u51b3\u65b9\u6cd5\uff1a<\/p>\n<p>\/var\/lib\/puppet\/state\/agent_catalog_run.lock\u5b58\u653e\u7684\u662fpuppet agent\u8fdb\u7a0b\u7684pid<\/p>\n<p>\u4f7f\u7528puppet agent &#8211;no-client\u65b9\u5f0f\u8fdb\u884c\u542f\u52a8\uff0c\u4f1a\u751f\u6210\u8be5lock\u6587\u4ef6\uff1b<\/p>\n<p>\u65b9\u6cd5\u4e00\uff1a<\/p>\n<p>rm -rf \/var\/lib\/puppet\/state\/agent_catalog_run.lock<\/p>\n<p>\u4f46\u6b64\u65b9\u6cd5\u4e0d\u65b9\u4fbf\uff0c\u7279\u522b\u662f\u5728\u53ea\u4f7f\u7528puppet kick\u8fdb\u884c\u4e3b\u52a8\u901a\u77e5\u7684\u90e8\u7f72\u65b9\u6848\u4e2d\uff1b<\/p>\n<p>\u65b9\u6cd5\u4e8c\uff1a<\/p>\n<p>\u66f4\u65b0ruby\u4e3a2.0.0\u7248\u672c\uff0cfacter\/puppet\u4e5f\u9700\u8981\u518d\u91cd\u88c5\u6b21\uff1b<\/p>\n<p>\u4f7f\u7528ruby2.0.0\uff0c\u591a\u6b21\u6267\u884cpuppet kick\u90fd\u662f\u6b63\u5e38\uff0c\u4e0d\u4f1a\u751f\u6210\u8be5.lock\u6587\u4ef6\uff1b<\/p>\n<p>\u5177\u4f53\u539f\u56e0\u4e0d\u592a\u6e05\u695a\u4e86\uff0c\u4f46\u5b9e\u9a8c\u7ed3\u679c\u662f\u8fd9\u6837\u7684\u3002<\/p>\n<p>\u53ea\u6709\u65b9\u6cd5\u4e8c\uff0c\u624d\u80fd\u89e3\u51b3\uff0c\u5f88\u9ebb\u70e6\uff0c\u96be\u9053\u53ea\u80fd\u7528mcollective\uff1f<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman\u66f4\u6539name\u7684\u540d\u79f0\u6362\u6210hostname<\/span><\/p>\n<p>\u66f4\u6539 node.rb \u6587\u4ef6<\/p>\n<p>hostname\u00a0\u00a0\u00a0\u00a0 = puppet_facts[&#8216;values&#8217;][&#8216;fqdn&#8217;] || certname<\/p>\n<p>{&#8216;facts&#8217; =&gt; puppet_facts[&#8216;values&#8217;], &#8216;name&#8217; =&gt; hostname, &#8216;certname&#8217; =&gt; certname}<\/p>\n<p>\u56e0\u4e3a\u4ed6\u662f\u83b7\u53d6&#8217;fqdn&#8217;\u7684\u503c \u8d4b\u503c\u7ed9hostname\uff0c\u518d\u8d4b\u503c\u7ed9name<\/p>\n<p>\u53ef\u4ee5\u76f4\u63a5\u66f4\u6539\u6210<\/p>\n<p>hostname\u00a0\u00a0\u00a0\u00a0 = puppet_facts[&#8216;values&#8217;][hostname] || certname<\/p>\n<p>\u5373\u53ef\u3002\u6d4b\u8bd5name\u53d8\u6210\u4e86hostname\uff0c\u7136\u540e\u57df\u95ee\u9898\u4e5f\u53ef\u4ee5\u4e0d\u6307\u5b9a\u4e86\u3002<\/p>\n<p><span style=\"background-color: #ff0000;\">foreman \u7684 mysql\u5b58\u50a8<\/span><\/p>\n<p>\u4e4b\u524d\u770b\u7f51\u4e0a\u6587\u6863\u6709\u5f88\u591a\u8bef\u5bfc\u4e86\u3002\u4ee5\u4e3aforeman\u5f88\u6e23\u3002\u540e\u6765\u53d1\u73b0\u90fd\u662f\u81ea\u5df1\u7684\u95ee\u9898\u3002<\/p>\n<p>\u5efa\u8bae\u53bb\u5b98\u7f51\u770b\uff1a<a title=\"http:\/\/theforeman.org\/manuals\/1.1\/index.html#3.5.3DatabaseSetup\" href=\"http:\/\/theforeman.org\/manuals\/1.1\/index.html#3.5.3DatabaseSetup\">http:\/\/theforeman.org\/manuals\/1.1\/index.html#3.5.3DatabaseSetup<\/a><\/p>\n<p>\u91cc\u9762\u8bf4\u4e86<\/p>\n<p>Edit your config\/database.yml and modify:<\/p>\n<pre><code>production:\r\n  adapter: mysql\r\n  database: puppet\r\n  username: puppet\r\n  password: password\r\n  host: localhost\r\n  socket: \"\/var\/run\/mysqld\/mysqld.sock\"\r\n<\/code><\/pre>\n<p><span style=\"color: #ff0000;\">If you use foreman 1.0 with foreman-mysql2 use &#8216;adapter: mysql2&#8217; instead<\/span><\/p>\n<p>\u5176\u4e2d\u8981\u6c42\u4f60\u88c5mysql2 \u6240\u4ee5\u914d\u7f6e\u4e2d adapter: mysql\u00a0 \u6362\u6210 adapter: mysql2<\/p>\n<p>\u9996\u5148\u4f60\u8981\u5b89\u88c5 yum -y install foreman-mysql*<\/p>\n<p>\u5b89\u88c5\u5b8c\u4e4b\u540e \u8bbf\u95ee\u9875\u9762 \u4f1a\u6709\u00a0 gem install activerecord-mysql2-adapter \u7684\u63d0\u793a\u3002<\/p>\n<p>\u6211\u901a\u8fc7gem install activerecord-mysql2-adapter\u00a0 \u5b89\u88c5\u4e86\uff0c\u5e76\u4e14\u901a\u8bf4gem list \u4e5f\u770b\u5230\u5b89\u88c5\u4e86\uff0c\u4e00\u76f4\u8fd8\u662f\u62a5gem install activerecord-mysql2-adapter\u00a0 \u7684\u9519\u8bef\uff0c\u4e4b\u524d\u4e00\u76f4\u6ca1\u60f3\u901a\uff0c\u540e\u6765\u53d1\u73b0 \u6211\u7684\u73af\u5883\u662f ruby193 \u800c\u4e0d\u662fruby \u3002\u6211\u5c1d\u8bd5\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 scl enable ruby193 &#8216;gem install rails&#8217; \u7136\u540e\u901a\u8fc7 scl enable ruby193 &#8216;gem list&#8217; \u770b\u5230\u5df2\u5b89\u88c5\u3002 \u91cd\u65b0\u767b\u5f55\u9875\u9762\u53d1\u73b0\u6ca1\u95ee\u9898\u4e86\u3002<\/p>\n<p>PS\uff1a \u7f51\u4e0a\u6709\u8ddf\u591a\u7528 rake db:migrate \u521d\u59cb\u5316\u7684 \uff0c\u6211\u7684rake\u597d\u50cf\u6709\u95ee\u9898\uff0c\u4e00\u76f4\u6ca1\u521d\u59cb\u5316\uff0c\u4f46\u662f\u901a\u8fc7\u9875\u9762\u8bbf\u95ee\u53ef\u4ee5\u76f4\u63a5\u521d\u59cb\u5316\uff0c\u5f88\u667a\u80fd\u3002<\/p>\n<p>\u611f\u609f\uff1a<\/p>\n<p>1\uff1a\u4e00\u5b9a\u8981\u770b\u73af\u5883\uff0c\u5982\u679c\u7a0b\u5e8f\u8fd8\u662f\u63d0\u793a\u540c\u6837\u7684\u9519\u8bef\uff0c\u53ef\u80fd\u4f60\u7684\u73af\u5883\u4e0d\u5bf9\u3002<\/p>\n<p>2\uff1a\u8981\u591a\u770b\u5b98\u7f51\u6587\u6863\uff0c\u7f51\u4e0a\u7684\u6587\u6863\u53ef\u80fd\u6709\u65f6\u4f1a\u6bd4\u8f83\u8001\uff0c\u4ece\u800c\u8bef\u5bfc\u4f60\u3002<\/p>\n<p>PS \u5207\u6362ruby<\/p>\n<pre>scl enable ruby193 bash<\/pre>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[32,108,37],"class_list":["post-3328","post","type-post","status-publish","format-standard","hentry","category-5","tag-foreman-installer","tag-foremannamehostname","tag-foreman","category-5-id","post-seq-1","post-parity-odd","meta-position-corners","fix"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=\/wp\/v2\/posts\/3328","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3328"}],"version-history":[{"count":9,"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=\/wp\/v2\/posts\/3328\/revisions"}],"predecessor-version":[{"id":4378,"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=\/wp\/v2\/posts\/3328\/revisions\/4378"}],"wp:attachment":[{"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3328"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3328"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hmouse.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3328"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}