home

Supported platforms

Vyatta documentation

Learn how to install, configure, and operate the Vyatta Network Operating System (Vyatta NOS) and Orchestrator, which help drive our virtual networking and physical platforms portfolio.

Configuring service chaining by using a hybrid model

Consider a scenario in which you have two guest VM1 and VM2, as illustrated in the following network diagram. These guest can be any services such as vNAT, vFW, vDPI, and so on.

The following list presents the components of the topology.
  • dp0p0s20f1 and dp0p0s2f0 are the ingress and egress interfaces, respectively, for vCPE and the vhost.

  • vhost0 and vhost1 are the virtual interfaces for VM1.
  • vhost2 and vhost3 are the virtual interfaces for VM2.
  • sc1-h1 is the PBR policies that are applied to dp0p0s20f1.
  • dp0vhost1 and vhost dp0vhost2 are in cross-connect.
Figure 1. Service chaining by using a hybrid model

In the topology, to perform service chaining between VM1 and VM2, the PBR policy is applied on dp0p0s20f1, and the route policy lookup is performed on all packets that are received on the dp0p0s20f1 interfaces. If there is a match, the route lookup is performed on the corresponding PBR table 1. All packets that are received on dp0p0s20f2 are forwarded to dp0vhost0, and the traffic received on dp0vhost1 is forwarded to dp0vhost2.

Table 1. Configuring service chaining by using a hybrid model
Steps Commands

Configure cross-connect.

vyatta@vyatta# set policy route pbr sc1-h1 rule 1 action 'accept'
vyatta@vyatta# set policy route pbr sc1-h1 rule 1 address-family 'ipv4'
vyatta@vyatta# set policy route pbr sc1-h1 rule 1 table '1

vyatta@vyatta# set interfaces vhost dp0vhost1 xconnect vhost dp0vhost2
vyatta@vyatta# set interfaces vhost dp0vhost2 xconnect vhost dp0vhost1

Configuring the static route

vyatta@vyatta# set protocols static table 1 route 0.0.0.0/0 next-hop '11.11.11.2'

Attach the PBR policy to the corresponding interface.

vyatta@vyatta# set interfaces dataplane dp0p0s20f1 policy route pbr 'sc1-h1'

Configure the IP addresses on the interfaces.

vyatta@vyatta# set interfaces dataplane dp0p0s20f1 address '192.0.2.1/24'
vyatta@vyatta# set interfaces dataplane dp0p0s20f0 address '198.51.100.1/24'
vyatta@vyatta# set interfaces vhost dp0vhost0 address '11.11.11.1/24'

Commit the configuration.

vyatta@vyatta# commit

Save the configuration.

vyatta@vyatta# save