Skip to content

Commit 2b66a67

Browse files
authored
Merge pull request #83981 from jldohmann/OCPBUGS-20134
OCPBUGS-20134: additions for example completion
2 parents 772fa75 + 54d82ef commit 2b66a67

File tree

5 files changed

+118
-2
lines changed

5 files changed

+118
-2
lines changed

installing/installing_bare_metal/upi/installing-bare-metal-network-customizations.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,8 @@ include::modules/installation-user-infra-machines-static-network.adoc[leveloffse
175175

176176
include::modules/rhcos-enabling-multipath.adoc[leveloffset=+2]
177177

178+
include::modules/rhcos-multipath-secondary-disk.adoc[leveloffset=+3]
179+
178180
//iscsi using `coreos-installer install`
179181
include::modules/rhcos-install-iscsi-manual.adoc[leveloffset=+2]
180182

installing/installing_bare_metal/upi/installing-bare-metal.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,8 @@ include::modules/installation-user-infra-machines-static-network.adoc[leveloffse
202202

203203
include::modules/rhcos-enabling-multipath.adoc[leveloffset=+2]
204204

205+
include::modules/rhcos-multipath-secondary-disk.adoc[leveloffset=+3]
206+
205207
//iscsi using `coreos-installer install`
206208
include::modules/rhcos-install-iscsi-manual.adoc[leveloffset=+2]
207209

installing/installing_bare_metal/upi/installing-restricted-networks-bare-metal.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,8 @@ include::modules/installation-user-infra-machines-static-network.adoc[leveloffse
196196

197197
include::modules/rhcos-enabling-multipath.adoc[leveloffset=+2]
198198

199+
include::modules/rhcos-multipath-secondary-disk.adoc[leveloffset=+3]
200+
199201
//iscsi using `coreos-installer install`
200202
include::modules/rhcos-install-iscsi-manual.adoc[leveloffset=+2]
201203

modules/rhcos-enabling-multipath.adoc

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ The following procedure enables multipath at installation time and appends kerne
2727
{product-title} does not support enabling multipathing as a day-2 activity on nodes that have been upgraded from 4.6 or earlier.
2828
====
2929

30+
.Prerequisites
31+
32+
* You have created the Ignition config files for your cluster.
33+
34+
* You have reviewed _Installing {op-system} and starting the {product-title} bootstrap process_.
35+
3036
.Procedure
3137

3238
. To enable multipath and start the `multipathd` daemon, run the following command on the installation host:
@@ -43,7 +49,8 @@ $ mpathconf --enable && systemctl start multipathd.service
4349
+
4450
[source,terminal]
4551
----
46-
$ coreos-installer install /dev/mapper/mpatha \ <1>
52+
$ coreos-installer install /dev/mapper/mpatha \// <1>
53+
--ignition-url=http://host/worker.ign \
4754
--append-karg rd.multipath=default \
4855
--append-karg root=/dev/disk/by-label/dm-mpath-root \
4956
--append-karg rw
@@ -54,7 +61,8 @@ $ coreos-installer install /dev/mapper/mpatha \ <1>
5461
+
5562
[source,terminal]
5663
----
57-
$ coreos-installer install /dev/disk/by-id/wwn-<wwn_ID> \ <1>
64+
$ coreos-installer install /dev/disk/by-id/wwn-<wwn_ID> \// <1>
65+
--ignition-url=http://host/worker.ign \
5866
--append-karg rd.multipath=default \
5967
--append-karg root=/dev/disk/by-label/dm-mpath-root \
6068
--append-karg rw
@@ -63,6 +71,8 @@ $ coreos-installer install /dev/disk/by-id/wwn-<wwn_ID> \ <1>
6371
+
6472
This symlink can also be used as the `coreos.inst.install_dev` kernel argument when using special `coreos.inst.*` arguments to direct the live installer. For more information, see "Installing {op-system} and starting the {product-title} bootstrap process".
6573

74+
. Reboot into the installed system.
75+
6676
. Check that the kernel arguments worked by going to one of the worker nodes and listing the kernel command line arguments (in `/proc/cmdline` on the host):
6777
+
6878
[source,terminal]
Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * installing/installing_bare_metal/upi/installing-bare-metal.adoc
4+
// * installing/installing_bare_metal/upi/installing-bare-metal-network-customizations.adoc
5+
// * installing/installing_bare_metal/upi/installing-restricted-networks-bare-metal.adoc
6+
7+
:_mod-docs-content-type: PROCEDURE
8+
[id="rhcos-multipath-secondary-disk_{context}"]
9+
= Enabling multipathing on secondary disks
10+
11+
{op-system} also supports multipathing on a secondary disk. Instead of kernel arguments, you use Ignition to enable multipathing for the secondary disk at installation time.
12+
13+
.Prerequisites
14+
15+
* You have read the section _Disk partitioning_.
16+
* You have read _Enabling multipathing with kernel arguments on {op-system}_.
17+
* You have installed the Butane utility.
18+
19+
.Procedure
20+
21+
. Create a Butane config with information similar to the following:
22+
+
23+
.Example `multipath-config.bu`
24+
[source,yaml]
25+
----
26+
variant: openshift
27+
version: {product-version}.0
28+
systemd:
29+
units:
30+
- name: mpath-configure.service
31+
enabled: true
32+
contents: |
33+
[Unit]
34+
Description=Configure Multipath on Secondary Disk
35+
ConditionFirstBoot=true
36+
ConditionPathExists=!/etc/multipath.conf
37+
Before=multipathd.service <1>
38+
DefaultDependencies=no
39+
40+
[Service]
41+
Type=oneshot
42+
ExecStart=/usr/sbin/mpathconf --enable <2>
43+
44+
[Install]
45+
WantedBy=multi-user.target
46+
- name: mpath-var-lib-container.service
47+
enabled: true
48+
contents: |
49+
[Unit]
50+
Description=Set Up Multipath On /var/lib/containers
51+
ConditionFirstBoot=true <3>
52+
Requires=dev-mapper-mpatha.device
53+
After=dev-mapper-mpatha.device
54+
After=ostree-remount.service
55+
Before=kubelet.service
56+
DefaultDependencies=no
57+
58+
[Service] <4>
59+
Type=oneshot
60+
ExecStart=/usr/sbin/mkfs.xfs -L containers -m reflink=1 /dev/mapper/mpatha
61+
ExecStart=/usr/bin/mkdir -p /var/lib/containers
62+
63+
[Install]
64+
WantedBy=multi-user.target
65+
- name: var-lib-containers.mount
66+
enabled: true
67+
contents: |
68+
[Unit]
69+
Description=Mount /var/lib/containers
70+
After=mpath-var-lib-containers.service
71+
Before=kubelet.service <5>
72+
73+
[Mount] <6>
74+
What=/dev/disk/by-label/dm-mpath-containers
75+
Where=/var/lib/containers
76+
Type=xfs
77+
78+
[Install]
79+
WantedBy=multi-user.target
80+
----
81+
<1> The configuration must be set before launching the multipath daemon.
82+
<2> Starts the `mpathconf` utility.
83+
<3> This field must be set to the value `true`.
84+
<4> Creates the filesystem and directory `/var/lib/containers`.
85+
<5> The device must be mounted before starting any nodes.
86+
<6> Mounts the device to the `/var/lib/containers` mount point. This location cannot be a symlink.
87+
88+
. Create the Ignition configuration by running the following command:
89+
+
90+
[source,terminal]
91+
----
92+
$ butane --pretty --strict multipath-config.bu > multipath-config.ign
93+
----
94+
95+
. Continue with the rest of the first boot {op-system} installation process.
96+
+
97+
[IMPORTANT]
98+
====
99+
Do not add the `rd.multipath` or `root` kernel arguments on the command-line during installation unless the primary disk is also multipathed.
100+
====

0 commit comments

Comments
 (0)