Guest User

Untitled

a guest
Sep 5th, 2026
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.92 KB | None | 0 0
  1. vyos@master# run sh configuration
  2. interfaces {
  3. ethernet eth0 {
  4. hw-id 50:e2:9f:00:10:00
  5. vif 100 {
  6. address 192.168.45.254/24
  7. vrf vlan100
  8. }
  9. vif 200 {
  10. address 192.168.45.254/24
  11. vrf vlan200
  12. }
  13. }
  14. ethernet eth1 {
  15. address 192.168.1.5/24
  16. address 192.168.1.6/24
  17. hw-id 50:e2:9f:00:10:01
  18. }
  19. ethernet eth2 {
  20. hw-id 50:e2:9f:00:10:02
  21. }
  22. ethernet eth3 {
  23. hw-id 50:e2:9f:00:10:03
  24. }
  25. loopback lo {
  26. }
  27. }
  28. nat {
  29. source {
  30. rule 10 {
  31. outbound-interface {
  32. name eth1
  33. }
  34. source {
  35. address 192.168.45.0/24
  36. }
  37. translation {
  38. address 192.168.1.5
  39. }
  40. }
  41. }
  42. }
  43. policy {
  44. route PBR {
  45. interface eth1
  46. rule 100 {
  47. description "192.168.1.5 to vrf/valn100"
  48. destination {
  49. address 192.168.1.5
  50. }
  51. set {
  52. vrf vlan100
  53. }
  54. }
  55. }
  56. }
  57. protocols {
  58. static {
  59. }
  60. }
  61. service {
  62. ntp {
  63. allow-client {
  64. address 127.0.0.0/8
  65. address 169.254.0.0/16
  66. address 10.0.0.0/8
  67. address 172.16.0.0/12
  68. address 192.168.0.0/16
  69. address ::1/128
  70. address fe80::/10
  71. address fc00::/7
  72. }
  73. server time1.vyos.net {
  74. }
  75. server time2.vyos.net {
  76. }
  77. server time3.vyos.net {
  78. }
  79. }
  80. ssh {
  81. }
  82. }
  83. system {
  84. config-management {
  85. commit-revisions 100
  86. }
  87. console {
  88. device ttyS0 {
  89. speed 115200
  90. }
  91. }
  92. host-name master
  93. login {
  94. operator-group default {
  95. command-policy {
  96. allow "*"
  97. }
  98. }
  99. user vyos {
  100. authentication {
  101. encrypted-password ****************
  102. plaintext-password ****************
  103. }
  104. }
  105. }
  106. option {
  107. reboot-on-upgrade-failure 5
  108. }
  109. syslog {
  110. local {
  111. facility all {
  112. level info
  113. }
  114. facility local7 {
  115. level debug
  116. }
  117. }
  118. }
  119. }
  120. vrf {
  121. name vlan100 {
  122. protocols {
  123. static {
  124. route 0.0.0.0/0 {
  125. next-hop 192.168.1.254 {
  126. vrf default
  127. }
  128. }
  129. }
  130. }
  131. table 100
  132. }
  133. name vlan200 {
  134. protocols {
  135. static {
  136. route 0.0.0.0/0 {
  137. next-hop 192.168.1.254 {
  138. vrf default
  139. }
  140. }
  141. }
  142. }
  143. table 200
  144. }
  145. }
  146. [edit]
Advertisement
Add Comment
Please, Sign In to add comment