# # AUTHOR , YEAR. # msgid "" msgstr "" "Project-Id-Version: 0\n" "POT-Creation-Date: 2018-05-14 18:03-0500\n" "PO-Revision-Date: 2018-05-14 18:03-0500\n" "Last-Translator: Automatically generated\n" "Language-Team: None\n" "MIME-Version: 1.0\n" "Content-Type: application/x-publican; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #. Tag: title #, no-c-format msgid "Guest Node Quick Example" msgstr "" #. Tag: para #, no-c-format msgid "If you already know how to use Pacemaker, you’ll likely be able to grasp this new concept of guest nodes by reading through this quick example without having to sort through all the detailed walk-through steps. Here are the key configuration ingredients that make this possible using libvirt and KVM virtual guests. These steps strip everything down to the very basics. guest node nodeguest node guest node " msgstr "" #. Tag: title #, no-c-format msgid "Mile-High View of Configuration Steps" msgstr "" #. Tag: para #, no-c-format msgid "Give each virtual machine that will be used as a guest node a static network address and unique hostname." msgstr "" #. Tag: para #, no-c-format msgid "Put the same authentication key with the path /etc/pacemaker/authkey on every cluster node and virtual machine. This secures remote communication." msgstr "" #. Tag: para #, no-c-format msgid "Run this command if you want to make a somewhat random key:" msgstr "" #. Tag: screen #, no-c-format msgid "dd if=/dev/urandom of=/etc/pacemaker/authkey bs=4096 count=1" msgstr "" #. Tag: para #, no-c-format msgid "Install pacemaker_remote on every virtual machine, enabling it to start at boot, and if a local firewall is used, allow the node to accept connections on TCP port 3121." msgstr "" #. Tag: screen #, no-c-format msgid "yum install pacemaker-remote resource-agents\n" "systemctl enable pacemaker_remote\n" "firewall-cmd --add-port 3121/tcp --permanent" msgstr "" #. Tag: para #, no-c-format msgid "If you just want to see this work, you may want to simply disable the local firewall and put SELinux in permissive mode while testing. This creates security risks and should not be done on a production machine exposed to the Internet, but can be appropriate for a protected test machine." msgstr "" #. Tag: para #, no-c-format msgid "Create a Pacemaker resource to launch each virtual machine, using the remote-node meta-attribute to let Pacemaker know this will be a guest node capable of running resources." msgstr "" #. Tag: screen #, no-c-format msgid "# pcs resource create vm-guest1 VirtualDomain hypervisor=\"qemu:///system\" config=\"vm-guest1.xml\" meta remote-node=\"guest1\"" msgstr "" #. Tag: para #, no-c-format msgid "The above command will create CIB XML similar to the following:" msgstr "" #. Tag: programlisting #, no-c-format msgid " <primitive class=\"ocf\" id=\"vm-guest1\" provider=\"heartbeat\" type=\"VirtualDomain\">\n" " <instance_attributes id=\"vm-guest-instance_attributes\">\n" " <nvpair id=\"vm-guest1-instance_attributes-hypervisor\" name=\"hypervisor\" value=\"qemu:///system\"/>\n" " <nvpair id=\"vm-guest1-instance_attributes-config\" name=\"config\" value=\"guest1.xml\"/>\n" " </instance_attributes>\n" " <operations>\n" " <op id=\"vm-guest1-interval-30s\" interval=\"30s\" name=\"monitor\"/>\n" " </operations>\n" " <meta_attributes id=\"vm-guest1-meta_attributes\">\n" " <nvpair id=\"vm-guest1-meta_attributes-remote-node\" name=\"remote-node\" value=\"guest1\"/>\n" " </meta_attributes>\n" " </primitive>" msgstr "" #. Tag: para #, no-c-format msgid "In the example above, the meta-attribute remote-node=\"guest1\" tells Pacemaker that this resource is a guest node with the hostname guest1. The cluster will attempt to contact the virtual machine’s pacemaker_remote service at the hostname guest1 after it launches." msgstr "" #. Tag: para #, no-c-format msgid "The ID of the resource creating the virtual machine (vm-guest1 in the above example) must be different from the virtual machine’s uname (guest1 in the above example). Pacemaker will create an implicit internal resource for the pacemaker_remote connection to the guest, named with the value of remote-node, so that value cannot be used as the name of any other resource." msgstr "" #. Tag: title #, no-c-format msgid "Using a Guest Node" msgstr "" #. Tag: para #, no-c-format msgid "Guest nodes will show up in crm_mon output as normal:" msgstr "" #. Tag: title #, no-c-format msgid "Example crm_mon output after guest1 is integrated into cluster" msgstr "" #. Tag: screen #, no-c-format msgid "Stack: corosync\n" "Current DC: node1 (version 1.1.16-12.el7_4.5-94ff4df) - partition with quorum\n" "Last updated: Fri Jan 12 13:52:39 2018\n" "Last change: Fri Jan 12 13:25:17 2018 via pacemaker-controld on node1\n" "\n" "2 nodes configured\n" "2 resources configured\n" "\n" "Online: [ node1 guest1]\n" "\n" "vm-guest1 (ocf::heartbeat:VirtualDomain): Started node1" msgstr "" #. Tag: para #, no-c-format msgid "Now, you could place a resource, such as a webserver, on guest1:" msgstr "" #. Tag: screen #, no-c-format msgid "# pcs resource create webserver apache params configfile=/etc/httpd/conf/httpd.conf op monitor interval=30s\n" "# pcs constraint location webserver prefers guest1" msgstr "" #. Tag: para #, no-c-format msgid "Now, the crm_mon output would show:" msgstr "" #. Tag: screen #, no-c-format msgid "Stack: corosync\n" "Current DC: node1 (version 1.1.16-12.el7_4.5-94ff4df) - partition with quorum\n" "Last updated: Fri Jan 12 13:52:39 2018\n" "Last change: Fri Jan 12 13:25:17 2018 via pacemaker-controld on node1\n" "\n" "2 nodes configured\n" "2 resources configured\n" "\n" "Online: [ node1 guest1]\n" "\n" "vm-guest1 (ocf::heartbeat:VirtualDomain): Started node1\n" "webserver (ocf::heartbeat::apache): Started guest1" msgstr "" #. Tag: para #, no-c-format msgid "It is worth noting that after guest1 is integrated into the cluster, nearly all the Pacemaker command-line tools immediately become available to the guest node. This means things like crm_mon, crm_resource, and crm_attribute will work natively on the guest node, as long as the connection between the guest node and a cluster node exists. This is particularly important for any promotable clone resources executing on the guest node that need access to crm_master to set transient attributes." msgstr ""