Author: iwilltry42 <iwilltry42@gmail.com>
Date:   Wed Jul 15 08:21:47 2020 +0200

    fix doc multiserver filename
pull/308/head
iwilltry42 4 years ago
parent dd842fcaaf
commit 2a787292a6
  1. 4
      404.html
  2. 20
      faq/faq/index.html
  3. 4
      faq/v1vsv3-comparison/index.html
  4. 18
      index.html
  5. 14
      internals/defaults/index.html
  6. 8
      internals/networking/index.html
  7. 2
      search/search_index.json
  8. 22
      sitemap.xml
  9. BIN
      sitemap.xml.gz
  10. 215
      static/asciicast/20200715_k3d.01.cast
  11. 12
      usage/commands/index.html
  12. 18
      usage/guides/exposing_services/index.html
  13. 4
      usage/guides/registries/index.html
  14. 8
      usage/kubeconfig/index.html
  15. 44
      usage/multiserver/index.html

@ -305,8 +305,8 @@
<li class="md-nav__item">
<a href="/usage/multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="/usage/multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>

@ -314,8 +314,8 @@
<li class="md-nav__item">
<a href="../../usage/multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../../usage/multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -522,8 +522,8 @@
</li>
<li class="md-nav__item">
<a href="#restarting-a-multi-master-cluster-or-the-initializing-master-node-fails" class="md-nav__link">
Restarting a multi-master cluster or the initializing master node fails
<a href="#restarting-a-multi-server-cluster-or-the-initializing-server-node-fails" class="md-nav__link">
Restarting a multi-server cluster or the initializing server node fails
</a>
</li>
@ -599,8 +599,8 @@
</li>
<li class="md-nav__item">
<a href="#restarting-a-multi-master-cluster-or-the-initializing-master-node-fails" class="md-nav__link">
Restarting a multi-master cluster or the initializing master node fails
<a href="#restarting-a-multi-server-cluster-or-the-initializing-server-node-fails" class="md-nav__link">
Restarting a multi-server cluster or the initializing server node fails
</a>
</li>
@ -634,7 +634,7 @@
<h2 id="issues-with-zfs">Issues with ZFS<a class="headerlink" href="#issues-with-zfs" title="Permanent link">&para;</a></h2>
<ul>
<li>
<p>k3s currently has <a href="ttps://github.com/rancher/k3s/issues/66">no support for ZFS</a> and thus, creating multi-master setups (e.g. <code>k3d cluster create multimaster --masters 3</code>) fails, because the initializing master node (server flag <code>--cluster-init</code>) errors out with the following log:
<p>k3s currently has <a href="ttps://github.com/rancher/k3s/issues/66">no support for ZFS</a> and thus, creating multi-server setups (e.g. <code>k3d cluster create multiserver --servers 3</code>) fails, because the initializing server node (server flag <code>--cluster-init</code>) errors out with the following log:
<div class="highlight"><pre><span></span><code>starting kubernetes: preparing server: start cluster and https: raft_init<span class="o">()</span>: io: create I/O capabilities probe file: posix_allocate: operation not supported on socket
</code></pre></div></p>
</li>
@ -655,11 +655,11 @@
</ul>
</li>
</ul>
<h2 id="restarting-a-multi-master-cluster-or-the-initializing-master-node-fails">Restarting a multi-master cluster or the initializing master node fails<a class="headerlink" href="#restarting-a-multi-master-cluster-or-the-initializing-master-node-fails" title="Permanent link">&para;</a></h2>
<h2 id="restarting-a-multi-server-cluster-or-the-initializing-server-node-fails">Restarting a multi-server cluster or the initializing server node fails<a class="headerlink" href="#restarting-a-multi-server-cluster-or-the-initializing-server-node-fails" title="Permanent link">&para;</a></h2>
<ul>
<li>What you do: You create a cluster with more than one master node and later, you either stop <code>master-0</code> or stop/start the whole cluster</li>
<li>What you do: You create a cluster with more than one server node and later, you either stop <code>server-0</code> or stop/start the whole cluster</li>
<li>What fails: After the restart, you cannot connect to the cluster anymore and <code>kubectl</code> will give you a lot of errors</li>
<li>What causes this issue: it&rsquo;s a <a href="https://github.com/rancher/k3s/issues/1391">known issue with dqlite in <code>k3s</code></a> which doesn&rsquo;t allow the initializing master node to go down</li>
<li>What causes this issue: it&rsquo;s a <a href="https://github.com/rancher/k3s/issues/1391">known issue with dqlite in <code>k3s</code></a> which doesn&rsquo;t allow the initializing server node to go down</li>
<li>What&rsquo;s the solution: Hopefully, this will be solved by the planned <a href="https://github.com/rancher/k3s/pull/1770">replacement of dqlite with embedded etcd in k3s</a></li>
<li>Related issues: <a href="https://github.com/rancher/k3d/issues/262">#262</a></li>
</ul>

@ -314,8 +314,8 @@
<li class="md-nav__item">
<a href="../../usage/multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../../usage/multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>

@ -389,8 +389,8 @@
<li class="md-nav__item">
<a href="usage/multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="usage/multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -654,7 +654,7 @@
<p><strong>This page is targeting k3d v3.0.0 and newer!</strong></p>
<p>k3d is a lightweight wrapper to run <a href="https://github.com/rancher/k3s">k3s</a> (Rancher Lab&rsquo;s minimal Kubernetes distribution) in docker.</p>
<p>k3d makes it very easy to create single- and multi-node <a href="https://github.com/rancher/k3s">k3s</a> clusters in docker, e.g. for local development on Kubernetes.</p>
<details class="tip"><summary>View a quick demo</summary><p><asciinema-player src="/static/asciicast/20200515_k3d.01.cast" cols=200 rows=32></asciinema-player></p>
<details class="tip"><summary>View a quick demo</summary><p><asciinema-player src="/static/asciicast/20200715_k3d.01.cast" cols=200 rows=32></asciinema-player></p>
</details>
<h2 id="learning">Learning<a class="headerlink" href="#learning" title="Permanent link">&para;</a></h2>
<ul>
@ -704,15 +704,15 @@
<p>You have several options there:</p>
<ul>
<li>use the install script to grab the latest release:<ul>
<li>wget: <code class="highlight">wget -q -O - https://raw.githubusercontent.com/rancher/k3d/master/install.sh <span class="p">|</span> bash</code></li>
<li>curl: <code class="highlight">curl -s https://raw.githubusercontent.com/rancher/k3d/master/install.sh <span class="p">|</span> bash</code></li>
<li>wget: <code class="highlight">wget -q -O - https://raw.githubusercontent.com/rancher/k3d/main/install.sh <span class="p">|</span> bash</code></li>
<li>curl: <code class="highlight">curl -s https://raw.githubusercontent.com/rancher/k3d/main/install.sh <span class="p">|</span> bash</code></li>
</ul>
</li>
<li>
<p>use the install script to grab a specific release (via <code>TAG</code> environment variable):</p>
<ul>
<li>wget: <code class="highlight">wget -q -O - https://raw.githubusercontent.com/rancher/k3d/master/install.sh <span class="p">|</span> <span class="nv">TAG</span><span class="o">=</span>v3.0.0-beta.0 bash</code></li>
<li>curl: <code class="highlight">curl -s https://raw.githubusercontent.com/rancher/k3d/master/install.sh <span class="p">|</span> <span class="nv">TAG</span><span class="o">=</span>v3.0.0-beta.0 bash</code></li>
<li>wget: <code class="highlight">wget -q -O - https://raw.githubusercontent.com/rancher/k3d/main/install.sh <span class="p">|</span> <span class="nv">TAG</span><span class="o">=</span>v3.0.0-rc.7 bash</code></li>
<li>curl: <code class="highlight">curl -s https://raw.githubusercontent.com/rancher/k3d/main/install.sh <span class="p">|</span> <span class="nv">TAG</span><span class="o">=</span>v3.0.0-rc.7 bash</code></li>
</ul>
</li>
<li>
@ -726,7 +726,7 @@
<li>install via go: <code class="highlight">go install github.com/rancher/k3d</code> (<strong>Note</strong>: this will give you unreleased/bleeding-edge changes)</li>
</ul>
<h2 id="quick-start">Quick Start<a class="headerlink" href="#quick-start" title="Permanent link">&para;</a></h2>
<p>Create a cluster named <code>mycluster</code> with just a single master node:</p>
<p>Create a cluster named <code>mycluster</code> with just a single server node:</p>
<div class="highlight"><pre><span></span><code>k3d cluster create mycluster
</code></pre></div>
@ -750,7 +750,7 @@
<div class="md-source-date">
<small>
Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">July 14, 2020</span>
Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">July 15, 2020</span>
</small>
</div>

@ -314,8 +314,8 @@
<li class="md-nav__item">
<a href="../../usage/multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../../usage/multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -535,10 +535,10 @@
<h1 id="defaults">Defaults<a class="headerlink" href="#defaults" title="Permanent link">&para;</a></h1>
<ul>
<li>multiple master nodes<ul>
<li>by default, when <code>--master</code> &gt; 1 and no <code>--datastore-x</code> option is set, the first master node (master-0) will be the initializing master node<ul>
<li>the initializing master node will have the <code>--cluster-init</code> flag appended</li>
<li>all other master nodes will refer to the initializing master node via <code>--server https://&lt;init-node&gt;:6443</code></li>
<li>multiple server nodes<ul>
<li>by default, when <code>--server</code> &gt; 1 and no <code>--datastore-x</code> option is set, the first server node (server-0) will be the initializing server node<ul>
<li>the initializing server node will have the <code>--cluster-init</code> flag appended</li>
<li>all other server nodes will refer to the initializing server node via <code>--server https://&lt;init-node&gt;:6443</code></li>
</ul>
</li>
</ul>
@ -564,7 +564,7 @@
<div class="md-source-date">
<small>
Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">June 22, 2020</span>
Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">July 14, 2020</span>
</small>
</div>

@ -314,8 +314,8 @@
<li class="md-nav__item">
<a href="../../usage/multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../../usage/multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -665,8 +665,8 @@ Existing networks won&rsquo;t be managed by k3d together with the cluster lifecy
<h2 id="connecting-to-docker-internalpre-defined-networks">Connecting to docker &ldquo;internal&rdquo;/pre-defined networks<a class="headerlink" href="#connecting-to-docker-internalpre-defined-networks" title="Permanent link">&para;</a></h2>
<h3 id="host-network"><code>host</code> network<a class="headerlink" href="#host-network" title="Permanent link">&para;</a></h3>
<p>When using the <code>--network</code> flag to connect to the host network (i.e. <code>k3d cluster create --network host</code>),
you won&rsquo;t be able to create more than <strong>one master node</strong>.
An edge case would be one master node (with agent disabled) and one worker node.</p>
you won&rsquo;t be able to create more than <strong>one server node</strong>.
An edge case would be one server node (with agent disabled) and one agent node.</p>
<h3 id="bridge-network"><code>bridge</code> network<a class="headerlink" href="#bridge-network" title="Permanent link">&para;</a></h3>
<p>By default, every network that k3d creates is working in <code>bridge</code> mode.
But when you try to use <code>--network bridge</code> to connect to docker&rsquo;s internal <code>bridge</code> network, you may

File diff suppressed because one or more lines are too long

@ -1,43 +1,43 @@
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><url>
<loc>https://k3d.io/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/usage/commands/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/usage/kubeconfig/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/usage/multimaster/</loc>
<lastmod>2020-07-14</lastmod>
<loc>https://k3d.io/usage/multiserver/</loc>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/usage/guides/exposing_services/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/usage/guides/registries/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/internals/defaults/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/internals/networking/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/faq/faq/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url><url>
<loc>https://k3d.io/faq/v1vsv3-comparison/</loc>
<lastmod>2020-07-14</lastmod>
<lastmod>2020-07-15</lastmod>
<changefreq>daily</changefreq>
</url>
</urlset>

Binary file not shown.

@ -0,0 +1,215 @@
{"version":2,"width":213,"height":47,"timestamp":1594792376,"theme":{},"env":{"SHELL":"/bin/zsh","TERM":"xterm-256color"}}
[2.221,"o","\u001b[H\u001b[2J\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K"]
[2.881,"o","k"]
[3.002,"o","\u0008k3"]
[3.187,"o","d"]
[3.32,"o"," "]
[3.42,"o","v"]
[3.53,"o","e"]
[3.662,"o","r"]
[3.827,"o","s"]
[3.913,"o","i"]
[4.113,"o","o"]
[4.245,"o","n"]
[4.443,"o","\u001b[?2004l\r\r\n"]
[4.471,"o","k3d version v3.0.0-rc.7\r\nk3s version v1.18.4-k3s1 (default)\r\n"]
[4.473,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[5.719,"o","k"]
[5.829,"o","\u0008k3"]
[6.038,"o","d"]
[6.235,"o"," "]
[6.75,"o","c"]
[6.852,"o","l"]
[7.094,"o","u"]
[7.193,"o","s"]
[7.534,"o","t"]
[7.71,"o","e"]
[7.831,"o","r"]
[8.029,"o"," "]
[8.268,"o","l"]
[8.491,"o","i"]
[8.634,"o","s"]
[8.796,"o","t"]
[8.943,"o","\u001b[?2004l\r\r\n"]
[8.971,"o","NAME SERVERS AGENTS\r\n"]
[8.972,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[9.756,"o","k"]
[9.854,"o","\u0008k3"]
[10.05,"o","d"]
[10.448,"o"," "]
[10.811,"o","c"]
[10.91,"o","l"]
[11.119,"o","u"]
[11.174,"o","s"]
[11.284,"o","t"]
[11.416,"o","e"]
[11.515,"o","r"]
[11.648,"o"," "]
[11.746,"o","c"]
[11.988,"o","r"]
[12.054,"o","e"]
[12.087,"o","a"]
[12.208,"o","t"]
[12.285,"o","e"]
[13.055,"o"," "]
[13.77,"o","d"]
[13.858,"o","e"]
[13.99,"o","m"]
[14.133,"o","o"]
[14.321,"o"," "]
[14.629,"o","-"]
[14.801,"o","-"]
[14.867,"o","s"]
[15.065,"o","e"]
[15.111,"o","r"]
[15.343,"o","v"]
[15.409,"o","e"]
[15.519,"o","r"]
[15.706,"o","s"]
[15.905,"o"," "]
[16.74,"o","3"]
[16.914,"o"," "]
[17.137,"o","-"]
[17.291,"o","-"]
[17.44,"o","a"]
[17.586,"o","g"]
[17.687,"o","e"]
[17.763,"o","n"]
[17.84,"o","t"]
[18.017,"o","s"]
[18.259,"o"," "]
[18.379,"o","3"]
[19.137,"o","\u001b[?2004l\r\r\n"]
[19.222,"o","\u001b[36mINFO\u001b[0m[0000] Created network 'k3d-demo' \r\n"]
[19.225,"o","\u001b[36mINFO\u001b[0m[0000] Created volume 'k3d-demo-images' \r\n"]
[19.225,"o","\u001b[36mINFO\u001b[0m[0000] Creating initializing server node \r\n\u001b[36mINFO\u001b[0m[0000] Creating node 'k3d-demo-server-0' \r\n"]
[30.266,"o","\u001b[36mINFO\u001b[0m[0011] Creating node 'k3d-demo-server-1' \r\n"]
[31.634,"o","\u001b[36mINFO\u001b[0m[0012] Creating node 'k3d-demo-server-2' \r\n"]
[32.125,"o","\u001b[36mINFO\u001b[0m[0012] Creating node 'k3d-demo-agent-0' \r\n"]
[32.519,"o","\u001b[36mINFO\u001b[0m[0013] Creating node 'k3d-demo-agent-1' \r\n"]
[33.096,"o","\u001b[36mINFO\u001b[0m[0013] Creating node 'k3d-demo-agent-2' \r\n"]
[33.577,"o","\u001b[36mINFO\u001b[0m[0014] Creating LoadBalancer 'k3d-demo-serverlb' \r\n"]
[38.248,"o","\u001b[36mINFO\u001b[0m[0019] Cluster 'demo' created successfully! \r\n"]
[38.33,"o","\u001b[36mINFO\u001b[0m[0019] You can now use it like this: \r\nkubectl cluster-info\r\n"]
[38.335,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r"]
[38.336,"o","\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[40.212,"o","k"]
[40.465,"o","\u0008ku"]
[40.63,"o","b"]
[40.773,"o","e"]
[40.916,"o","c"]
[41.169,"o","t"]
[41.302,"o","l"]
[41.53,"o"," "]
[41.686,"o","c"]
[41.774,"o","o"]
[41.928,"o","n"]
[42.093,"o","f"]
[42.213,"o","i"]
[42.401,"o","g"]
[42.565,"o"," "]
[42.686,"o","v"]
[42.807,"o","i"]
[42.895,"o","e"]
[43.082,"o","w"]
[43.27,"o","\u001b[?2004l\r\r\n"]
[43.304,"o","apiVersion: v1\r\nclusters:\r\n- cluster:\r\n certificate-authority-data: DATA+OMITTED\r\n server: https://0.0.0.0:38365\r\n name: k3d-demo\r\ncontexts:\r\n- context:\r\n cluster: k3d-demo\r\n user: admin@k3d-demo\r\n name: k3d-demo\r\ncurrent-context: k3d-demo\r\nkind: Config\r\npreferences: {}\r\nusers:\r\n- name: admin@k3d-demo\r\n user:\r\n password: 1c22f8175521452403719784fa0b124f\r\n username: admin\r\n"]
[43.305,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r"]
[43.305,"o","\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[45.754,"o","k"]
[45.843,"o","\u0008k3"]
[45.987,"o","d"]
[46.075,"o"," "]
[46.24,"o","c"]
[46.36,"o","l"]
[46.569,"o","u"]
[46.658,"o","s"]
[46.768,"o","t"]
[46.91,"o","e"]
[46.977,"o","r"]
[47.042,"o"," "]
[47.252,"o","l"]
[47.472,"o","i"]
[47.56,"o","s"]
[47.681,"o","t"]
[47.846,"o","\u001b[?2004l\r\r\n"]
[47.88,"o","NAME SERVERS AGENTS\r\ndemo 3 3\r\n"]
[47.881,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r"]
[47.882,"o","\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[48.517,"o","k"]
[48.616,"o","\u0008k3"]
[48.77,"o","d"]
[48.968,"o"," "]
[50.133,"o","n"]
[50.276,"o","o"]
[50.33,"o","d"]
[50.386,"o","e"]
[50.462,"o"," "]
[50.605,"o","l"]
[50.792,"o","i"]
[50.881,"o","s"]
[51.046,"o","t"]
[51.255,"o","\u001b[?2004l\r\r\n"]
[51.266,"o","NAME ROLE CLUSTER\r\nk3d-demo-agent-0 agent "]
[51.266,"o","demo\r\nk3d-demo-agent-1 agent demo\r\nk3d-demo-agent-2 agent demo\r\nk3d-demo-server-0 server demo\r\nk3d-demo-server-1 server demo\r\nk3d-demo-server-2 server demo\r\nk3d-demo-serverlb loadbalancer demo\r\n"]
[51.267,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r"]
[51.267,"o","\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[58.525,"o","k"]
[58.822,"o","\u0008ku"]
[58.999,"o","b"]
[59.109,"o","e"]
[59.217,"o","c"]
[59.48,"o","t"]
[59.582,"o","l"]
[59.791,"o"," "]
[59.876,"o","g"]
[59.978,"o","e"]
[60.109,"o","t"]
[60.285,"o"," "]
[60.495,"o","n"]
[60.626,"o","o"]
[60.725,"o","d"]
[60.791,"o","e"]
[61,"o","s"]
[61.176,"o","\u001b[?2004l\r\r\n"]
[61.334,"o","NAME STATUS ROLES AGE VERSION\r\nk3d-demo-server-2 Ready master 22s v1.18.4+k3s1\r\nk3d-demo-agent-2 Ready \u003cnone\u003e 26s v1.18.4+k3s1\r\nk3d-demo-agent-0 Ready \u003cnone\u003e "]
[61.334,"o","27s v1.18.4+k3s1\r\nk3d-demo-agent-1 Ready \u003cnone\u003e 27s v1.18.4+k3s1\r\nk3d-demo-server-1 Ready master 19s v1.18.4+k3s1\r\nk3d-demo-server-0 Ready master 32s v1.18.4+k3s1\r\n"]
[61.336,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[63.901,"o","k"]
[64.08,"o","\u0008k3"]
[64.297,"o","d"]
[64.464,"o"," "]
[64.674,"o","c"]
[64.84,"o","l"]
[65.126,"o","u"]
[65.245,"o","s"]
[65.411,"o","t"]
[65.553,"o","e"]
[65.675,"o","r"]
[65.918,"o"," "]
[66.18,"o","d"]
[66.302,"o","e"]
[66.499,"o","l"]
[66.687,"o","e"]
[66.874,"o","t"]
[66.984,"o","e"]
[67.794,"o"," "]
[67.919,"o","d"]
[67.985,"o","e"]
[68.084,"o","m"]
[68.257,"o","o"]
[68.623,"o","\u001b[?2004l\r\r\n"]
[68.637,"o","\u001b[36mINFO\u001b[0m[0000] Deleting cluster 'demo' \r\n"]
[69.822,"o","\u001b[36mINFO\u001b[0m[0001] Deleted k3d-demo-serverlb \r\n"]
[70.309,"o","\u001b[36mINFO\u001b[0m[0001] Deleted k3d-demo-agent-2 \r\n"]
[71.017,"o","\u001b[36mINFO\u001b[0m[0002] Deleted k3d-demo-agent-1 \r\n"]
[71.645,"o","\u001b[36mINFO\u001b[0m[0003] Deleted k3d-demo-agent-0 \r\n"]
[72.274,"o","\u001b[36mINFO\u001b[0m[0003] Deleted k3d-demo-server-2 \r\n"]
[73.264,"o","\u001b[36mINFO\u001b[0m[0004] Deleted k3d-demo-server-1 \r\n"]
[74.155,"o","\u001b[36mINFO\u001b[0m[0005] Deleted k3d-demo-server-0 \r\n"]
[74.155,"o","\u001b[36mINFO\u001b[0m[0005] Deleting cluster network '2324ab59566f5bca41df87cbf7b65e14539cfe9feea1087f143eec45ac91652f' \r\n"]
[74.35,"o","\u001b[36mINFO\u001b[0m[0005] Deleting image volume 'k3d-demo-images' \r\n"]
[74.36,"o","\u001b[36mINFO\u001b[0m[0005] Removing cluster details from default kubeconfig... \r\n"]
[74.362,"o","\u001b[36mINFO\u001b[0m[0005] Removing standalone kubeconfig file (if there is one)... \r\n\u001b[36mINFO\u001b[0m[0005] Successfully deleted cluster demo! \r\n"]
[74.363,"o","\u001b[1m\u001b[7m%\u001b[27m\u001b[1m\u001b[0m \r \r\r\u001b[0m\u001b[27m\u001b[24m\u001b[J\u001b[32mThisCouldBeYou\u001b[0m$ \u001b[K\u001b[?2004h"]
[75.795,"o","\u001b[?2004l\r\r\n"]

@ -325,8 +325,8 @@
<li class="md-nav__item">
<a href="../multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -547,7 +547,7 @@
-i, --image <span class="c1"># specify which k3s image should be used for the nodes</span>
--k3s-agent-arg <span class="c1"># add additional arguments to the k3s agent (see https://rancher.com/docs/k3s/latest/en/installation/install-options/agent-config/#k3s-agent-cli-help)</span>
--k3s-server-arg <span class="c1"># add additional arguments to the k3s server (see https://rancher.com/docs/k3s/latest/en/installation/install-options/server-config/#k3s-server-cli-help)</span>
-m, --masters <span class="c1"># specify how many master nodes you want to create</span>
-m, --servers <span class="c1"># specify how many server nodes you want to create</span>
--network <span class="c1"># specify a network you want to connect to</span>
--no-image-volume <span class="c1"># disable the creation of a volume for storing images (used for the &#39;k3d load image&#39; command)</span>
-p, --port <span class="c1"># add some more port mappings</span>
@ -556,11 +556,11 @@
--update-default-kubeconfig <span class="c1"># enable the automated update of the default kubeconfig with the details of the newly created cluster (also sets &#39;--wait=true&#39;)</span>
--switch-context <span class="c1"># (implies --update-default-kubeconfig) automatically sets the current-context of your default kubeconfig to the new cluster&#39;s context</span>
-v, --volume <span class="c1"># specify additional bind-mounts</span>
--wait <span class="c1"># enable waiting for all master nodes to be ready before returning</span>
-w, --workers <span class="c1"># specify how many worker nodes you want to create</span>
--wait <span class="c1"># enable waiting for all server nodes to be ready before returning</span>
-a, --agents <span class="c1"># specify how many agent nodes you want to create</span>
start CLUSTERNAME <span class="c1"># start a (stopped) cluster</span>
-a, --all <span class="c1"># start all clusters</span>
--wait <span class="c1"># wait for all masters and master-loadbalancer to be up before returning</span>
--wait <span class="c1"># wait for all servers and server-loadbalancer to be up before returning</span>
--timeout <span class="c1"># maximum waiting time for &#39;--wait&#39; before canceling/returning</span>
stop CLUSTERNAME <span class="c1"># stop a cluster</span>
-a, --all <span class="c1"># stop all clusters</span>

@ -316,8 +316,8 @@
<li class="md-nav__item">
<a href="../../multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../../multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -606,7 +606,7 @@ Therefore, we have to create the cluster in a way, that the internal port 80 (wh
<ol>
<li>
<p>Create a cluster, mapping the ingress port 80 to localhost:8081</p>
<p><code class="highlight">k3d cluster create --api-port <span class="m">6550</span> -p <span class="m">8081</span>:80@loadbalancer --workers <span class="m">2</span></code></p>
<p><code class="highlight">k3d cluster create --api-port <span class="m">6550</span> -p <span class="m">8081</span>:80@loadbalancer --agents <span class="m">2</span></code></p>
<div class="admonition info">
<p class="admonition-title">Good to know</p>
<ul>
@ -615,8 +615,8 @@ Therefore, we have to create the cluster in a way, that the internal port 80 (wh
<li>map port <code>8081</code> from the host to port <code>80</code> on the container which matches the nodefilter <code>loadbalancer</code></li>
</ul>
</li>
<li>the <code>loadbalancer</code> nodefilter matches only the <code>masterlb</code> that&rsquo;s deployed in front of a cluster&rsquo;s master nodes<ul>
<li>all ports exposed on the <code>masterlb</code> will be proxied to the same ports on all master nodes in the cluster</li>
<li>the <code>loadbalancer</code> nodefilter matches only the <code>serverlb</code> that&rsquo;s deployed in front of a cluster&rsquo;s server nodes<ul>
<li>all ports exposed on the <code>serverlb</code> will be proxied to the same ports on all server nodes in the cluster</li>
</ul>
</li>
</ul>
@ -662,8 +662,8 @@ Therefore, we have to create the cluster in a way, that the internal port 80 (wh
<h2 id="2-via-nodeport">2. via NodePort<a class="headerlink" href="#2-via-nodeport" title="Permanent link">&para;</a></h2>
<ol>
<li>
<p>Create a cluster, mapping the port 30080 from worker-0 to localhost:8082</p>
<p><code class="highlight">k3d cluster create mycluster -p <span class="m">8082</span>:30080@worker<span class="o">[</span><span class="m">0</span><span class="o">]</span> --workers <span class="m">2</span></code></p>
<p>Create a cluster, mapping the port 30080 from agent-0 to localhost:8082</p>
<p><code class="highlight">k3d cluster create mycluster -p <span class="m">8082</span>:30080@agent<span class="o">[</span><span class="m">0</span><span class="o">]</span> --agents <span class="m">2</span></code></p>
<ul>
<li>Note: Kubernetes&rsquo; default NodePort range is <a href="https://kubernetes.io/docs/concepts/services-networking/service/#nodeport"><code>30000-32767</code></a></li>
</ul>
@ -728,7 +728,7 @@ Therefore, we have to create the cluster in a way, that the internal port 80 (wh
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid" aria-label="Footer">
<a href="../../multimaster/" title="Creating multi-master clusters" class="md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<a href="../../multiserver/" title="Creating multi-server clusters" class="md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<div class="md-footer-nav__button md-icon">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11h12z"/></svg>
</div>
@ -737,7 +737,7 @@ Therefore, we have to create the cluster in a way, that the internal port 80 (wh
<span class="md-footer-nav__direction">
Previous
</span>
Creating multi-master clusters
Creating multi-server clusters
</div>
</div>
</a>

@ -316,8 +316,8 @@
<li class="md-nav__item">
<a href="../../multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../../multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>

@ -372,8 +372,8 @@
<li class="md-nav__item">
<a href="../multimaster/" title="Creating multi-master clusters" class="md-nav__link">
Creating multi-master clusters
<a href="../multiserver/" title="Creating multi-server clusters" class="md-nav__link">
Creating multi-server clusters
</a>
</li>
@ -711,13 +711,13 @@ Note, that with multiple cluster specified, the <code>--switch-context</code> fl
</a>
<a href="../multimaster/" title="Creating multi-master clusters" class="md-footer-nav__link md-footer-nav__link--next" rel="next">
<a href="../multiserver/" title="Creating multi-server clusters" class="md-footer-nav__link md-footer-nav__link--next" rel="next">
<div class="md-footer-nav__title">
<div class="md-ellipsis">
<span class="md-footer-nav__direction">
Next
</span>
Creating multi-master clusters
Creating multi-server clusters
</div>
</div>
<div class="md-footer-nav__button md-icon">

@ -11,7 +11,7 @@
<meta name="description" content="Little helper to run Rancher Lab's k3s in Docker">
<link rel="canonical" href="https://k3d.io/usage/multimaster/">
<link rel="canonical" href="https://k3d.io/usage/multiserver/">
<link rel="shortcut icon" href="../../static/img/favicons_black_blue/favicon.png">
@ -19,7 +19,7 @@
<title>Creating multi-master clusters - k3d</title>
<title>Creating multi-server clusters - k3d</title>
@ -66,7 +66,7 @@
<div data-md-component="skip">
<a href="#creating-multi-master-clusters" class="md-skip">
<a href="#creating-multi-server-clusters" class="md-skip">
Skip to content
</a>
@ -93,7 +93,7 @@
</span>
<span class="md-header-nav__topic md-ellipsis">
Creating multi-master clusters
Creating multi-server clusters
</span>
</div>
@ -325,14 +325,14 @@
<label class="md-nav__link md-nav__link--active" for="__toc">
Creating multi-master clusters
Creating multi-server clusters
<span class="md-nav__icon md-icon">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M3 9h14V7H3v2m0 4h14v-2H3v2m0 4h14v-2H3v2m16 0h2v-2h-2v2m0-10v2h2V7h-2m0 6h2v-2h-2v2z"/></svg>
</span>
</label>
<a href="./" title="Creating multi-master clusters" class="md-nav__link md-nav__link--active">
Creating multi-master clusters
<a href="./" title="Creating multi-server clusters" class="md-nav__link md-nav__link--active">
Creating multi-server clusters
</a>
@ -358,8 +358,8 @@
</li>
<li class="md-nav__item">
<a href="#adding-master-nodes-to-a-running-cluster" class="md-nav__link">
Adding master nodes to a running cluster
<a href="#adding-server-nodes-to-a-running-cluster" class="md-nav__link">
Adding server nodes to a running cluster
</a>
</li>
@ -571,8 +571,8 @@
</li>
<li class="md-nav__item">
<a href="#adding-master-nodes-to-a-running-cluster" class="md-nav__link">
Adding master nodes to a running cluster
<a href="#adding-server-nodes-to-a-running-cluster" class="md-nav__link">
Adding server nodes to a running cluster
</a>
</li>
@ -589,7 +589,7 @@
<article class="md-content__inner md-typeset">
<a href="https://github.com/rancher/k3d/edit/master/docs/usage/multimaster.md" title="Edit this page" class="md-content__button md-icon">
<a href="https://github.com/rancher/k3d/edit/master/docs/usage/multiserver.md" title="Edit this page" class="md-content__button md-icon">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20.71 7.04c.39-.39.39-1.04 0-1.41l-2.34-2.34c-.37-.39-1.02-.39-1.41 0l-1.84 1.83 3.75 3.75M3 17.25V21h3.75L17.81 9.93l-3.75-3.75L3 17.25z"/></svg>
</a>
@ -597,26 +597,26 @@
<h1 id="creating-multi-master-clusters">Creating multi-master clusters<a class="headerlink" href="#creating-multi-master-clusters" title="Permanent link">&para;</a></h1>
<h1 id="creating-multi-server-clusters">Creating multi-server clusters<a class="headerlink" href="#creating-multi-server-clusters" title="Permanent link">&para;</a></h1>
<div class="admonition info">
<p class="admonition-title">Important note</p>
<p>For the best results (and less unexpected issues), choose 1, 3, 5, &hellip; master nodes.</p>
<p>For the best results (and less unexpected issues), choose 1, 3, 5, &hellip; server nodes.</p>
</div>
<h2 id="embedded-dqlite">Embedded dqlite<a class="headerlink" href="#embedded-dqlite" title="Permanent link">&para;</a></h2>
<p>Create a cluster with 3 master nodes using k3s&rsquo; embedded dqlite database.
The first master to be created will use the <code>--cluster-init</code> flag and k3d will wait for it to be up and running before creating (and connecting) the other master nodes.</p>
<div class="highlight"><pre><span></span><code> k3d cluster create multimaster --masters <span class="m">3</span>
<p>Create a cluster with 3 server nodes using k3s&rsquo; embedded dqlite database.
The first server to be created will use the <code>--cluster-init</code> flag and k3d will wait for it to be up and running before creating (and connecting) the other server nodes.</p>
<div class="highlight"><pre><span></span><code> k3d cluster create multiserver --servers <span class="m">3</span>
</code></pre></div>
<h2 id="adding-master-nodes-to-a-running-cluster">Adding master nodes to a running cluster<a class="headerlink" href="#adding-master-nodes-to-a-running-cluster" title="Permanent link">&para;</a></h2>
<h2 id="adding-server-nodes-to-a-running-cluster">Adding server nodes to a running cluster<a class="headerlink" href="#adding-server-nodes-to-a-running-cluster" title="Permanent link">&para;</a></h2>
<p>In theory (and also in practice in most cases), this is as easy as executing the following command:</p>
<div class="highlight"><pre><span></span><code> k3d node create newmaster --cluster multimaster --role master
<div class="highlight"><pre><span></span><code> k3d node create newserver --cluster multiserver --role server
</code></pre></div>
<div class="admonition important">
<p class="admonition-title">There&rsquo;s a trap!</p>
<p>If your cluster was initially created with only a single master node, then this will fail.
That&rsquo;s because the initial master node was not started with the <code>--cluster-init</code> flag and thus is not using the dqlite backend.</p>
<p>If your cluster was initially created with only a single server node, then this will fail.
That&rsquo;s because the initial server node was not started with the <code>--cluster-init</code> flag and thus is not using the dqlite backend.</p>
</div>
@ -626,7 +626,7 @@ That&rsquo;s because the initial master node was not started with the <code>--cl
<div class="md-source-date">
<small>
Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">July 14, 2020</span>
Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">July 15, 2020</span>
</small>
</div>
Loading…
Cancel
Save