<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Openstack on sysarcher/@ich_code</title><link>https://sysarcher.github.io/categories/openstack/</link><description>Recent content in Openstack on sysarcher/@ich_code</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Tue, 10 Nov 2020 21:22:37 +0200</lastBuildDate><atom:link href="https://sysarcher.github.io/categories/openstack/index.xml" rel="self" type="application/rss+xml"/><item><title>VM Optimizations for RT</title><link>https://sysarcher.github.io/posts/realtime-linux-vms/</link><pubDate>Tue, 10 Nov 2020 21:22:37 +0200</pubDate><guid>https://sysarcher.github.io/posts/realtime-linux-vms/</guid><description>&lt;p&gt;QEMU/KVM are a popular backend for OpenStack. In StarlingX Openstack (&lt;code&gt;stx-openstack&lt;/code&gt;) this is also the case. I&amp;rsquo;ll try to describe various techniques that I used to optimize RT behavior on an STX 4.0.1 cluster with worker nodes.&lt;/p&gt;
&lt;h4 id="terminology"&gt;Terminology&lt;/h4&gt;
&lt;p&gt;&lt;strong&gt;Bare-Metal&lt;/strong&gt; is a a physical computer and it&amp;rsquo;s base OS&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Host&lt;/strong&gt; is a bare-metal machine that runs VMs&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Thread&lt;/strong&gt; is a core of a CPU&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;CPU thread&lt;/strong&gt; refers to the thread on the host system CPU&lt;/p&gt;</description><content:encoded><![CDATA[<p>QEMU/KVM are a popular backend for OpenStack. In StarlingX Openstack (<code>stx-openstack</code>) this is also the case. I&rsquo;ll try to describe various techniques that I used to optimize RT behavior on an STX 4.0.1 cluster with worker nodes.</p>
<h4 id="terminology">Terminology</h4>
<p><strong>Bare-Metal</strong> is a a physical computer and it&rsquo;s base OS</p>
<p><strong>Host</strong> is a bare-metal machine that runs VMs</p>
<p><strong>Thread</strong> is a core of a CPU</p>
<p><strong>CPU thread</strong> refers to the thread on the host system CPU</p>
<p><strong>vCPU thread</strong> is a thread on a VM&rsquo;s virtualized CPU</p>
<p><em>Note: I borrowed terminology heavily from <a href="https://null-src.com/posts/qemu-optimization/post.php">this article on <code>null-src</code></a></em></p>
<h3 id="isolating-cpus">Isolating CPUs</h3>
<p><a href="https://shrmrf.github.io/rants/stx/2020/11/09/STX-for-RT.html">My last article covers this topic</a>. Isolating a VM&rsquo;s vCPU threads from the host system ensures that host&rsquo;s processes don&rsquo;t interfere with the VM.</p>
<h3 id="scheduling-openstack-vms-on-isolated-cores">Scheduling Openstack VMs on isolated cores</h3>
<h3 id="cpu-affinity">CPU Affinity</h3>
<h4 id="using-taskset">using <code>taskset</code></h4>
<h3 id="linux-process-scheduler-tuning">Linux Process Scheduler Tuning</h3>
<h3 id="grub-cmdline">GRUB cmdline</h3>
<p>Okay&hellip; don&rsquo;t delete the <code>console</code> entries in your command line&hellip; the entries below are for isolated cpu 1. This is not a comprehensive list&hellip; Just append whatever makes sense to you.</p>
<pre tabindex="0"><code>GRUB_CMDLINE_LINUX_DEFAULT=&#34;threadirqs rcu_nocbs=1 rcu_nocb_poll isolcpus=1 nohz_full=1 nohz=off intel_pstate=disable nosoftlockup nohalt&#34;
</code></pre>]]></content:encoded></item><item><title>First Steps With OpenStack</title><link>https://sysarcher.github.io/posts/openstack-deployment/</link><pubDate>Fri, 26 Apr 2019 21:22:37 +0200</pubDate><guid>https://sysarcher.github.io/posts/openstack-deployment/</guid><description>&lt;p&gt;I recently tried to set up OpenStack on a single-node development environment using devstack. This blog is &lt;em&gt;not&lt;/em&gt; meant as a tutorial or getting started guide. However, I hope that Google will send someone crying tears of sorrow this way so he can benefit from my experience.&lt;/p&gt;
&lt;h3 id="conclusion"&gt;Conclusion&lt;/h3&gt;
&lt;p&gt;What I concluded from the documentations is that we don&amp;rsquo;t get something ready-to-go from the official docs. And you should consider yourself lucky if everything worked for you out-of-the-box.&lt;/p&gt;</description><content:encoded><![CDATA[<p>I recently tried to set up OpenStack on a single-node development environment using devstack. This blog is <em>not</em> meant as a tutorial or getting started guide. However, I hope that Google will send someone crying tears of sorrow this way so he can benefit from my experience.</p>
<h3 id="conclusion">Conclusion</h3>
<p>What I concluded from the documentations is that we don&rsquo;t get something ready-to-go from the official docs. And you should consider yourself lucky if everything worked for you out-of-the-box.</p>
<h2 id="setup-ideas">Setup Ideas</h2>
<ul>
<li>Start from a clean installation of Ubuntu 18.04.</li>
<li>The <code>local.conf</code> goes into the top-level directory of the <code>devstack</code> checkout.</li>
</ul>
<h3 id="setup">Setup</h3>
<p>My setup already provided the DNS and DHCP servers as illustrated below.</p>
<pre tabindex="0"><code>        (DNS Server)              (DHCP Server)
             |                          |
             |                          |
             +------------+-------------+
                          |
                          |
                        (OpenStack)
</code></pre><p>So, my <code>local.conf</code> looks like the following:</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-ini" data-lang="ini"><span style="display:flex;"><span><span style="color:#66d9ef">[[local|localrc]]</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">ADMIN_PASSWORD</span><span style="color:#f92672">=</span><span style="color:#e6db74">safeandsecure</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">DATABASE_PASSWORD</span><span style="color:#f92672">=</span><span style="color:#e6db74">$ADMIN_PASSWORD</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">RABBIT_PASSWORD</span><span style="color:#f92672">=</span><span style="color:#e6db74">$ADMIN_PASSWORD</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">SERVICE_PASSWORD</span><span style="color:#f92672">=</span><span style="color:#e6db74">$ADMIN_PASSWORD</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">HOST_IP</span><span style="color:#f92672">=</span><span style="color:#e6db74">&lt;HOST_IP&gt;</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">FLOATING_RANGE</span><span style="color:#f92672">=</span><span style="color:#e6db74">&lt;HOST_IP&gt;/24</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">Q_FLOATING_ALLOCATION_POOL</span><span style="color:#f92672">=</span><span style="color:#e6db74">start=&lt;HOST_IP&gt;.150,end=&lt;HOST_IP&gt;.200</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">FIXED_RANGE</span><span style="color:#f92672">=</span><span style="color:#e6db74">10.11.12.0/24</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">FIXED_NETWORK_SIZE</span><span style="color:#f92672">=</span><span style="color:#e6db74">256</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">PUBLIC_INTERFACE</span><span style="color:#f92672">=</span><span style="color:#e6db74">eno1</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">PUBLIC_NETWORK_GATEWAY</span><span style="color:#f92672">=</span><span style="color:#e6db74">&lt;HOST_IP&gt;.1</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">LOGFILE</span><span style="color:#f92672">=</span><span style="color:#e6db74">$DEST/logs/stack.sh.log</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">LOGDAYS</span><span style="color:#f92672">=</span><span style="color:#e6db74">2</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">SWIFT_HASH</span><span style="color:#f92672">=</span><span style="color:#e6db74">66a3d6b56c1f479c8b4e70ab5c2000f5</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">SWIFT_REPLICAS</span><span style="color:#f92672">=</span><span style="color:#e6db74">1</span>
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">SWIFT_DATA_DIR</span><span style="color:#f92672">=</span><span style="color:#e6db74">$DEST/data</span>
</span></span></code></pre></div><p>(The <code>&lt;HOST_IP&gt;.XXX</code> numbers are obviously replacing the last part of the IP address.)</p>
<p>What I&rsquo;m telling OpenStack is that I &hellip;</p>
<ul>
<li>already have a Gateway in the network, use it!</li>
<li>Already know what the IP allocation pool looks like</li>
</ul>
<h3 id="next">Next</h3>
<p>With that, hopefully you can go do OpenStack stuff and not have to worry about networking being the biggest issue in your life. Good luck!!!</p>
]]></content:encoded></item></channel></rss>