The following example illustrates how a virtual Ethernet (VE) interface is assigned to a VRF, and how IP addresses and the OSPF protocol are configured.
Important
After a VRF instance is configured on the device, one or more Layer 3 interfaces (physical or virtual Ethernet) must be assigned to the VRF. This causes all existing IP addresses to be deleted; this action also triggers cache deletion, route deletion, and associated cleanup. After assigning an interface to the VRF, the user must reconfigure the IP address and interface properties.device(config)# configure terminal
device(config)# interface ve 10
device(config-if-Ve-10)# vrf forwarding guest
device(config-if-Ve-10)# ip address 192.168.1.254/24
device(config-if-Ve-10)# ip ospf area 0
device(config-if-Ve-10)# ip ospf passive
device(config-if-Ve-10)# exit