diff --git a/subiquitycore/models/network.py b/subiquitycore/models/network.py index 4ee7f401..3006817a 100644 --- a/subiquitycore/models/network.py +++ b/subiquitycore/models/network.py @@ -65,11 +65,12 @@ class Networkdev: if self.type == 'bond': bond = self._net_info.bond self._configuration['interfaces'] = bond['slaves'] - self._configuration['parameters'] = { - 'mode': bond['mode'], - 'lacp-rate': bond['lacp_rate'], - 'transmit-hash-policy': bond['xmit_hash_policy'], - } + params = {'mode': bond['mode']} + if bond['mode'] in ['balance-xor', '802.3ad', 'balance-tlb']: + params['transmit-hash-policy'] = bond['xmit_hash_policy'] + if bond['mode'] == '802.3ad': + params['lacp-rate'] = bond['lacp_rate'] + self._configuration['parameters'] = params def render(self): if (self.configured_ip_addresses or self.dhcp4 or self.dhcp6 or