Hello!
I encountered an issue while trying to create SVI interface on a MELLANOX switch model MSN2410-BB2F with Puppet.
I was using Mellanox MLNX-OS® User Manual for Ethernet. According to this guide the manifest should have look like this:
class l3int{
netdev_device { $hostname: }
$vlans = {
‘vlan 347’ => { ensure => present, ipaddress =>‘192.168.4.2’, netmask =>‘255.255.255.0’ }
}
create_resources( netdev_l3_interface, $vlans )
}
But after executing it puppet-agent on switch returns an error:
show puppet-agent log continuous
Wed Dec 13 13:20:35 +0000 2017 Puppet (err): Could not set ‘present’ on ensure: Error: return code = 1 return msg = line:1|Action /ifd/actions/ip_interface parameter ifindex has bad type: string expected uint32
Wed Dec 13 13:20:35 +0000 2017 Puppet (err): Could not set ‘present’ on ensure: Error: return code = 1 return msg = line:1|Action /ifd/actions/ip_interface parameter ifindex has bad type: string expected uint32
Wrapped exception:
Error: return code = 1 return msg = line:1|Action /ifd/actions/ip_interface parameter ifindex has bad type: string expected uint32
Wed Dec 13 13:20:35 +0000 2017 /Stage[main]/L3int/Netdev_l3_interface[vlan 347]/ensure (err): change from absent to present failed: Could not set ‘present’ on ensure: Error: return code = 1 return msg = line:1|Action /ifd/actions/ip_interface parameter ifindex has bad type: string expected uint32
While trying to solve this problem i founded, that after manually creating a SVI interface with this vlan puppet seccessefuly assign an ip address with same manifest:
hostname [standalone: master] (config) # int vlan 347
hostname [standalone: master] (config interface vlan 347) # ex
hostname [standalone: master] (config) # ex
Wed Dec 13 13:11:23 +0000 2017 Puppet (notice): Starting Puppet client version 3.2.3
Wed Dec 13 13:11:33 +0000 2017 /Stage[main]/L3int/Netdev_l3_interface[vlan 347]/ipaddress (notice): ipaddress changed ‘0.0.0.0’ to ‘192.168.4.2’
Wed Dec 13 13:11:33 +0000 2017 /Stage[main]/L3int/Netdev_l3_interface[vlan 347]/netmask (notice): netmask changed ‘0.0.0.0’ to ‘255.255.255.0’
Could you provide any guidance to resolve this issue and make the manifest fully operational?