Using the IDPF network interface (original) (raw)

Bare metal instances available with machine series such as C3 and X4 useInfrastructure Data Plane Function (IDPF), which is a standardized, multi-vendor PCIe network data plane function device. IDPF is a physical device. The IDPF driver is included in the kernel of Linux operating system (OS) images.

Before you begin

Supported features with IDPF

Similar to gVNIC, the following features are supported with IDPF:

Limitations of the IDPF network interface

When using the IDPF network interface, note the following limitations:

Overview of using IDPF with bare metal instances

To create a bare metal instance that uses IDPF, complete the following steps:

  1. Choose a public OS image that supports IDPF, or create a custom OS image that is tagged to use IDPF.
  2. Create a bare metal instance using the public or custom OS image. During instance creation, configure the network interface to use IDPF.
  3. Verify that IDPF is enabled.

Operating system support

On Compute Engine, IDPF is available with a limited number of supported public OS images.

For information about which operating systems are supported with IDPF, see theInterfaces tab for an operating system.

Use on non-supported operating systems

For OS images that don't support IDPF, check with the operating system distributor about including the IDPF driver.

After you get an operating system image that includes IDPF,import a bootable virtual diskthat contains the customized operating system. You can then use the custom OS image to create bare metal instances that use IDPF on that operating system. For more information about creating a custom OS image for use with bare metal instances, seeCreate a custom OS image that supports IDPF on this page.

Create a custom OS image that supports IDPF

If you require a different OS image or version for your bare metal instance than those provided by Google Cloud, you can create the OS image using either the Google Cloud CLI orREST. For detailed information and best practices for creating custom OS images, seeCreate custom OS images.

gcloud

When creating the custom image, either from a Google Cloud provided image or an imported OS image, you must tag the OS image with IDPF. Use thegcloud compute images create commandas shown in the following example:

gcloud compute images create IMAGE_NAME
--source-image=SOURCE_IMAGE
--source-image-project=SOURCE_IMAGE_PROJECT
--guest-os-features=IDPF

Replace the following:

REST

  1. Select an OS image or image family that supports IDPF For more information, seeOperating system details.
  2. Using the OS image or image family selected in the previous step, create an OS image and tag this OS image with IDPF. To create the OS image, use theimages.insert method.
    POST https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/global/images
    {
    "name":"IMAGE_NAME",
    "sourceImage":"SOURCE_IMAGE_URI",
    "guestOsFeatures":[
    {
    "type":"IDPF"
    }
    ]
    }
    Replace the following:
    • IMAGE_NAME: a name for the custom image that you are creating.
    • SOURCE_IMAGE_URI: the URI for the specific OS image or image family that you want to use.
      For example:
      * Specific OS image: "sourceImage": "projects/suse-sap-cloud/global/images/sles-15-sp5-sap-v20240427-x86-64"
      * Image family: "sourceImage": "projects/suse-sap-cloud/global/images/family/sles-15-sp5-sap".

    When you specify an image family, Compute Engine creates a VM from the most recent, non-deprecated OS image in that family. For more information about when to use image families, seeImage family best practices.

You can create a bare metal instance using one of thepublic OS images that supports IDPF or using a custom OS image that you created using the steps inCreate a custom OS image that supports IDPF.

Create a bare metal instance using a public OS image

To create a bare metal instance using a public OS image that supports IDPF, follow the instructions atCreate a bare metal instance.

Create a bare metal instance using a custom OS image

If you aren't using a public OS image that supports IDPF, you must first create a custom OS image that supports IDPF. You then use that custom OS image to create a bare metal instance by using the Google Cloud CLI orREST.

gcloud

  1. Create the bare metal instance by using thegcloud compute instances create command. For the boot disk image, specify the custom OS image that you created earlier. For the network interface, set the value of the nic-type flag to IDPF.
    gcloud compute instances create INSTANCE_NAME \
    --zone=ZONE \
    --image=IMAGE_NAME \
    --image-project=YOUR_IMAGE_PROJECT \
    --network-interface=nic-type=IDPF
    Replace the following:
    • INSTANCE_NAME: a name for the new instance.
    • ZONE: the zone to create the instance in.
    • IMAGE_NAME: the custom OS image that was created previously.
    • YOUR_IMAGE_PROJECT: the name of the project that contains the custom OS image.
  2. Optional: Verify that Compute Engine created the instance and that thenicType is set to IDPF.
    gcloud compute instances describe INSTANCE_NAME \
    --zone=ZONE
    Replace the following:
    • INSTANCE_NAME: the name of the instance.
    • ZONE: the zone that you created the instance in.
      Example
      To create a bare metal instance in zone eu-west4-b using a customized SLES 15 SP5 for SAP OS image named my-sles15sp5-metal-os that's in project my-project-12345, run the following command:
      gcloud compute instances create test-x4-metal-custom-os \
      --zone=eu-west4-b \
      --machine-type=x4-1440-24t-metal \
      --image=my-sles15sp5-metal-os \
      --image-project=my-project-12345 \
      --network-interface=nic-type=IDPF
      Things to consider
      The --network-interface flag has sub-level flags such as the following:
    • --address: Assign an IP address to the instance
    • --network: The network the interface is to be a part of
    • --network-tier: The network tier of the interface
    • --subnet: The subnet that the interface is to be part of. If--network is also specified, the subnet must be a part of the specified network.
    • --private-network-ip: Specify the RFC 1918 IP to assign to the instance.
      For a full list see, the--network-interface flag.

REST

Create the bare metal instance by using theinstances.insert method.

POST https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/zones/ZONE/instances { "name":"INSTANCE_NAME", "networkInterfaces":[ { "nicType":"IDPF", "network":"NETWORK", "subnet":"SUBNET_NAME" } ], "disks":[ { "initializeParams":{ "sourceImage":"projects/YOUR_IMAGE_PROJECT/global/images/IMAGE_NAME" }, "boot":true } ] }

Replace the following:

Verify that IDPF is enabled

You can use the lshw tool to extract detailed information about the hardware configuration of the bare metal instance.

To install the lshw tool on your Linux instance, open an SSH connection to the guest OS, and then run the following command:

sudo apt-get install lshw -y

To determine whether the instance is using the IDPF network interface, run the following command:

sudo lshw -class network

The following shows an example of the output:

*-network description: Ethernet interface product: Intel Corporation vendor: Intel Corporation physical id: 0 bus info: pci@0000:05:00.0 logical name: enp5s0f0 version: 11 serial: 42:01:0a:96:00:02 width: 64 bits clock: 33MHz capabilities: pm msi msix pciexpress bus_master cap_list ethernet physical configuration: autonegotiation=off broadcast=yes driver=idpf driverversion=6.5.0-1023-gcp duplex=full ip=10.150.0.2 latency=0 link=yes multicast=yes resources: iomemory:21ff0-21fef iomemory:21ff0-21fef irq:16 memory:21ffe0000000-21ffefffffff memory:21fff2000000-21fff203ffff

What's next