{"id":688,"date":"2014-10-30T12:18:19","date_gmt":"2014-10-30T16:18:19","guid":{"rendered":"http:\/\/blog.domb.net\/?p=688"},"modified":"2014-12-01T21:14:02","modified_gmt":"2014-12-02T02:14:02","slug":"install-openshift-enterpirse-2-2-non-ha","status":"publish","type":"post","link":"https:\/\/blog.domb.net\/?p=688","title":{"rendered":"Install OpenShift Enterpirse 2.2 Non HA"},"content":{"rendered":"<p>This guide will help you to setup an OpenShift non HA environment within less than an hour. We are installing 1 Broker and 2 nodes. <\/p>\n<p>If you do not have a satellite server and need local repos, these are the channels you need to clone are have available: <\/p>\n<p>jbappplatform-6-x86_64-server-6-rpm<br \/>\njb-ews-2-x86_64-server-6-rpm<br \/>\nrhel-x86_64-server-6-ose-2.2-infrastructure<br \/>\nrhel-x86_64-server-6-ose-2.2-jbosseap<br \/>\nrhel-x86_64-server-6-ose-2.2-node<br \/>\nrhel-x86_64-server-6-ose-2.2-rhc<br \/>\nrhel-x86_64-server-6-rhscl-1<br \/>\nrhel-x86_64-server-6 (optional)<\/p>\n<p>Here are the repos based on role: <\/p>\n<p>Broker:<br \/>\n<code><br \/>\n# 1 RHEL 6 - On Everywhere<br \/>\n[rhel-x86_64-server-6]<br \/>\nname=rhel-x86_64-server-6<br \/>\n[rhel-x86_64-server-6-updates]<\/p>\n<p># 2 SCL 1.1 - On Everywhere<br \/>\n[rhel-x86_64-server-6-rhscl-1]<br \/>\nname=rhel-x86_64-server-6-rhscl-1<\/p>\n<p># 3 OSE2 Client Tools - On Everywhere<br \/>\n[rhel-x86_64-server-6-ose-2.1-rhc]<br \/>\nname=rhel-x86_64-server-6-ose-2.1-rhc<\/p>\n<p># 4 OSE2 Broker Repo - Broker-only<br \/>\n[rhel-x86_64-server-6-ose-2.1-infrastructure]<br \/>\nname=rhel-x86_64-server-6-ose-2.1-infrastructure<br \/>\n<\/code><\/p>\n<p>Node:<br \/>\n<code><br \/>\n # 1 RHEL 6 - On Everywhere<br \/>\n[rhel-x86_64-server-6]<br \/>\nname=rhel-x86_64-server-6<\/p>\n<p>[rhel-x86_64-server-6-updates]<br \/>\nname=rhel-x86_64-server-6-updates<\/p>\n<p># 2 SCL 2.0 - On Everywhere<br \/>\n[rhel-x86_64-server-6-rhscl-1]<br \/>\nname=rhel-x86_64-server-6-rhscl-1<\/p>\n<p># 3 OSE2 Client Tools - On Everywhere<br \/>\n[rhel-x86_64-server-6-ose-2.1-rhc]<br \/>\nname=rhel-x86_64-server-6-ose-2.1-rhc<\/p>\n<p># 5 OSE2 Node Repo - Node-only<br \/>\n[rhel-x86_64-server-6-ose-2.1-node]<br \/>\nname=rhel-x86_64-server-6-ose-2.1-node<\/p>\n<p># 6 OSE2 JBoss EAP Addon - Node-only<br \/>\n[rhel-x86_64-server-6-ose-2.1-jbosseap]<br \/>\nname=rhel-x86_64-server-6-ose-2.1-jbosseap<\/p>\n<p># 7 OSE2 EAP - Node-only<br \/>\n[jbappplatform-6-x86_64-server-6-rpm]<br \/>\nname=jbappplatform-6-x86_64-server-6-rpm<\/p>\n<p># 8 OSE2 EWS - Node-only<br \/>\n[jb-ews-2-x86_64-server-6-rpm]<br \/>\nname=jb-ews-2-x86_64-server-6-rpm<br \/>\n<\/code><\/p>\n<p>Workstation:<br \/>\n<code><br \/>\n# 1 RHEL 6 - On Everywhere<br \/>\n[rhel-x86_64-server-6]<br \/>\nname=rhel-x86_64-server-6<\/p>\n<p>[rhel-x86_64-server-6-updates]<br \/>\nname=rhel-x86_64-server-6-updates<\/p>\n<p># 2 SCL 1.1 - On Everywhere<br \/>\n[rhel-x86_64-server-6-rhscl-1]<br \/>\nname=rhel-x86_64-server-6-rhscl-1<\/p>\n<p># 3 OSE2 Client Tools - On Everywhere<br \/>\n[rhel-x86_64-server-6-ose-2.1-rhc]<br \/>\nname=rhel-x86_64-server-6-ose-2.1-rhc<br \/>\n<\/code><\/p>\n<p>Once you have all the repos available you can start installing: <\/p>\n<p>1. Install Rhel 6.6 on 3 VM&#8217;s<br \/>\n2. Choose which one should be the broker and which ones should be nodes<br \/>\n3. Login to the broker<br \/>\n4. Get the openshift installer<br \/>\n<code><br \/>\nwget https:\/\/raw.githubusercontent.com\/openshift\/openshift-extras\/enterprise-2.2\/enterprise\/install-scripts\/generic\/openshift.sh<br \/>\n<\/code><br \/>\n5. Set execute permissions<br \/>\n<code><br \/>\nchmod +x openshift.sh<br \/>\n<\/code><\/p>\n<p>Also make sure you add the broker to \/etc\/hosts<br \/>\n<code><br \/>\n192.168.1.45  broker.local.domb.com broker<br \/>\n<\/code><\/p>\n<p>Now we will run the openshift.sh command to setup the broker<\/p>\n<p>If you are installing this on OpenStack make sure you use the Public IP and not the private IP&#8217;s. This is important as these values get added to the bind dns config. Your hosts wont resolv from outside the instances if you use private ips. <\/p>\n<p>6. Launch the installer<br \/>\n<code>.\/openshift.sh install_method=rhsm \\<br \/>\nrhn_user=YourRhnUser \\<br \/>\nrhn_pass=YourRHnPassword \\<br \/>\nsm_reg_pool=YourRegPool\u00a0\\<br \/>\ninstall_components=broker,named,activemq,datastore \\<br \/>\nmcollective_password=redhat \\<br \/>\nmongodb_broker_password=redhat \\<br \/>\nopenshift_password1=redhat \\<br \/>\ndomain=apps.local.domb.com \\<br \/>\nhosts_domain=hosts.local.domb.com \\<br \/>\nbroker_hostname=broker.hosts.local.domb.com \\<br \/>\nnamed_entries=broker:192.168.1.45,activemq:192.168.1.45,node1:192.168.1.46,node2:192.168.1.47 \\<br \/>\nvalid_gear_sizes=medium \\<br \/>\ndefault_gear_size=medium \\<br \/>\ndefault_gear_capabilities=medium 2&gt;&amp;1 | tee -a openshift.sh.log<br \/>\n<\/code><\/p>\n<p>7. Make sure you have a forwarder which points to your company dns in \/etc\/named.conf and restart DNS.<\/p>\n<p>8. After the install is completed on the broker login to the nodes and make sure that the DNS in \/etc\/resolv.conf points to the broker. <\/p>\n<p>Repeat this step for both nodes<\/p>\n<p>9. Get the openshift installer<br \/>\n<code><br \/>\nwget https:\/\/raw.githubusercontent.com\/openshift\/openshift-extras\/enterprise-2.2\/enterprise\/install-scripts\/generic\/openshift.sh<br \/>\n<\/code><br \/>\n10. Set execute permissions<br \/>\n<code><br \/>\nchmod +x openshift.sh<br \/>\n<\/code><\/p>\n<p>11. Add the broker to \/etc\/hosts<br \/>\n<code><br \/>\n192.168.1.45  broker.local.domb.com broker<br \/>\n<\/code><\/p>\n<p>12. Launch the installer:<br \/>\n<code><br \/>\n.\/openshift.sh install_method=rhsm \\<br \/>\nrhn_user=YourRhnUser \\<br \/>\nrhn_pass=YourRHnPassword \\<br \/>\nsm_reg_pool=YourRegPool \\<br \/>\ninstall_components=node \\<br \/>\nmcollective_password=redhat \\<br \/>\ndomain=apps.local.domb.com \\<br \/>\nhosts_domain=hosts.local.domb.com \\<br \/>\nnode_hostname=node1.hosts.local.domb.com \\<br \/>\nbroker_ip_addr=192.168.1.45 \\<br \/>\nbroker_hostname=broker.hosts.local.domb.com \\<br \/>\nnode_profile=medium \\<br \/>\ncartridges=all 2&gt;&amp;1 | tee -a openshift.sh.log<br \/>\n<\/code><\/p>\n<p>13. After both Nodes are back up, login into the nodes to make sure that the labels for authorized keys are correct<br \/>\n<code><br \/>\ncd \/root\/.ssh<br \/>\nrestorcon -Rv authorized_keys<br \/>\n<\/code><\/p>\n<p>14. Login to the broker and run the following command to activate the cardtriges<br \/>\n<code><br \/>\noo-admin-ctl-cartridge -c import-node --activate --obsolete<br \/>\nsh openshift.sh actions=post_deploy install_components=broker valid_gear_sizes=medium default_gear_size=medium default_gear_capabilities=medium 2&gt;&amp;1 | tee -a openshift.sh.log<br \/>\n<\/code><\/p>\n<p>15. If this is sucessful run oo-diagnostics on the broker and nodes to see if there are no error messages<br \/>\n<code><br \/>\noo-diagnostics<br \/>\noo-mco ping<br \/>\n<\/code><\/p>\n<p>16. Enable Admin console<br \/>\nOn each broker host, edit the \/etc\/httpd\/conf.d\/000002_openshift_origin_broker_proxy.conf configuration file. Inside the <VirtualHost *:443> section, add additional ProxyPass entries for the Administration Console and its static assets after the existing ProxyPass entry for the broker. The completed <VirtualHost *:443> section looks similar to the following:<br \/>\n\u2060<br \/>\nYou can add this in the 443 section<br \/>\n<code><br \/>\nProxyPass \/broker http:\/\/127.0.0.1:8080\/broker<br \/>\nProxyPass \/admin-console http:\/\/127.0.0.1:8080\/admin-console<br \/>\nProxyPass \/assets http:\/\/127.0.0.1:8080\/assets<br \/>\nProxyPassReverse \/ http:\/\/127.0.0.1:8080\/<br \/>\n<\/code><\/p>\n<p>Restart httpd<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This guide will help you to setup an OpenShift non HA environment within less than an hour. We are installing 1 Broker and 2 nodes. If you do not have a satellite server and need local repos, these are the channels you need to clone are have available: jbappplatform-6-x86_64-server-6-rpm jb-ews-2-x86_64-server-6-rpm rhel-x86_64-server-6-ose-2.2-infrastructure rhel-x86_64-server-6-ose-2.2-jbosseap rhel-x86_64-server-6-ose-2.2-node rhel-x86_64-server-6-ose-2.2-rhc rhel-x86_64-server-6-rhscl-1&#8230;<\/p>\n","protected":false},"author":2,"featured_media":694,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_themeisle_gutenberg_block_has_review":false,"footnotes":""},"categories":[3],"tags":[21],"class_list":["post-688","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","tag-openshift-cloud"],"_links":{"self":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts\/688","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=688"}],"version-history":[{"count":11,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts\/688\/revisions"}],"predecessor-version":[{"id":710,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts\/688\/revisions\/710"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/media\/694"}],"wp:attachment":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=688"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=688"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=688"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}