Creating a flat network in the CLI

If you recall from previous chapters, a flat network is a network in which no 802.1q tagging takes place.

The syntax to create a flat network can be seen here:

openstack network create
--provider-network-type flat
--provider-physical-network <provider-physical-network>
<name>

The following is an example of using the OpenStack client to create a flat network by the name of MyFlatNetwork. The network will utilize an interface or bridge represented by the label physnet1 and will be shared among all projects:

In the preceding output, the project ID corresponds to the admin project where the user who executed the network create command was scoped. Since the network is shared, all projects can create instances and network resources that utilize the MyFlatNetwork network.

Attempting to create an additional flat network using the same provider-physical-network name of physnet1 will result in an error, as shown in the following screenshot:

Because there is only one untagged or native VLAN available on the interface, Neutron cannot create a second flat network and returns a Conflict error. Given this limitation, flat networks are rarely utilized in favor of VLAN networks.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset