Skip to content

Instantly share code, notes, and snippets.

@phoracek
Created January 7, 2021 11:14
Show Gist options
  • Select an option

  • Save phoracek/5135fddc586595bcbee3fd91e353ca4e to your computer and use it in GitHub Desktop.

Select an option

Save phoracek/5135fddc586595bcbee3fd91e353ca4e to your computer and use it in GitHub Desktop.
Jumbo frames test on kubevirtci
make cluster-down
KUBEVIRT_WITH_CNAO=true make cluster-up
make cluster-sync
./cluster-up/cli.sh ssh node01 'sudo ip link add br10 type bridge && sudo ip link set dev br10 mtu 9000'
cat <<EOF | ./cluster-up/kubectl.sh apply -f -
apiVersion: "k8s.cni.cncf.io/v1"
kind: NetworkAttachmentDefinition
metadata:
name: br10
spec:
config: '{
"cniVersion": "0.3.1",
"name": "cnv-bridge-conf",
"plugins": [
{
"type": "bridge",
"bridge": "br10",
"mtu": 9000
},
{
"type": "tuning"
}
]
}'
EOF
cat <<EOF | ./cluster-up/kubectl.sh apply -f -
apiVersion: kubevirt.io/v1
kind: VirtualMachineInstance
metadata:
labels:
special: vmi-multus-multiple-net
name: vmi-multus-multiple-net
spec:
domain:
devices:
disks:
- disk:
bus: virtio
name: containerdisk
- disk:
bus: virtio
name: cloudinitdisk
interfaces:
- bridge: {}
name: secondary
rng: {}
machine:
type: ""
resources:
requests:
memory: 1024M
networks:
- multus:
networkName: br10
name: secondary
terminationGracePeriodSeconds: 0
volumes:
- containerDisk:
image: kubevirt/fedora-cloud-container-disk-demo:latest
name: containerdisk
- cloudInitNoCloud:
userData: |
#!/bin/bash
echo "fedora" |passwd fedora --stdin
name: cloudinitdisk
EOF
./cluster-up/virtctl.sh console vmi-multus-multiple-net
# fedora:fedora
# ip l
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment