Page 1 of 1
Hardcode PCI device number
Posted: 8. Nov 2016, 01:40
by duffsterlp
I'm working with a CentOS virtual machine that has consistent network naming. I would like that network name to actually be consistent within VirtualBox. I was wondering if there was a way to hardcode the PCI device ID that is seen by the guest such that I can assume a particular interface name within the guest. On my virtual machine, for example, I see that it maps to PCI device 3. However, is that guaranteed? Does VirtualBox let the user configure which device number is used or is that all internal to VirtualBox?
Re: Hardcode PCI device number
Posted: 8. Nov 2016, 08:00
by socratis
I really don't understand why/how the "PCI device number" is tied to the "network name" of a computer. Can you please explain that?
I haven't seen anything that you can force a specific PCI enumeration, but I may have missed something.
Re: Hardcode PCI device number
Posted: 9. Nov 2016, 19:45
by duffsterlp
I don't mean that the PCI device number maps to a *hostname*. I mean that the PCI device number maps to an *ethernet interface name*.
From:
https://access.redhat.com/documentation ... aming.html
"Scheme 3: Names incorporating physical location of the connector of the hardware (example: enp2s0), are applied if applicable, else falling directly back to scheme 5 in all other cases."
For example, I'm able to modify the interface name for a CentOS VM in VMware ESXi by modifying the PCI device number that is mapped to the virtual network interface within the virtual machine's VMX configuration file. I'm looking for equivalent functionality in VirtualBox.
Re: Hardcode PCI device number
Posted: 9. Nov 2016, 20:38
by socratis
No clue whatsoever. I'm more of a plug and play guy...

Re: Hardcode PCI device number
Posted: 10. Nov 2016, 18:38
by duffsterlp
Re: Hardcode PCI device number
Posted: 10. Nov 2016, 21:08
by socratis
Great, thanks for reporting back and actually including the link to the discussion.