Openstack 启动一个实例(九)
Openstack 启动一个实例(九)
创建一个提供者网络:
# 创建一个提供者网络: openstack network create --share --external --provider-physical-network linux36 --provider-network-type flat linux36 --external # 声明是一个外部网络 --provider-physical-network linux36 # 自定义的网络名, ```/etc/neutron/plugins/ml2/ml2_conf.ini``` 中,flat_networks = linux36定义. --provider-network-type flat linux36 # flat 单一扁平网络(就是桥接). [ ~]# source admin.sh ~]# openstack network create --share --external --provider-physical-network linux36 --provider-network-type flat linux36 +---------------------------+--------------------------------------+ | Field | Value | +---------------------------+--------------------------------------+ | admin_state_up | UP | | availability_zone_hints | | | availability_zones | | | created_at | 2020-05-31T11:09:34Z | | description | | | dns_domain | None | | id | 8bcf8753-71da-48eb-a2e8-22438d6b95ca | | ipv4_address_scope | None | | ipv6_address_scope | None | | is_default | None | | mtu | 1500 | | name | linux36 | | port_security_enabled | True | | project_id | 7895c74b24e640498acb869a790f7092 | | provider:network_type | flat | | provider:physical_network | linux36 | | provider:segmentation_id | None | | qos_policy_id | None | | revision_number | 4 | | router:external | External | | segments | None | | shared | True | | status | ACTIVE | | subnets | | | updated_at | 2020-05-31T11:09:34Z | +---------------------------+--------------------------------------+ # 创建一个子网: openstack subnet create --network linux36 --allocation-pool start=10.10.5.50,end=10.10.5.100 --dns-nameserver 10.10.5.1 --gateway 10.10.5.1 --subnet-range 10.10.5.0/24 linux36 [ ~]# openstack subnet create --network linux36 > --allocation-pool start=10.10.5.50,end=10.10.5.100 > --dns-nameserver 10.10.5.1 --gateway 10.10.5.1 > --subnet-range 10.10.5.0/24 linux36 +-------------------+--------------------------------------+ | Field | Value | +-------------------+--------------------------------------+ | allocation_pools | 10.10.5.50-10.10.5.100 | | cidr | 10.10.5.0/24 | | created_at | 2020-05-31T12:16:48Z | | description | | | dns_nameservers | 10.10.5.1 | | enable_dhcp | True | | gateway_ip | 10.10.5.1 | | host_routes | | | id | ecae924f-1a23-4b40-b32e-49f06dcfd2b9 | | ip_version | 4 | | ipv6_address_mode | None | | ipv6_ra_mode | None | | name | linux36 | | network_id | 8bcf8753-71da-48eb-a2e8-22438d6b95ca | | project_id | 7895c74b24e640498acb869a790f7092 | | revision_number | 2 | | segment_id | None | | service_types | | | subnetpool_id | None | | updated_at | 2020-05-31T12:16:48Z | +-------------------+--------------------------------------+
创建m1.nano类型
# openstack flavor create --id 0 --vcpus 1 --ram 64 --disk 1 m1.nano [ ~]# openstack flavor create --id 0 --vcpus 1 --ram 64 --disk 1 m1.nano +----------------------------+---------+ | Field | Value | +----------------------------+---------+ | OS-FLV-DISABLED:disabled | False | | OS-FLV-EXT-DATA:ephemeral | 0 | | disk | 1 | | id | 0 | | name | m1.nano | | os-flavor-access:is_public | True | | properties | | | ram | 64 | | rxtx_factor | 1.0 | | swap | | | vcpus | 1 | +----------------------------+---------+
生成一个键值对(不是必须的)
相关推荐
Moolightshadow 2020-07-16
fyggzb 2020-07-05
gokeibi 2020-06-12
zziyuann 2020-06-12
fyggzb 2020-06-12
hhphhp 2020-06-12
fyggzb 2020-06-10
JeremyLiu 2020-06-10
JeremyLiu 2020-06-10
jmppok 2020-06-07
jmppok 2020-06-05
zziyuann 2020-05-17
gokeibi 2020-05-07
gokeibi 2020-04-26
gokeibi 2020-04-19
gokeibi 2020-04-19
嗯 2020-04-17