Quantcast
Channel: VMware Communities : Blog List - All Communities
Viewing all articles
Browse latest Browse all 3135

Set Manual Routing for VCSA

$
0
0

Although we want to to manage all of our deployed hosts inside a single subnet or VLAN, maybe in some situations there need to place many of hypervisor on other subnets / VLANs. So if there is a way for routing the vCenter traffic from it's gateway to them, there is no problem. Only the requirement traffics for initial management (incoming TCP 443 / both side TCP 902 / outgoing UDP 902) must be permitted within your gateway / router / firewall. But if it's not possible to do that because of some management or security considerations, so you can input all of the required routes inside the vCenter Server Shell. There is two ways to do that. One method is using "route add" command on shell access. For example:

# route add -net 10.10.10.0 netmask 255.255.255.0 gw 10.10.100.1 dev eth0 

Result of this method is not persistent and will be clean after VCSA restart, Then it's useful only for testing or temporary situations. But if you want to save it, the Second way is editing of file *.network (such as 10-eth0.network) in and path "/etc/systemd/network" add intended routes in this form:

[Routes]

Destination=10.10.20.0/24

Gateway=10.10.100.2

 

Remember to add each route line in separated [Routes] brackets, otherwise it's not working as you expected. Then restart the network interface:

# ifdown eth0 | ifup eth0

 

or restart the networkd with these commands:

# systemctl restart systemd-networkd

# service network restart

 

And now if you want to check the results, run:

# route -n

# ip route show

 

Without shell access if you only login to VCSA console, there is many CLI for routing check and config, so you can use of these.

To check them and how to use:

 

> routes.list --help

> routes.add --help

> routes.delete --help

> routes.test --help

 

Note I: There is another file here: "/etc/sysconfig/network/routes", if you view it's content, it will show only the system default gateway,

no more routes will be shown here.

Note II: If you want to add routing to your ESXi hosts, just do:

# esxcli network ip route ipv4 add -n 10.10.20.0/24 -g 10.10.100.2

 

Source of Content inside my personal blog:Undercity of Virtualization: Set Manual Routing for VCSA


Viewing all articles
Browse latest Browse all 3135

Trending Articles