|
1 | 1 | // Module included in the following assemblies: |
2 | 2 | // |
3 | | -// * post_installation_configuration/machine-configuration-tasks.adoc |
| 3 | +// * installing/installing_bare_metal/installing-bare-metal.adoc |
| 4 | +// * installing/installing_bare_metal/installing-bare-metal-network-customizations.adoc |
| 5 | +// * installing/installing_bare_metal/installing-restricted-networks-bare-metal.adoc |
4 | 6 |
|
5 | 7 | [id="rhcos-enabling-multipath_{context}"] |
6 | 8 | = Enabling multipathing with kernel arguments on {op-system} |
7 | 9 |
|
8 | 10 | {op-system} supports multipathing on the primary disk, allowing stronger resilience to hardware failure to achieve higher host availability. |
9 | 11 |
|
10 | | -[IMPORTANT] |
11 | | -==== |
12 | | -Multipathing is only supported when it is activated using the machine config as documented in the following procedure. It must be enabled after {op-system} installation. |
13 | | -==== |
| 12 | +You can enable multipathing at installation time for nodes that were provisioned in {product-title} 4.8 or later. While post-installation support is available by activating multipathing via the machine config, enabling multipathing during installation is recommended. |
| 13 | + |
| 14 | +In setups where any I/O to non-optimized paths results in I/O system errors, you must enable multipathing at installation time. |
14 | 15 |
|
15 | 16 | [IMPORTANT] |
16 | 17 | ==== |
17 | | -On IBM Z and LinuxONE, you can enable multipathing only if you configured your cluster for it during installation. For more information, see "Creating {op-system-first} machines" in _Installing a cluster with z/VM on IBM Z and LinuxONE_. |
| 18 | +On IBM Z and LinuxONE, you can enable multipathing only if you configured your cluster for it during installation. For more information, see "Installing {op-system} and starting the {product-title} bootstrap process" in _Installing a cluster with z/VM on IBM Z and LinuxONE_. |
18 | 19 | ==== |
19 | 20 | // Add xref once it's allowed. |
20 | 21 |
|
| 22 | +The following procedure enables multipath at installation time and appends kernel arguments to the `coreos-installer install` command so that the installed system itself will use multipath beginning from the first boot. |
| 23 | + |
21 | 24 | .Prerequisites |
22 | | -* You have a running {product-title} cluster that uses version 4.7 or later. |
| 25 | +* You have a running {product-title} cluster that uses version 4.8 or later. |
23 | 26 | * You are logged in to the cluster as a user with administrative privileges. |
24 | 27 |
|
25 | 28 | .Procedure |
26 | 29 |
|
27 | | -. To enable multipathing on control plane nodes (also known as the master nodes): |
28 | | - |
29 | | -* Create a machine config file, such as `99-master-kargs-mpath.yaml`, that instructs the cluster to add the `master` label and that identifies the multipath kernel argument, for example: |
30 | | - |
31 | | -+ |
32 | | -[source,yaml] |
33 | | ----- |
34 | | -apiVersion: machineconfiguration.openshift.io/v1 |
35 | | -kind: MachineConfig |
36 | | -metadata: |
37 | | - labels: |
38 | | - machineconfiguration.openshift.io/role: "master" |
39 | | - name: 99-master-kargs-mpath |
40 | | -spec: |
41 | | - kernelArguments: |
42 | | - - rd.multipath=default |
43 | | - - root=/dev/disk/by-label/dm-mpath-root |
44 | | ----- |
45 | | - |
46 | | -. To enable multipathing on worker nodes: |
47 | | - |
48 | | -* Create a machine config file, such as `99-worker-kargs-mpath.yaml`, that instructs the cluster to add the `worker` label and that identifies the multipath kernel argument, for example: |
49 | | -+ |
50 | | -[source,yaml] |
51 | | ----- |
52 | | -apiVersion: machineconfiguration.openshift.io/v1 |
53 | | -kind: MachineConfig |
54 | | -metadata: |
55 | | - labels: |
56 | | - machineconfiguration.openshift.io/role: "worker" |
57 | | - name: 99-worker-kargs-mpath |
58 | | -spec: |
59 | | - kernelArguments: |
60 | | - - rd.multipath=default |
61 | | - - root=/dev/disk/by-label/dm-mpath-root |
62 | | ----- |
63 | | - |
64 | | -. Create the new machine config by using either the master or worker YAML file you previously created: |
| 30 | +. To enable multipath and start the `multipathd` daemon, run the following command: |
65 | 31 | + |
66 | 32 | [source,terminal] |
67 | 33 | ---- |
68 | | -$ oc create -f ./99-master-kargs-mpath.yaml |
| 34 | +$ mpathconf --enable && systemctl start multipathd.service |
69 | 35 | ---- |
| 36 | +** Optional: If booting the PXE or ISO, you can instead enable multipath by adding `rd.multipath=default` from the kernel command line. |
70 | 37 |
|
71 | | -. Check the machine configs to see that the new one was added: |
| 38 | +. Append the kernel arguments by invoking the `coreos-installer` program: |
72 | 39 | + |
73 | | -[source,terminal] |
74 | | ----- |
75 | | -$ oc get MachineConfig |
76 | | ----- |
| 40 | +* If there is only one multipath device connected to the machine, it should be available at path `/dev/mapper/mpatha`. For example: |
77 | 41 | + |
78 | | -.Example output |
79 | 42 | [source,terminal] |
80 | 43 | ---- |
81 | | -NAME GENERATEDBYCONTROLLER IGNITIONVERSION AGE |
82 | | -00-master 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
83 | | -00-worker 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
84 | | -01-master-container-runtime 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
85 | | -01-master-kubelet 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
86 | | -01-worker-container-runtime 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
87 | | -01-worker-kubelet 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
88 | | -99-master-kargs-mpath 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 105s |
89 | | -99-master-generated-registries 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
90 | | -99-master-ssh 3.2.0 40m |
91 | | -99-worker-generated-registries 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
92 | | -99-worker-ssh 3.2.0 40m |
93 | | -rendered-master-23e785de7587df95a4b517e0647e5ab7 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
94 | | -rendered-worker-5d596d9293ca3ea80c896a1191735bb1 52dd3ba6a9a527fc3ab42afac8d12b693534c8c9 3.2.0 33m |
| 44 | +$ coreos-installer install /dev/mapper/mpatha \ <1> |
| 45 | +--append-karg rd.multipath=default \ |
| 46 | +--append-karg root=/dev/disk/by-label/dm-mpath-root |
95 | 47 | ---- |
96 | | - |
97 | | -. Check the nodes: |
| 48 | +<1> Indicates the path of the single multipathed device. |
98 | 49 | + |
99 | | -[source,terminal] |
100 | | ----- |
101 | | -$ oc get nodes |
102 | | ----- |
| 50 | +* If there are multiple multipath devices connected to the machine, or to be more explicit, instead of using `/dev/mapper/mpatha`, it is recommended to use the World Wide Name (WWN) symlink available in `/dev/disk/by-id`. For example: |
103 | 51 | + |
104 | | -.Example output |
105 | 52 | [source,terminal] |
106 | 53 | ---- |
107 | | -NAME STATUS ROLES AGE VERSION |
108 | | -ip-10-0-136-161.ec2.internal Ready worker 28m v1.20.0 |
109 | | -ip-10-0-136-243.ec2.internal Ready master 34m v1.20.0 |
110 | | -ip-10-0-141-105.ec2.internal Ready,SchedulingDisabled worker 28m v1.20.0 |
111 | | -ip-10-0-142-249.ec2.internal Ready master 34m v1.20.0 |
112 | | -ip-10-0-153-11.ec2.internal Ready worker 28m v1.20.0 |
113 | | -ip-10-0-153-150.ec2.internal Ready master 34m v1.20.0 |
| 54 | +$ coreos-installer install /dev/disk/by-id/wwn-<wwn_ID> \ <1> |
| 55 | +--append-karg rd.multipath=default \ |
| 56 | +--append-karg root=/dev/disk/by-label/dm-mpath-root |
114 | 57 | ---- |
| 58 | +<1> Indicates the WWN ID of the target multipathed device. For example, `0xx194e957fcedb4841`. |
115 | 59 | + |
116 | | -You can see that scheduling on each worker node is disabled as the change is being applied. |
| 60 | +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". |
117 | 61 |
|
118 | | -. Check that the kernel argument worked by going to one of the worker nodes and listing |
119 | | -the kernel command line arguments (in `/proc/cmdline` on the host): |
| 62 | +. 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): |
120 | 63 | + |
121 | 64 | [source,terminal] |
122 | 65 | ---- |
|
0 commit comments