- OpenStack Networking Essentials
- James Denton
- 579字
- 2021-07-09 19:39:29
The initial network configuration
To understand how networking within the all-in-one virtual machine node hosting OpenStack will work, refer to the following diagram:

In the preceding diagram, three virtual interfaces are cabled to the All-In-One Node. The eth0
interface will serve as the management interface for OpenStack services and API access while eth1
will be used for interfacing with virtual machine instances over Neutron networks, including using floating IPs. The eth2
interface will serve as the gateway interface for Internet access from the All-In-One Node and will not be utilized by OpenStack itself. By configuring host-only networks within VirtualBox and associating them with the All-In-One Node, you will be able to interface with the OpenStack API, dashboard, and certain Neutron networks from your workstation.
For instructions on how to configure VirtualBox to support the aforementioned networking configuration, refer to Appendix, Configuring VirtualBox.
Example networks
Throughout the book, there will be examples of configuring and using various OpenStack services. The following table provides the networks used for those services:

Interface configuration
CentOS uses a configuration file for each inpidual network interface. These files can be found in the /etc/sysconfig/network-scripts
directory. Interface names may vary between systems, depending on the operating system version, the underlying hardware, and the type of network interface used. Within my VirtualBox instance, the following interface mappings can be observed:

Using a text editor, update the network interface files on your host as follows:
- Management interface (
ifcfg-enp0s3
):TYPE=Ethernet BOOTPROTO=none DEFROUTE=no IPV4_FAILURE_FATAL=no IPV6INIT=no NAME=enp0s3 DEVICE=enp0s3 ONBOOT=yes IPADDR=10.254.254.100 PREFIX=24
- Gateway interface (
ifcfg-enp0s9
):TYPE=Ethernet BOOTPROTO=dhcp DEFROUTE=yes IPV4_FAILURE_FATAL=no IPV6INIT=no NAME=enp0s9 DEVICE=enp0s9 ONBOOT=yes
Tip
You can download the example code files for this book from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.
You can download the code files by following these steps:
- Log in or register to our website using your e-mail address and password.
- Hover the mouse pointer on the SUPPORT tab at the top.
- Click on Code Downloads & Errata.
- Enter the name of the book in the Search box.
- Select the book for which you're looking to download the code files.
- Choose from the drop-down menu where you purchased this book from.
- Click on Code Download.
Once the file is downloaded, please make sure that you unzip or extract the folder using the latest version of:
- WinRAR / 7-Zip for Windows
- Zipeg / iZip / UnRarX for Mac
- 7-Zip / PeaZip for Linux
The enp0s8
interface will be connected to a network bridge and used for VM traffic and will be configured automatically during the installation of OpenStack. Packstack should automatically configure the interface and connect it to the bridge, which means you do not need to configure the file beforehand.
To activate the changes, cycle the interfaces using the following ifdown
and ifup
commands from the virtual machine console:
$ sudo ifdown enp0s3; sudo ifdown enp0s9; $ sudo ifup enp0s3; sudo ifup enp0s9;
Connect to the host
From your workstation, connect to the host using the management address configured on the eth0
(enp0s3
) interface, as shown in the following screenshot:

The host will utilize the DHCP interface as its default gateway interface, allowing it to access the Internet using the NAT established by VirtualBox. The management interface will be used to interact with the host using SSH as well as the OpenStack API and the Horizon dashboard. Once connected, proceed with installing OpenStack using the procedure outlined in the following sections.
- 數據科學實戰手冊(R+Python)
- PHP 編程從入門到實踐
- JavaScript動態網頁開發詳解
- 程序員修煉之道:通向務實的最高境界(第2版)
- R大數據分析實用指南
- Oracle 18c 必須掌握的新特性:管理與實戰
- Java系統化項目開發教程
- MySQL從入門到精通(軟件開發視頻大講堂)
- Visual Foxpro 9.0數據庫程序設計教程
- Scala編程(第5版)
- Maker基地嘉年華:玩轉樂動魔盒學Scratch
- Flask Web開發:基于Python的Web應用開發實戰(第2版)
- JavaScript設計模式與開發實踐
- Build Your Own PaaS with Docker
- LibGDX Game Development By Example