From 26dd24e3f5352f789e5dda13735082ddddf60617 Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Tue, 22 Jun 2021 02:22:15 -0400 Subject: [PATCH] Ensure MTU is set on VF when starting up --- node-daemon/pvcnoded/SRIOVVFInstance.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/node-daemon/pvcnoded/SRIOVVFInstance.py b/node-daemon/pvcnoded/SRIOVVFInstance.py index be9ffbc7..ddc1abca 100644 --- a/node-daemon/pvcnoded/SRIOVVFInstance.py +++ b/node-daemon/pvcnoded/SRIOVVFInstance.py @@ -41,9 +41,11 @@ class SRIOVVFInstance(object): self.pf = self.zkhandler.read(('node.sriov.vf', self.myhostname, 'sriov_vf.pf', self.vf)) self.mtu = self.zkhandler.read(('node.sriov.vf', self.myhostname, 'sriov_vf.mtu', self.vf)) - self.vfid = self.vf.replace('{}v'.format(self.pf), '') + self.logger.out('Setting MTU to {}'.format(self.mtu), state='i', prefix='SR-IOV VF {}'.format(self.vf)) + common.run_os_command('ip link set {} mtu {}'.format(self.vf, self.mtu)) + # These properties are set via the DataWatch functions, to ensure they are configured on the system self.mac = None self.vlan_id = None