 b0c38784b5
			
		
	
	b0c38784b5
	
	
	
		
			
			Updated Patchset 1 comments Signed-off-by: Juanita-Balaraj <juanita.balaraj@windriver.com> Change-Id: I75253277515425e9b933686635a62e3f63141e93 Signed-off-by: Juanita-Balaraj <juanita.balaraj@windriver.com>
		
			
				
	
	
	
		
			3.1 KiB
		
	
	
	
	
	
	
	
			
		
		
	
	Configure a PCI Alias in Nova
passthrough devices are exposed to using system-wide alias.
Each alias specifies matching optional attributes: vendor_id, product_id, and device_type.
where
- name
- 
is a string identifying the alias 
- device_id
- 
is the device_id value obtained from the device list 
- vendor_id
- 
is the vendor_id value obtained from the device list 
- device_type
- 
is a string indicating the type of device to add (valid values are: type-PCI, type-PF, or type-VF) 
The following command displays the current configured aliases:
$ kubectl exec -it -n openstack \
$(kubectl get pod --selector=application=nova,component=os-api -o name -n openstack) -- grep -e '\[pci\]' -e alias /etc/nova/nova.confBy default it contains a list of general aliases, such as:
[pci]
alias = {"vendor_id": "8086", "product_id": "0435", "name": "qat-dh895xcc-pf"}
alias = {"vendor_id": "8086", "product_id": "0443", "name": "qat-dh895xcc-vf"}
alias = {"vendor_id": "8086", "product_id": "37c8", "name": "qat-c62x-pf"}
alias = {"vendor_id": "8086", "product_id": "37c9", "name": "qat-c62x-vf"}
alias = {"name": "gpu"}Additional aliases may configured using a helm override for nova.
The following example replaces the previous list of aliases with a custom list.
- Create a yaml configuration file containing the configuration update. - ~(keystone_admin)]$ cat << EOF > ./gpu_override.yaml conf: nova: pci: alias: type: multistring values: - '{"vendor_id": "8086", "product_id": "0435", "name": "qat-dh895xcc-pf"}' - '{"vendor_id": "8086", "product_id": "0443", "name": "qat-dh895xcc-vf"}' - '{"vendor_id": "8086", "product_id": "37c8", "name": "qat-c62x-pf"}' - '{"vendor_id": "8086", "product_id": "37c9", "name": "qat-c62x-vf"}' - '{"name": "gpu"}' - '{"vendor_id": "102b", "product_id": "0522", "name": "matrox-g200e"}' - '{"vendor_id": "10de", "product_id": "13f2", "name": "nvidia-tesla-m60"}' - '{"vendor_id": "10de", "product_id": "1b38", "name": "nvidia-tesla-p40"}' - '{"vendor_id": "10de", "product_id": "1eb8", "device_type": "type-PF", "name": "nvidia-tesla-t4-pf"}' EOF
- Update the Helm overrides using the new configuration file. - ~(keystone_admin)]$ system helm-override-update --reuse-values --values ./gpu_override.yaml -openstack nova openstack --reuse-values 
- Apply the changes. - ~(keystone_admin)]$ system application-apply -openstack