You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I need to migrate restsrv01.polito.it to a new server. I do not need to support the generation of new vms since I will be able to create new VMs using crownlabs.
I need to find the configuration of vms that were created in restsrv01 with the p4 switch compiler and all the settings required to interact with the control plane of the two p4 switches
Since VMs will be created via CrownLabs (not KVM), skip the kvm_provision role and run only:
# Bootstrap networking + SDE on each new CrownLabs VM
ansible-playbook playbooks/bootstrap-vms.yaml -i inventory.yaml -K
Key things to keep in mind:
No ProxyCommand needed if CrownLabs VMs are directly reachable (unlike the current restsrv01 bastion setup in inventory.yaml)
Reuse or reassign dataplane IPs — each VM still needs 2 consecutive IPs from 10.10.0.0/24; see the IP table in playbooks/README.md
P4 switch user accounts already exist — no switch re-bootstrap needed unless switches were reset
SR-IOV is server-specific — restsrv01-smartdata01/02 use SR-IOV PCI passthrough defined in host_vars/restsrv01.yaml; CrownLabs VMs will use standard bridged networking instead
Base VM image must have P4 SDE 9.13.2 pre-installed at /opt/p4-sde/bf-sde-9.13.2 (same as the existing ubuntu20.04-p4-sde image used for KVM VMs)
Activity
alessandrocornacchia commentedon Jun 10, 2026
Migration Notes
Current VM inventory
All VMs and their configurations live in:
host_vars/restsrv01.yaml— list of all VMshost_vars/restvm-*.yaml/host_vars/restsrv01-smartdata*.yaml— per-VM config (dataplane IPs, users)restsrv01-smartdata01restsrv01-smartdata02restvm-dauin-01restvm-mamanj-01restvm-mspina-01restvm-mspina-02P4 SDE configuration (per VM)
Defined in
group_vars/all.yamland applied byroles/bootstrap/:/opt/p4-sde/bf-sde-9.13.2bf_kdrv.ko(loaded viaroles/tofino-sde/)p4,sde,p4-build,tfm,iftofinoup/down,switch-intelroles/tofino-sde/tasks/main.yamlP4 switch control plane settings
host_vars/rest-bfsw01.yamlandhost_vars/rest-bfsw02.yaml— control CPU IPs (10.10.0.2–5)playbooks/bootstrap-tofino.yamlgroup_vars/all.yaml→restart_usersMigration with CrownLabs VMs
Since VMs will be created via CrownLabs (not KVM), skip the
kvm_provisionrole and run only:# Bootstrap networking + SDE on each new CrownLabs VM ansible-playbook playbooks/bootstrap-vms.yaml -i inventory.yaml -KKey things to keep in mind:
restsrv01bastion setup ininventory.yaml)10.10.0.0/24; see the IP table inplaybooks/README.mdrestsrv01-smartdata01/02use SR-IOV PCI passthrough defined inhost_vars/restsrv01.yaml; CrownLabs VMs will use standard bridged networking instead/opt/p4-sde/bf-sde-9.13.2(same as the existingubuntu20.04-p4-sdeimage used for KVM VMs)