mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
85 lines
3.4 KiB
Plaintext
85 lines
3.4 KiB
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * microshift_networking/microshift_multiple_networks/microshift_cni_multus.adoc
|
|
// * networking/multiple_networks/secondary_networks/creating-secondary-nwt-other-cni.adoc
|
|
|
|
//37.1. IPVLAN overview
|
|
// https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/configuring_and_managing_networking/getting-started-with-ipvlan_configuring-and-managing-networking#ipvlan-overview_getting-started-with-ipvlan
|
|
:_mod-docs-content-type: REFERENCE
|
|
|
|
[id="nw-multus-ipvlan-object_{context}"]
|
|
= Configuration for an IPVLAN secondary network
|
|
|
|
[role="_abstract"]
|
|
The IPVLAN CNI plugin JSON configuration object describes the configuration parameters for the IPVLAN, `ipvlan`, CNI plugin. The following table details these parameters:
|
|
|
|
[cols=".^2,.^2,.^6",options="header"]
|
|
|====
|
|
|Field|Type|Description
|
|
|
|
|`cniVersion`
|
|
|`string`
|
|
|The CNI specification version. The `0.3.1` value is required.
|
|
|
|
|`name`
|
|
|`string`
|
|
|The mandatory, unique identifier assigned to this CNI network attachment definition. It is used by the container runtime to select the correct network configuration and serves as the key for persistent resource state management, such as IP address allocations.
|
|
|
|
|`type`
|
|
|`string`
|
|
|The name of the CNI plugin to configure: `ipvlan`.
|
|
|
|
|`ipam`
|
|
|`object`
|
|
|The configuration object for the IPAM CNI plugin. The plugin manages IP address assignment for the attachment definition. This is required unless the plugin is chained.
|
|
|
|
|`mode`
|
|
|`string`
|
|
|Optional: The operating mode for the virtual network. The value must be `l2`, `l3`, or `l3s`. The default value is `l2`.
|
|
|
|
|`master`
|
|
|`string`
|
|
|Optional: The Ethernet interface to associate with the network attachment. If a `master` is not specified, the interface for the default network route is used.
|
|
|
|
|`mtu`
|
|
|`integer`
|
|
|Optional: Set the maximum transmission unit (MTU) to the specified value. The default value is automatically set by the kernel.
|
|
|
|
|`linkInContainer`
|
|
|`boolean`
|
|
|Optional: Specifies whether the `master` interface is in the container network namespace or the main network namespace. Set the value to `true` to request the use of a container namespace `master` interface.
|
|
|
|
|====
|
|
|
|
[IMPORTANT]
|
|
====
|
|
* The `ipvlan` object does not allow virtual interfaces to communicate with the `master` interface. Therefore the container is not able to reach the host by using the `ipvlan` interface. Be sure that the container joins a network that provides connectivity to the host, such as a network supporting the Precision Time Protocol (`PTP`).
|
|
* A single `master` interface cannot simultaneously be configured to use both `macvlan` and `ipvlan`.
|
|
* For IP allocation schemes that cannot be interface agnostic, the `ipvlan` plugin can be chained with an earlier plugin that handles this logic. If the `master` is omitted, then the previous result must contain a single interface name for the `ipvlan` plugin to enslave. If `ipam` is omitted, then the previous result is used to configure the `ipvlan` interface.
|
|
====
|
|
|
|
[id="nw-multus-ipvlan-config-example_{context}"]
|
|
== IPVLAN CNI plugin configuration example
|
|
|
|
The following example configures a secondary network named `ipvlan-net`:
|
|
|
|
[source,json]
|
|
----
|
|
{
|
|
"cniVersion": "0.3.1",
|
|
"name": "ipvlan-net",
|
|
"type": "ipvlan",
|
|
"master": "eth1",
|
|
"linkInContainer": false,
|
|
"mode": "l3",
|
|
"ipam": {
|
|
"type": "static",
|
|
"addresses": [
|
|
{
|
|
"address": "192.168.10.10/24"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
----
|