{"action":"created","comment":{"url":"https://api.github.com/repos/FRRouting/frr/pulls/comments/183794748","pull_request_review_id":114861296,"id":183794748,"diff_hunk":"@@ -351,6 +360,143 @@ default) should the specified gateways not be reachable. Eg:\n \n .. _multicast-rib-commands:\n \n+VRF Commands\n+============\n+\n+Currently, the user has the possibility to configure VRFs. VRF is a way to\n+separate networking contexts on the same machine. Those networking contexts\n+stick to separate interfaces, thus making it possible to associate one interface\n+to a specific VRF.\n+VRF can be used, for example, when instantiating per enterprise networking\n+services, without having to instantiate the physical host machine or the\n+routing management daemons for each enterprise. As a result, interfaces are\n+separate for each set of VRF, and routing daemons can have their own context\n+for each VRF.\n+\n+This conceptual view introduces the `Default VRF` case. If the user does not\n+configure any specific VRF, then by default, the user will however configure\n+the `Default VRF`.\n+On the Zebra context, this can be done when being in configuration mode, when\n+configuring a static route `ip route NETWORK GATEWAY`.\n+\n+   .. code-block:: frr\n+\n+      # case without VRF\n+      configure terminal\n+      ip route 10.0.0.0 255.255.255.0 10.0.0.2\n+      exit\n+\n+Configuring VRF networking contexts can be done on various ways on FRR.\n+The VRF interfaces can be configured by entering in interface configuration\n+mode : `interface INTERFACE VRF`. Also, if the user wants to configure a static\n+route for a specific VRF, then a specific VRF configuration mode is available.\n+After entering into that mode by following command: `vrf VRF`. the user can\n+enter the same route command as before, but this time, the route command\n+will apply to vrf VRF.\n+\n+   .. code-block:: frr\n+\n+      # case with VRF\n+      configure terminal\n+      vrf r1-cust1\n+       ip route 10.0.0.0 255.255.255.0 10.0.0.2\n+      exit-vrf\n+\n+A VRF backend mode is chosen when running zebra.\n+\n+If no option is chosen, then the `Linux VRF lite` implementation\n+will be mapped over the Zebra VRF. The routing table associated to\n+that VRF is a Linux table identifier located in the same `Linux\n+network namespace` where Zebra started.\n+\n+If the -n option is chosen, then the `Linux network namespace`\n+will be mapped over the Zebra VRF. That implies that Zebra is\n+able to configure several `Linux network namespaces`.  The routing\n+table associated to that VRF is the whole routing tables located\n+in that namespace. For instance, this mode matches Opentack or 6WIND\n+Linux vRouters ; others have reported to use this mode too. The\n+default behavior remains Linux VRF lite that os widely used by Cumulus\n+Linux.\n+\n+Because of that difference, there are some subtle differences when running\n+some commands in relationship to VRF. Here is an extract of some of those\n+commands:\n+\n+.. index:: vrf VRF\n+.. clicmd:: vrf VRF\n+\n+    This command is available on configuration mode.\n+    By default, above command permits accessing the vrf configuration mode.\n+    This mode is available for both VRFs. It is to be noted that Zebra does\n+    not create `Linux VRF`.\n+    Provisioning this command is used to keep the configuration intact.\n+\n+.. index:: netns NAMESPACE\n+.. clicmd:: netns NAMESPACE\n+\n+    This command is based on VRF configuration mode.\n+    This command is available when Zebra is run in `-n` mode.\n+    This command reflects which `Linux network namespace` is to be\n+    mapped with Zebra VRF. It is to be noted that Zebra creates\n+    and detects added/suppressed VRFs from the Linux environment\n+    (in fact, those managed with iproute2).\n+    Provisioning this command is used to keep the configuration intact.\n+\n+.. index:: ip route NETWORK NETMASK GATEWAY\n+.. clicmd:: ip route NETWORK NETMASK GATEWAY\n+\n+    This command is based on VRF configuration mode or in configuration mode.\n+    If applied on configuration mode, this applies to default VRF. Otherwise,\n+    this command applies to the VRF of the vrf configuration mode.\n+    By default, above command permits configuring a network in the table\n+    identifier of the mentioned VRF.\n+    If `-n` option is given, the network will be configured in the default\n+    routing table of the `Linux network namespace` <VRF>.\n+\n+.. index:: ip route NETWORK NETMASK GATEWAY NEXTHOPVRF\n+.. clicmd:: ip route NETWORK NETMASK GATEWAY NEXTHOPVRF\n+\n+    This command is based on VRF configuration mode or in configuration mode.\n+    If applied on configuration mode, this applies to default VRF. Otherwise,\n+    this command applies to the VRF of the vrf configuration mode.\n+    This command is used to configure a vrf route leak across 2 VRFs.\n+    This command is only available when Zebra is launched without `-n` option\n+\n+.. index:: ip route NETWORK NETMASK GATEWAY table TABLENO\n+.. clicmd:: ip route NETWORK NETMASK GATEWAY table TABLENO\n+\n+    This command is based on VRF configuration mode. There, this command is only\n+    available with `-n` command. This commands permits configuring a network\n+    route in the given <TABLENO> of the `Linux network namespace` <VRF>.\n+\n+.. index:: ip route NETWORK NETMASK GATEWAY table TABLENO\n+.. clicmd:: ip route NETWORK NETMASK GATEWAY table TABLENO\n+\n+    This command is based on configuration mode. There, for default VRF,\n+    this command is available for all modes. The <TABLENO> configured is one of\n+    the tables from Default `Linux network namespace`.\n+\n+.. index:: show ip route vrf VRF\n+.. clicmd:: show ip route vrf VRF\n+\n+   The show command permits dumping the routing table associated to the VRF.\n+   If zebra is launched with default settings, this will be the TABLENO of the\n+   VRF lite. If zebra is launched with `-n` option, this will be the default routing\n+   table of the `Linux network namespace` <VRF>.","path":"doc/user/zebra.rst","position":142,"original_position":142,"commit_id":"d1bee6e22bdf67bce8609635fef1839947016d13","original_commit_id":"d1bee6e22bdf67bce8609635fef1839947016d13","user":{"login":"pguibert6WIND","id":16295538,"avatar_url":"https://avatars2.githubusercontent.com/u/16295538?v=4","gravatar_id":"","url":"https://api.github.com/users/pguibert6WIND","html_url":"https://github.com/pguibert6WIND","followers_url":"https://api.github.com/users/pguibert6WIND/followers","following_url":"https://api.github.com/users/pguibert6WIND/following{/other_user}","gists_url":"https://api.github.com/users/pguibert6WIND/gists{/gist_id}","starred_url":"https://api.github.com/users/pguibert6WIND/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pguibert6WIND/subscriptions","organizations_url":"https://api.github.com/users/pguibert6WIND/orgs","repos_url":"https://api.github.com/users/pguibert6WIND/repos","events_url":"https://api.github.com/users/pguibert6WIND/events{/privacy}","received_events_url":"https://api.github.com/users/pguibert6WIND/received_events","type":"User","site_admin":false},"body":"ok","created_at":"2018-04-24T16:17:06Z","updated_at":"2018-04-24T16:17:06Z","html_url":"https://github.com/FRRouting/frr/pull/2075#discussion_r183794748","pull_request_url":"https://api.github.com/repos/FRRouting/frr/pulls/2075","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/FRRouting/frr/pulls/comments/183794748"},"html":{"href":"https://github.com/FRRouting/frr/pull/2075#discussion_r183794748"},"pull_request":{"href":"https://api.github.com/repos/FRRouting/frr/pulls/2075"}},"in_reply_to_id":182170536},"pull_request":{"url":"https://api.github.com/repos/FRRouting/frr/pulls/2075","id":182114005,"html_url":"https://github.com/FRRouting/frr/pull/2075","diff_url":"https://github.com/FRRouting/frr/pull/2075.diff","patch_url":"https://github.com/FRRouting/frr/pull/2075.patch","issue_url":"https://api.github.com/repos/FRRouting/frr/issues/2075","number":2075,"state":"open","locked":false,"title":"doc: add information about zebra VRF configuration","user":{"login":"pguibert6WIND","id":16295538,"avatar_url":"https://avatars2.githubusercontent.com/u/16295538?v=4","gravatar_id":"","url":"https://api.github.com/users/pguibert6WIND","html_url":"https://github.com/pguibert6WIND","followers_url":"https://api.github.com/users/pguibert6WIND/followers","following_url":"https://api.github.com/users/pguibert6WIND/following{/other_user}","gists_url":"https://api.github.com/users/pguibert6WIND/gists{/gist_id}","starred_url":"https://api.github.com/users/pguibert6WIND/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pguibert6WIND/subscriptions","organizations_url":"https://api.github.com/users/pguibert6WIND/orgs","repos_url":"https://api.github.com/users/pguibert6WIND/repos","events_url":"https://api.github.com/users/pguibert6WIND/events{/privacy}","received_events_url":"https://api.github.com/users/pguibert6WIND/received_events","type":"User","site_admin":false},"body":"As there are subtle differences between VRF-lite and VRF-netns,\r\nsome information is given to the operator on what can be/ can not be\r\ndone.\r\n\r\nSigned-off-by: Philippe Guibert <philippe.guibert@6wind.com>","created_at":"2018-04-17T10:03:13Z","updated_at":"2018-04-24T16:17:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4ff47f0719804988c9443106aeb66fbb52dead96","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/FRRouting/frr/pulls/2075/commits","review_comments_url":"https://api.github.com/repos/FRRouting/frr/pulls/2075/comments","review_comment_url":"https://api.github.com/repos/FRRouting/frr/pulls/comments{/number}","comments_url":"https://api.github.com/repos/FRRouting/frr/issues/2075/comments","statuses_url":"https://api.github.com/repos/FRRouting/frr/statuses/d1bee6e22bdf67bce8609635fef1839947016d13","head":{"label":"pguibert6WIND:doc_vrf","ref":"doc_vrf","sha":"d1bee6e22bdf67bce8609635fef1839947016d13","user":{"login":"pguibert6WIND","id":16295538,"avatar_url":"https://avatars2.githubusercontent.com/u/16295538?v=4","gravatar_id":"","url":"https://api.github.com/users/pguibert6WIND","html_url":"https://github.com/pguibert6WIND","followers_url":"https://api.github.com/users/pguibert6WIND/followers","following_url":"https://api.github.com/users/pguibert6WIND/following{/other_user}","gists_url":"https://api.github.com/users/pguibert6WIND/gists{/gist_id}","starred_url":"https://api.github.com/users/pguibert6WIND/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pguibert6WIND/subscriptions","organizations_url":"https://api.github.com/users/pguibert6WIND/orgs","repos_url":"https://api.github.com/users/pguibert6WIND/repos","events_url":"https://api.github.com/users/pguibert6WIND/events{/privacy}","received_events_url":"https://api.github.com/users/pguibert6WIND/received_events","type":"User","site_admin":false},"repo":{"id":78088116,"name":"frr","full_name":"pguibert6WIND/frr","owner":{"login":"pguibert6WIND","id":16295538,"avatar_url":"https://avatars2.githubusercontent.com/u/16295538?v=4","gravatar_id":"","url":"https://api.github.com/users/pguibert6WIND","html_url":"https://github.com/pguibert6WIND","followers_url":"https://api.github.com/users/pguibert6WIND/followers","following_url":"https://api.github.com/users/pguibert6WIND/following{/other_user}","gists_url":"https://api.github.com/users/pguibert6WIND/gists{/gist_id}","starred_url":"https://api.github.com/users/pguibert6WIND/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pguibert6WIND/subscriptions","organizations_url":"https://api.github.com/users/pguibert6WIND/orgs","repos_url":"https://api.github.com/users/pguibert6WIND/repos","events_url":"https://api.github.com/users/pguibert6WIND/events{/privacy}","received_events_url":"https://api.github.com/users/pguibert6WIND/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pguibert6WIND/frr","description":"FRR - The FreeRangeRouting Protocol Suite forked from Quagga","fork":true,"url":"https://api.github.com/repos/pguibert6WIND/frr","forks_url":"https://api.github.com/repos/pguibert6WIND/frr/forks","keys_url":"https://api.github.com/repos/pguibert6WIND/frr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pguibert6WIND/frr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pguibert6WIND/frr/teams","hooks_url":"https://api.github.com/repos/pguibert6WIND/frr/hooks","issue_events_url":"https://api.github.com/repos/pguibert6WIND/frr/issues/events{/number}","events_url":"https://api.github.com/repos/pguibert6WIND/frr/events","assignees_url":"https://api.github.com/repos/pguibert6WIND/frr/assignees{/user}","branches_url":"https://api.github.com/repos/pguibert6WIND/frr/branches{/branch}","tags_url":"https://api.github.com/repos/pguibert6WIND/frr/tags","blobs_url":"https://api.github.com/repos/pguibert6WIND/frr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pguibert6WIND/frr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pguibert6WIND/frr/git/refs{/sha}","trees_url":"https://api.github.com/repos/pguibert6WIND/frr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pguibert6WIND/frr/statuses/{sha}","languages_url":"https://api.github.com/repos/pguibert6WIND/frr/languages","stargazers_url":"https://api.github.com/repos/pguibert6WIND/frr/stargazers","contributors_url":"https://api.github.com/repos/pguibert6WIND/frr/contributors","subscribers_url":"https://api.github.com/repos/pguibert6WIND/frr/subscribers","subscription_url":"https://api.github.com/repos/pguibert6WIND/frr/subscription","commits_url":"https://api.github.com/repos/pguibert6WIND/frr/commits{/sha}","git_commits_url":"https://api.github.com/repos/pguibert6WIND/frr/git/commits{/sha}","comments_url":"https://api.github.com/repos/pguibert6WIND/frr/comments{/number}","issue_comment_url":"https://api.github.com/repos/pguibert6WIND/frr/issues/comments{/number}","contents_url":"https://api.github.com/repos/pguibert6WIND/frr/contents/{+path}","compare_url":"https://api.github.com/repos/pguibert6WIND/frr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pguibert6WIND/frr/merges","archive_url":"https://api.github.com/repos/pguibert6WIND/frr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pguibert6WIND/frr/downloads","issues_url":"https://api.github.com/repos/pguibert6WIND/frr/issues{/number}","pulls_url":"https://api.github.com/repos/pguibert6WIND/frr/pulls{/number}","milestones_url":"https://api.github.com/repos/pguibert6WIND/frr/milestones{/number}","notifications_url":"https://api.github.com/repos/pguibert6WIND/frr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pguibert6WIND/frr/labels{/name}","releases_url":"https://api.github.com/repos/pguibert6WIND/frr/releases{/id}","deployments_url":"https://api.github.com/repos/pguibert6WIND/frr/deployments","created_at":"2017-01-05T06:56:15Z","updated_at":"2017-01-05T06:56:22Z","pushed_at":"2018-04-24T14:45:38Z","git_url":"git://github.com/pguibert6WIND/frr.git","ssh_url":"git@github.com:pguibert6WIND/frr.git","clone_url":"https://github.com/pguibert6WIND/frr.git","svn_url":"https://github.com/pguibert6WIND/frr","homepage":"","size":38980,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"FRRouting:master","ref":"master","sha":"673c2b79b732f6b9a3d6376baa32f21928890ed6","user":{"login":"FRRouting","id":24592672,"avatar_url":"https://avatars1.githubusercontent.com/u/24592672?v=4","gravatar_id":"","url":"https://api.github.com/users/FRRouting","html_url":"https://github.com/FRRouting","followers_url":"https://api.github.com/users/FRRouting/followers","following_url":"https://api.github.com/users/FRRouting/following{/other_user}","gists_url":"https://api.github.com/users/FRRouting/gists{/gist_id}","starred_url":"https://api.github.com/users/FRRouting/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FRRouting/subscriptions","organizations_url":"https://api.github.com/users/FRRouting/orgs","repos_url":"https://api.github.com/users/FRRouting/repos","events_url":"https://api.github.com/users/FRRouting/events{/privacy}","received_events_url":"https://api.github.com/users/FRRouting/received_events","type":"Organization","site_admin":false},"repo":{"id":76599439,"name":"frr","full_name":"FRRouting/frr","owner":{"login":"FRRouting","id":24592672,"avatar_url":"https://avatars1.githubusercontent.com/u/24592672?v=4","gravatar_id":"","url":"https://api.github.com/users/FRRouting","html_url":"https://github.com/FRRouting","followers_url":"https://api.github.com/users/FRRouting/followers","following_url":"https://api.github.com/users/FRRouting/following{/other_user}","gists_url":"https://api.github.com/users/FRRouting/gists{/gist_id}","starred_url":"https://api.github.com/users/FRRouting/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FRRouting/subscriptions","organizations_url":"https://api.github.com/users/FRRouting/orgs","repos_url":"https://api.github.com/users/FRRouting/repos","events_url":"https://api.github.com/users/FRRouting/events{/privacy}","received_events_url":"https://api.github.com/users/FRRouting/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/FRRouting/frr","description":"The FRRouting Protocol Suite","fork":false,"url":"https://api.github.com/repos/FRRouting/frr","forks_url":"https://api.github.com/repos/FRRouting/frr/forks","keys_url":"https://api.github.com/repos/FRRouting/frr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/FRRouting/frr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/FRRouting/frr/teams","hooks_url":"https://api.github.com/repos/FRRouting/frr/hooks","issue_events_url":"https://api.github.com/repos/FRRouting/frr/issues/events{/number}","events_url":"https://api.github.com/repos/FRRouting/frr/events","assignees_url":"https://api.github.com/repos/FRRouting/frr/assignees{/user}","branches_url":"https://api.github.com/repos/FRRouting/frr/branches{/branch}","tags_url":"https://api.github.com/repos/FRRouting/frr/tags","blobs_url":"https://api.github.com/repos/FRRouting/frr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/FRRouting/frr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/FRRouting/frr/git/refs{/sha}","trees_url":"https://api.github.com/repos/FRRouting/frr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/FRRouting/frr/statuses/{sha}","languages_url":"https://api.github.com/repos/FRRouting/frr/languages","stargazers_url":"https://api.github.com/repos/FRRouting/frr/stargazers","contributors_url":"https://api.github.com/repos/FRRouting/frr/contributors","subscribers_url":"https://api.github.com/repos/FRRouting/frr/subscribers","subscription_url":"https://api.github.com/repos/FRRouting/frr/subscription","commits_url":"https://api.github.com/repos/FRRouting/frr/commits{/sha}","git_commits_url":"https://api.github.com/repos/FRRouting/frr/git/commits{/sha}","comments_url":"https://api.github.com/repos/FRRouting/frr/comments{/number}","issue_comment_url":"https://api.github.com/repos/FRRouting/frr/issues/comments{/number}","contents_url":"https://api.github.com/repos/FRRouting/frr/contents/{+path}","compare_url":"https://api.github.com/repos/FRRouting/frr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/FRRouting/frr/merges","archive_url":"https://api.github.com/repos/FRRouting/frr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/FRRouting/frr/downloads","issues_url":"https://api.github.com/repos/FRRouting/frr/issues{/number}","pulls_url":"https://api.github.com/repos/FRRouting/frr/pulls{/number}","milestones_url":"https://api.github.com/repos/FRRouting/frr/milestones{/number}","notifications_url":"https://api.github.com/repos/FRRouting/frr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/FRRouting/frr/labels{/name}","releases_url":"https://api.github.com/repos/FRRouting/frr/releases{/id}","deployments_url":"https://api.github.com/repos/FRRouting/frr/deployments","created_at":"2016-12-15T21:56:38Z","updated_at":"2018-04-24T15:53:25Z","pushed_at":"2018-04-24T15:53:21Z","git_url":"git://github.com/FRRouting/frr.git","ssh_url":"git@github.com:FRRouting/frr.git","clone_url":"https://github.com/FRRouting/frr.git","svn_url":"https://github.com/FRRouting/frr","homepage":"https://frrouting.org/","size":38559,"stargazers_count":488,"watchers_count":488,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":191,"mirror_url":null,"archived":false,"open_issues_count":190,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":191,"open_issues":190,"watchers":488,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/FRRouting/frr/pulls/2075"},"html":{"href":"https://github.com/FRRouting/frr/pull/2075"},"issue":{"href":"https://api.github.com/repos/FRRouting/frr/issues/2075"},"comments":{"href":"https://api.github.com/repos/FRRouting/frr/issues/2075/comments"},"review_comments":{"href":"https://api.github.com/repos/FRRouting/frr/pulls/2075/comments"},"review_comment":{"href":"https://api.github.com/repos/FRRouting/frr/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/FRRouting/frr/pulls/2075/commits"},"statuses":{"href":"https://api.github.com/repos/FRRouting/frr/statuses/d1bee6e22bdf67bce8609635fef1839947016d13"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"pguibert6WIND"}}