In my environment, I have a guest server running influxdb listening on port 8086. I'd like to forward port 8086 from the host to the guest.
This is the definition of the network:
Code: Select all
<network>
<name>mgmt_nat</name>
<forward dev='ens33' mode='nat'>
<interface dev='ens33'/>
</forward>
<bridge name='mgmt_nat' stp='on' delay='0'/>
<ip address='192.168.50.1' netmask='255.255.255.0'>
<dhcp>
<range start="192.168.50.128" end="192.168.50.254"/>
<host mac='52:54:00:a0:50:08' name='vdicinfluxdb01' ip='192.168.50.8'/>
</dhcp>
</ip>
</network>
Code: Select all
<interface type='network'>
<mac address='52:54:00:a0:50:08'/>
<source network='mgmt_nat'/>
<model type='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
</interface>
Code: Select all
firewall-cmd --zone=public --add-rich-rule='rule family="ipv4" source address="0.0.0.0/0" accept' --permanent
firewall-cmd --zone=public --change-interface=ens33 --permanent
firewall-cmd --zone=public --add-masquerade --permanent
firewall-cmd --zone=public --add-forward-port=port=8086:proto=tcp:toport=8086:toaddr=192.168.50.8 --permanent
Thanks a lot, any help will be welcome!!!