OpenStack的网络及简单操作
OpenStack的网络及简单操作 OpenStack的网络主要有两类,内部网络和外部网络;再细分内部网络包括管理网络和虚拟机之间的数据网络,外部网络包括互联internet网络和API管控网络。其中:管理网络主要是来管理OpenStack中各个组件的,在安装部署时,很多配置文件项相关的网络IP就属于管理网络范畴;数据网络主要用于虚拟机之间的通信,虚拟网络划分,Netwo
-
Management network. Used for internal communication between OpenStack components.
The IP addresses on this network should be reachable only within the data center. -
Data network. Used for VM data communication within the cloud deployment.
The IP addressing requirements of this network depend on the OpenStack Networking plugin in use. -
External network. Provides VMs with Internet access in some deployment scenarios.
The IP addresses on this network should be reachable by anyone on the Internet. -
API network. Exposes all OpenStack APIs, including the OpenStack Networking API, to tenants.
The IP addresses on this network should be reachable by anyone on the Internet. This may be the same network as the external network, as it is possible to create a quantum subnet for the external network that uses IP allocation ranges to use only less than the full range of IP addresses in an IP block.
# Obtain the VM's fixed IP
nova --os-tenant-name TenantA --os-username UserA --os-password password--os-auth-url=http://localhost:5000/v2.0 list
# You can find its fixed IP in the "Networks" section: TenantA-Net={fixed IP}.
# Obtain the virtual port ID from the fixed IP quantum --os-tenant-name TenantA --os-usernameUserA --os-password password--os-auth-url=http://localhost:5000/v2.0 port-list | grep "{fixed IP}"
# The first column shows the virtual port ID.# Create a floating IP
quantum --os-tenant-name TenantA --os-username UserA --os-password password--os-auth-url=http://localhost:5000/v2.0 floatingip-create Ext-Net
# Associate the created floating IP to the VM's virtual port
quantum --os-tenant-name TenantA --os-username UserA --os-password password--os-auth-url=http://localhost:5000/v2.0 floatingip-associate {floating IP ID} {virtual port ID}
# Check your VM status
nova --os-tenant-name TenantA --os-username UserA --os-password password--os-auth-url=http://localhost:5000/v2.0 list
# SSH to your VM when your VM is ACTIVE # The password is cubswin:)
ssh xxx@{floating_ip}
更多推荐
所有评论(0)