Vyatta Network OS Documentation

Learn how to install, configure and operate the Vyatta NOS, which helps drive our virtual networking & physical platforms portfolio.

Configuring NAT

The Internet gateway should send outbound traffic from the office LAN out through the Internet-facing interface, translating all internal private IP addresses to a single public address. This translation is done by defining a Network Address Translation (NAT) rule.

Define a NAT rule

Define a rule that allows traffic from the 192.168.1.0/24 network to proceed to the Internet through the dp0p1p1 interface and translates any internal addresses to the IP address of dp0p1p1. (This translation is called “masquerade” translation.)


vyatta@R1# set service nat source rule 10 source address 192.168.1.0/24
[edit]
vyatta@R1# set service nat source rule 10 outbound-interface dp0p1p1
[edit]
vyatta@R1# set service nat source rule 10 translation address masquerade
[edit]
vyatta@R1# commit
[edit]
vyatta@R1# 
            

Here is this configuration.


vyatta@R1# show nat source
	rule 10 {
		outbound-interface dp0p1p1
		source {
			address 192.168.1.0/24
		}
		translation {
			address masquerade
		}
	}
[edit]
vyatta@R1#