Monday, May 1, 2017

Switching to newly created project's private network running CentOS 7.3 Cloud VMs on RDO Ocata.

Topology been deployed into overcloud originally via Tripleo QuickStart(branch Ocata)
[stack@undercloud ~]$ openstack server list
+-------------------------+-------------------------+--------+------------------------+----------------+
| ID                      | Name                    | Status | Networks               | Image Name     |
+-------------------------+-------------------------+--------+------------------------+----------------+
| ec0c56ac-f723-487b-     | overcloud-controller-0  | ACTIVE | ctlplane=192.168.24.10 | overcloud-full |
| 945c-3d27d404e794       |                         |        |                        |                |
| 8c91b724-7bee-          | overcloud-controller-2  | ACTIVE | ctlplane=192.168.24.7  | overcloud-full |
| 4e09-b4f7-5abe3e8ea6b8  |                         |        |                        |                |
| 528c7776-18d3-4f06-8dd6 | overcloud-controller-1  | ACTIVE | ctlplane=192.168.24.11 | overcloud-full |
| -56b6e0c64921           |                         |        |                        |                |
| 0477d12b-5f2a-4366-be34 | overcloud-cephstorage-0 | ACTIVE | ctlplane=192.168.24.14 | overcloud-full |
| -1ca1b3cccc8c           |                         |        |                        |                |
| df77e3f2-4345-4f88      | overcloud-novacompute-0 | ACTIVE | ctlplane=192.168.24.12 | overcloud-full |
| -98cd-6622d57efe59      |                         |        |                        |                |
+-------------------------+-------------------------+--------+------------------------+----------------+

[stack@undercloud ~]$ ssh heat-admin@192.168.24.10
The authenticity of host '192.168.24.10 (192.168.24.10)' can't be established.
ECDSA key fingerprint is c7:8a:13:09:60:ff:bb:d9:76:5c:50:40:4e:98:2f:1f.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.24.10' (ECDSA) to the list of known hosts.
[heat-admin@overcloud-controller-0 ~]$ sudo su -
[root@overcloud-controller-0 ~]# vi overcloudrc.v3
[root@overcloud-controller-0 ~]# .  overcloudrc.v3
[root@overcloud-controller-0 ~]# pcs status
Cluster name: tripleo_cluster
Stack: corosync
Current DC: overcloud-controller-0 (version 1.1.15-11.el7_3.4-e174ec8) - partition with quorum
Last updated: Mon May  1 13:52:33 2017        Last change: Mon May  1 13:44:06 2017 by root via cibadmin on overcloud-controller-0

3 nodes and 19 resources configured

Online: [ overcloud-controller-0 overcloud-controller-1 overcloud-controller-2 ]

Full list of resources:

 Master/Slave Set: galera-master [galera]
     Masters: [ overcloud-controller-0 overcloud-controller-1 overcloud-controller-2 ]
 Clone Set: rabbitmq-clone [rabbitmq]
     Started: [ overcloud-controller-0 overcloud-controller-1 overcloud-controller-2 ]
 Master/Slave Set: redis-master [redis]
     Masters: [ overcloud-controller-1 ]
     Slaves: [ overcloud-controller-0 overcloud-controller-2 ]
 ip-192.168.24.8    (ocf::heartbeat:IPaddr2):    Started overcloud-controller-0
 ip-10.0.0.9    (ocf::heartbeat:IPaddr2):    Started overcloud-controller-1
 ip-172.16.2.9    (ocf::heartbeat:IPaddr2):    Started overcloud-controller-2
 ip-172.16.2.10    (ocf::heartbeat:IPaddr2):    Started overcloud-controller-0
 ip-172.16.1.4    (ocf::heartbeat:IPaddr2):    Started overcloud-controller-1
 ip-172.16.3.12    (ocf::heartbeat:IPaddr2):    Started overcloud-controller-2
 Clone Set: haproxy-clone [haproxy]
     Started: [ overcloud-controller-0 overcloud-controller-1 overcloud-controller-2 ]
 openstack-cinder-volume    (systemd:openstack-cinder-volume):    Started overcloud-controller-0

Daemon Status:
  corosync: active/enabled
  pacemaker: active/enabled
  pcsd: active/enabled
[root@overcloud-controller-0 ~]# ceph status
    cluster dcc39abc-2e69-11e7-ae4b-006843a37fdc
     health HEALTH_OK
     monmap e1: 3 mons at {overcloud-controller-0=172.16.1.7:6789/0,overcloud-controller-1=172.16.1.8:6789/0,overcloud-controller-2=172.16.1.10:6789/0}
            election epoch 8, quorum 0,1,2 overcloud-controller-0,overcloud-controller-1,overcloud-controller-2
     osdmap e18: 1 osds: 1 up, 1 in
            flags sortbitwise
      pgmap v95: 288 pgs, 8 pools, 3171 bytes data, 19 objects
            8343 MB used, 42844 MB / 51187 MB avail
                 288 active+clean
  client io 900 B/s rd, 737 B/s wr, 0 op/s rd, 1 op/s wr
[root@overcloud-controller-0 ~]# yum install wget -y
Loaded plugins: fastestmirror, priorities
base                                                                      | 3.6 kB  00:00:00     
centos-ceph-jewel                                                         | 2.9 kB  00:00:00     
delorean                                                                  | 3.0 kB  00:00:00     
delorean-ocata-testing                                                    | 2.9 kB  00:00:00     
extras                                                                    | 3.4 kB  00:00:00     
rdo-qemu-ev                                                               | 2.9 kB  00:00:00     
updates                                                                   | 3.4 kB  00:00:00     
Loading mirror speeds from cached hostfile
 * base: mirror.corbina.net
 * extras: mirror.corbina.net
 * updates: mirror.corbina.net
884 packages excluded due to repository priority protections
Resolving Dependencies
--> Running transaction check
---> Package wget.x86_64 0:1.14-13.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

=================================================================================================
 Package             Arch                  Version                     Repository           Size
=================================================================================================
Installing:
 wget                x86_64                1.14-13.el7                 base                546 k

Transaction Summary
=================================================================================================
Install  1 Package

Total download size: 546 k
Installed size: 2.0 M
Downloading packages:
wget-1.14-13.el7.x86_64.rpm                                               | 546 kB  00:00:00     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : wget-1.14-13.el7.x86_64                                                       1/1 
  Verifying  : wget-1.14-13.el7.x86_64                                                       1/1 

Installed:
  wget.x86_64 0:1.14-13.el7                                                                      

Complete!
[root@overcloud-controller-0 ~]# wget https://cloud.centos.org/centos/7/images/CentOS-7-x86_64-GenericCloud-1703.qcow2.xz
--2017-05-01 13:54:40--  https://cloud.centos.org/centos/7/images/CentOS-7-x86_64-GenericCloud-1703.qcow2.xz
Resolving cloud.centos.org (cloud.centos.org)... 38.110.33.4, 2a01:4f8:212:29d0::1
Connecting to cloud.centos.org (cloud.centos.org)|38.110.33.4|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 483780468 (461M) [application/x-xz]
Saving to: ‘CentOS-7-x86_64-GenericCloud-1703.qcow2.xz’

100%[=======================================================>] 483,780,468 2.06MB/s   in 4m 30s 

2017-05-01 13:59:11 (1.71 MB/s) - ‘CentOS-7-x86_64-GenericCloud-1703.qcow2.xz’ saved [483780468/483780468]


[root@overcloud-controller-0 ~]# openstack image create --disk-format qcow2 --container-format bare \
>  --public --file ./CentOS-7-x86_64-GenericCloud-1703.qcow2 CentOS7Cloud-image
+------------------+----------------------------------------------------------------------------+
| Field            | Value                                                                      |
+------------------+----------------------------------------------------------------------------+
| checksum         | 6ed1a82e655cba7f911fcb5c9bc5dbfa                                           |
| container_format | bare                                                                       |
| created_at       | 2017-05-01T14:01:21Z                                                       |
| disk_format      | qcow2                                                                      |
| file             | /v2/images/f8384a15-364e-4c57-845f-f5e33b6d890c/file                       |
| id               | f8384a15-364e-4c57-845f-f5e33b6d890c                                       |
| min_disk         | 0                                                                          |
| min_ram          | 0                                                                          |
| name             | CentOS7Cloud-image                                                         |
| owner            | 02d4b231650e4622bce9496f4463c1a6                                           |
| properties       | direct_url='rbd://dcc39abc-2e69-11e7-ae4b-006843a37fdc/images/f8384a15     |
|                  | -364e-4c57-845f-f5e33b6d890c/snap', locations='[{u'url': u'rbd://dcc39abc- |
|                  | 2e69-11e7-ae4b-006843a37fdc/images/f8384a15-364e-4c57-845f-                |
|                  | f5e33b6d890c/snap', u'metadata': {}}]'                                     |
| protected        | False                                                                      |
| schema           | /v2/schemas/image                                                          |
| size             | 1391329280                                                                 |
| status           | active                                                                     |
| tags             |                                                                            |
| updated_at       | 2017-05-01T14:02:11Z                                                       |
| virtual_size     | None                                                                       |
| visibility       | public                                                                     |
+------------------+----------------------------------------------------------------------------+

[root@overcloud-controller-0 ~]# openstack image list
+--------------------------------------+--------------------+--------+
| ID                                   | Name               | Status |
+--------------------------------------+--------------------+--------+
| f8384a15-364e-4c57-845f-f5e33b6d890c | CentOS7Cloud-image | active |
+--------------------------------------+--------------------+--------+

[root@overcloud-controller-0 ~]# openstack image list
+--------------------------------------+--------------------+--------+
| ID                                   | Name               | Status |
+--------------------------------------+--------------------+--------+
| f8384a15-364e-4c57-845f-f5e33b6d890c | CentOS7Cloud-image | active |
+--------------------------------------+--------------------+--------+

[root@overcloud-controller-0 ~]# openstack volume create --image f8384a15-364e-4c57-845f-f5e33b6d890c \
>    --size 12 --availability-zone nova CentOS73Volume
+---------------------+--------------------------------------+
| Field               | Value                                |
+---------------------+--------------------------------------+
| attachments         | []                                   |
| availability_zone   | nova                                 |
| bootable            | false                                |
| consistencygroup_id | None                                 |
| created_at          | 2017-05-01T14:05:11.926450           |
| description         | None                                 |
| encrypted           | False                                |
| id                  | 2cbba66d-6ddc-46bd-9a76-400963d95fb3 |
| migration_status    | None                                 |
| multiattach         | False                                |
| name                | CentOS73Volume                       |
| properties          |                                      |
| replication_status  | None                                 |
| size                | 12                                   |
| snapshot_id         | None                                 |
| source_volid        | None                                 |
| status              | creating                             |
| type                | None                                 |
| updated_at          | None                                 |
| user_id             | 9132014f44c341c8a93f1a67de2ec85d     |
+---------------------+--------------------------------------+

[root@overcloud-controller-0 ~]# cinder list
+--------------------------------------+-------------+----------------+------+-------------+----------+-------------+
| ID                                   | Status      | Name           | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-------------+----------------+------+-------------+----------+-------------+
| 2cbba66d-6ddc-46bd-9a76-400963d95fb3 | downloading | CentOS73Volume | 12   | -           | false    |             |
+--------------------------------------+-------------+----------------+------+-------------+----------+-------------+

[root@overcloud-controller-0 ~]# cinder list
+--------------------------------------+-----------+----------------+------+-------------+----------+-------------+
| ID                                   | Status    | Name           | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-----------+----------------+------+-------------+----------+-------------+
| 2cbba66d-6ddc-46bd-9a76-400963d95fb3 | available | CentOS73Volume | 12   | -           | true     |             |
+--------------------------------------+-----------+----------------+------+-------------+----------+-------------+

[root@overcloud-controller-0 ~]# openstack flavor create --public m1.small --id 2 \
>   --ram 2000 --disk 20 --vcpus 1 --rxtx-factor 1
+----------------------------+----------+
| Field                      | Value    |
+----------------------------+----------+
| OS-FLV-DISABLED:disabled   | False    |
| OS-FLV-EXT-DATA:ephemeral  | 0        |
| disk                       | 20       |
| id                         | 2        |
| name                       | m1.small |
| os-flavor-access:is_public | True     |
| properties                 |          |
| ram                        | 2000     |
| rxtx_factor                | 1.0      |
| swap                       |          |
| vcpus                      | 1        |
+----------------------------+----------+
[root@overcloud-controller-0 ~]# openstack keypair create oskey050117 > oskey050117.pem

[root@overcloud-controller-0 ~]# openstack  network create ext-net --external \
> --provider-physical-network datacentre  --provider-network-type flat
+---------------------------+--------------------------------------+
| Field                     | Value                                |
+---------------------------+--------------------------------------+
| admin_state_up            | UP                                   |
| availability_zone_hints   |                                      |
| availability_zones        |                                      |
| created_at                | 2017-05-01T14:13:23Z                 |
| description               |                                      |
| dns_domain                | None                                 |
| id                        | 7885b879-39ee-478b-b2fa-19c2c2fe9e39 |
| ipv4_address_scope        | None                                 |
| ipv6_address_scope        | None                                 |
| is_default                | False                                |
| mtu                       | 1500                                 |
| name                      | ext-net                              |
| port_security_enabled     | True                                 |
| project_id                | 02d4b231650e4622bce9496f4463c1a6     |
| provider:network_type     | flat                                 |
| provider:physical_network | datacentre                           |
| provider:segmentation_id  | None                                 |
| qos_policy_id             | None                                 |
| revision_number           | 4                                    |
| router:external           | External                             |
| segments                  | None                                 |
| shared                    | False                                |
| status                    | ACTIVE                               |
| subnets                   |                                      |
| updated_at                | 2017-05-01T14:13:24Z                 |
+---------------------------+--------------------------------------+

[root@overcloud-controller-0 ~]#  openstack subnet create ext-subnet --network ext-net \
>  --subnet-range 192.168.24.0/24  --allocation-pool start=192.168.24.100,end=192.168.24.120 \
>  --no-dhcp --gateway 192.168.24.1
+-------------------+--------------------------------------+
| Field             | Value                                |
+-------------------+--------------------------------------+
| allocation_pools  | 192.168.24.100-192.168.24.120        |
| cidr              | 192.168.24.0/24                      |
| created_at        | 2017-05-01T14:13:51Z                 |
| description       |                                      |
| dns_nameservers   |                                      |
| enable_dhcp       | False                                |
| gateway_ip        | 192.168.24.1                         |
| host_routes       |                                      |
| id                | fce7585d-2992-4d1e-b252-78bdbbba8772 |
| ip_version        | 4                                    |
| ipv6_address_mode | None                                 |
| ipv6_ra_mode      | None                                 |
| name              | ext-subnet                           |
| network_id        | 7885b879-39ee-478b-b2fa-19c2c2fe9e39 |
| project_id        | 02d4b231650e4622bce9496f4463c1a6     |
| revision_number   | 2                                    |
| segment_id        | None                                 |
| service_types     |                                      |
| subnetpool_id     | None                                 |
| updated_at        | 2017-05-01T14:13:51Z                 |
+-------------------+--------------------------------------+

[root@overcloud-controller-0 ~]# openstack router create RouterDSA
+-------------------------+--------------------------------------+
| Field                   | Value                                |
+-------------------------+--------------------------------------+
| admin_state_up          | UP                                   |
| availability_zone_hints |                                      |
| availability_zones      |                                      |
| created_at              | 2017-05-01T14:14:28Z                 |
| description             |                                      |
| distributed             | False                                |
| external_gateway_info   | None                                 |
| flavor_id               | None                                 |
| ha                      | True                                 |
| id                      | 95ff521d-d906-441a-baae-20c6609a8b22 |
| name                    | RouterDSA                            |
| project_id              | 02d4b231650e4622bce9496f4463c1a6     |
| revision_number         | None                                 |
| routes                  |                                      |
| status                  | ACTIVE                               |
| updated_at              | 2017-05-01T14:14:28Z                 |
+-------------------------+--------------------------------------+
[root@overcloud-controller-0 ~]# openstack router set RouterDSA --external-gateway ext-net

[root@overcloud-controller-0 ~]#  openstack network create internal01
+---------------------------+--------------------------------------+
| Field                     | Value                                |
+---------------------------+--------------------------------------+
| admin_state_up            | UP                                   |
| availability_zone_hints   |                                      |
| availability_zones        |                                      |
| created_at                | 2017-05-01T14:15:35Z                 |
| description               |                                      |
| dns_domain                | None                                 |
| id                        | 5cbd8357-8d8e-42cd-958d-00f01ee9f49f |
| ipv4_address_scope        | None                                 |
| ipv6_address_scope        | None                                 |
| is_default                | None                                 |
| mtu                       | 1450                                 |
| name                      | internal01                           |
| port_security_enabled     | True                                 |
| project_id                | 02d4b231650e4622bce9496f4463c1a6     |
| provider:network_type     | vxlan                                |
| provider:physical_network | None                                 |
| provider:segmentation_id  | 65                                   |
| qos_policy_id             | None                                 |
| revision_number           | 3                                    |
| router:external           | Internal                             |
| segments                  | None                                 |
| shared                    | False                                |
| status                    | ACTIVE                               |
| subnets                   |                                      |
| updated_at                | 2017-05-01T14:15:35Z                 |
+---------------------------+--------------------------------------+

[root@overcloud-controller-0 ~]# openstack subnet create sub-internal01 --network internal01 \
>  --subnet-range 50.0.0.0/24  --dns-nameserver  83.221.202.254
+-------------------+--------------------------------------+
| Field             | Value                                |
+-------------------+--------------------------------------+
| allocation_pools  | 50.0.0.2-50.0.0.254                  |
| cidr              | 50.0.0.0/24                          |
| created_at        | 2017-05-01T14:16:12Z                 |
| description       |                                      |
| dns_nameservers   | 83.221.202.254                       |
| enable_dhcp       | True                                 |
| gateway_ip        | 50.0.0.1                             |
| host_routes       |                                      |
| id                | 407f974e-9fe3-434a-b504-797ca11ffe4f |
| ip_version        | 4                                    |
| ipv6_address_mode | None                                 |
| ipv6_ra_mode      | None                                 |
| name              | sub-internal01                       |
| network_id        | 5cbd8357-8d8e-42cd-958d-00f01ee9f49f |
| project_id        | 02d4b231650e4622bce9496f4463c1a6     |
| revision_number   | 2                                    |
| segment_id        | None                                 |
| service_types     |                                      |
| subnetpool_id     | None                                 |
| updated_at        | 2017-05-01T14:16:12Z                 |
+-------------------+--------------------------------------+

[root@overcloud-controller-0 ~]# openstack router add subnet RouterDSA 407f974e-9fe3-434a-b504-797ca11ffe4f
[root@overcloud-controller-0 ~]# openstack network create internal02
+---------------------------+--------------------------------------+
| Field                     | Value                                |
+---------------------------+--------------------------------------+
| admin_state_up            | UP                                   |
| availability_zone_hints   |                                      |
| availability_zones        |                                      |
| created_at                | 2017-05-01T14:17:37Z                 |
| description               |                                      |
| dns_domain                | None                                 |
| id                        | e37ad31a-7920-450a-bb35-f62dc25c4f74 |
| ipv4_address_scope        | None                                 |
| ipv6_address_scope        | None                                 |
| is_default                | None                                 |
| mtu                       | 1450                                 |
| name                      | internal02                           |
| port_security_enabled     | True                                 |
| project_id                | 02d4b231650e4622bce9496f4463c1a6     |
| provider:network_type     | vxlan                                |
| provider:physical_network | None                                 |
| provider:segmentation_id  | 77                                   |
| qos_policy_id             | None                                 |
| revision_number           | 3                                    |
| router:external           | Internal                             |
| segments                  | None                                 |
| shared                    | False                                |
| status                    | ACTIVE                               |
| subnets                   |                                      |
| updated_at                | 2017-05-01T14:17:37Z                 |
+---------------------------+--------------------------------------+

[root@overcloud-controller-0 ~]# openstack subnet create sub-internal02 --network internal02 \
>  --subnet-range 70.0.0.0/24  --dns-nameserver  83.221.202.254
+-------------------+--------------------------------------+
| Field             | Value                                |
+-------------------+--------------------------------------+
| allocation_pools  | 70.0.0.2-70.0.0.254                  |
| cidr              | 70.0.0.0/24                          |
| created_at        | 2017-05-01T14:18:03Z                 |
| description       |                                      |
| dns_nameservers   | 83.221.202.254                       |
| enable_dhcp       | True                                 |
| gateway_ip        | 70.0.0.1                             |
| host_routes       |                                      |
| id                | de2c205e-599c-4d1e-ac64-4be08ce93329 |
| ip_version        | 4                                    |
| ipv6_address_mode | None                                 |
| ipv6_ra_mode      | None                                 |
| name              | sub-internal02                       |
| network_id        | e37ad31a-7920-450a-bb35-f62dc25c4f74 |
| project_id        | 02d4b231650e4622bce9496f4463c1a6     |
| revision_number   | 2                                    |
| segment_id        | None                                 |
| service_types     |                                      |
| subnetpool_id     | None                                 |
| updated_at        | 2017-05-01T14:18:03Z                 |
+-------------------+--------------------------------------+
[root@overcloud-controller-0 ~]# openstack router add subnet RouterDSA de2c205e-599c-4d1e-ac64-4be08ce93329

[root@overcloud-controller-0 ~]# neutron router-port-list RouterDSA
+------------------+------------------+------------------+------------------+-------------------+
| id               | name             | tenant_id        | mac_address      | fixed_ips         |
+------------------+------------------+------------------+------------------+-------------------+
| 2032c6c2-905f-4b |                  | 02d4b231650e4622 | fa:16:3e:c8:f9:0 | {"subnet_id":     |
| bd-a400-256dca65 |                  | bce9496f4463c1a6 | 3                | "407f974e-9fe3-43 |
| 9271             |                  |                  |                  | 4a-b504-797ca11ff |
|                  |                  |                  |                  | e4f",             |
|                  |                  |                  |                  | "ip_address":     |
|                  |                  |                  |                  | "50.0.0.1"}       |
| 473ffe16-5bcc-44 | HA port tenant 0 |                  | fa:16:3e:82:9c:e | {"subnet_id": "61 |
| 15-b49b-         | 2d4b231650e4622b |                  | 7                | 36aed4-06d5-41b5- |
| c3bdb31dda2f     | ce9496f4463c1a6  |                  |                  | b888-84ba14f9d9b4 |
|                  |                  |                  |                  | ", "ip_address":  |
|                  |                  |                  |                  | "169.254.192.9"}  |
| 85b4f4ee-9401-45 |                  | 02d4b231650e4622 | fa:16:3e:59:3a:5 | {"subnet_id":     |
| 55-bb5c-         |                  | bce9496f4463c1a6 | 5                | "de2c205e-599c-   |
| cbbb1014be8f     |                  |                  |                  | 4d1e-ac64-4be08ce |
|                  |                  |                  |                  | 93329",           |
|                  |                  |                  |                  | "ip_address":     |
|                  |                  |                  |                  | "70.0.0.1"}       |
| a7b7b643-8e56-48 |                  |                  | fa:16:3e:2f:b9:b | {"subnet_id": "fc |
| 3a-8039-321ac14a |                  |                  | 2                | e7585d-2992-4d1e- |
| ff01             |                  |                  |                  | b252-78bdbbba8772 |
|                  |                  |                  |                  | ", "ip_address":  |
|                  |                  |                  |                  | "192.168.24.102"} |
| f1096789-dc85-41 | HA port tenant 0 |                  | fa:16:3e:e3:f6:4 | {"subnet_id": "61 |
| 89-9f99-136fcf96 | 2d4b231650e4622b |                  | 6                | 36aed4-06d5-41b5- |
| dff8             | ce9496f4463c1a6  |                  |                  | b888-84ba14f9d9b4 |
|                  |                  |                  |                  | ", "ip_address":  |
|                  |                  |                  |                  | "169.254.192.4"}  |
| f94ee7a4-5b44-41 | HA port tenant 0 |                  | fa:16:3e:6a:ce:a | {"subnet_id": "61 |
| a8-9256-02d8858d | 2d4b231650e4622b |                  | c                | 36aed4-06d5-41b5- |
| b669             | ce9496f4463c1a6  |                  |                  | b888-84ba14f9d9b4 |
|                  |                  |                  |                  | ", "ip_address":  |
|                  |                  |                  |                  | "169.254.192.2"}  |
+------------------+------------------+------------------+------------------+-------------------+

[root@overcloud-controller-0 ~]# neutron port-list | grep 50.0.0.1
| 2032c6c2-905f-4bbd-a400-256dca659271 |                                                 | 02d4b231650e4622bce9496f4463c1a6 | fa:16:3e:c8:f9:03 | {"subnet_id": "407f974e-9fe3-434a-b504-797ca11ffe4f", "ip_address": "50.0.0.1"}       |

[root@overcloud-controller-0 ~]# neutron port-show 2032c6c2-905f-4bbd-a400-256dca659271
+-----------------------+-----------------------------------------------------------------------+
| Field                 | Value                                                                 |
+-----------------------+-----------------------------------------------------------------------+
| admin_state_up        | True                                                                  |
| allowed_address_pairs |                                                                       |
| binding:host_id       | overcloud-controller-1.localdomain                                    |
| binding:profile       | {}                                                                    |
| binding:vif_details   | {"port_filter": true, "ovs_hybrid_plug": true}                        |
| binding:vif_type      | ovs                                                                   |
| binding:vnic_type     | normal                                                                |
| created_at            | 2017-05-01T14:16:59Z                                                  |
| description           |                                                                       |
| device_id             | 95ff521d-d906-441a-baae-20c6609a8b22                                  |
| device_owner          | network:ha_router_replicated_interface                                |
| extra_dhcp_opts       |                                                                       |
| fixed_ips             | {"subnet_id": "407f974e-9fe3-434a-b504-797ca11ffe4f", "ip_address":   |
|                       | "50.0.0.1"}                                                           |
| id                    | 2032c6c2-905f-4bbd-a400-256dca659271                                  |
| mac_address           | fa:16:3e:c8:f9:03                                                     |
| name                  |                                                                       |
| network_id            | 5cbd8357-8d8e-42cd-958d-00f01ee9f49f                                  |
| port_security_enabled | False                                                                 |
| project_id            | 02d4b231650e4622bce9496f4463c1a6                                      |
| qos_policy_id         |                                                                       |
| revision_number       | 8                                                                     |
| security_groups       |                                                                       |
| status                | ACTIVE                                                                |
| tags                  |                                                                       |
| tenant_id             | 02d4b231650e4622bce9496f4463c1a6                                      |
| updated_at            | 2017-05-01T14:17:05Z                                                  |
+-----------------------+-----------------------------------------------------------------------+

[root@overcloud-controller-0 ~]# neutron port-list | grep 70.0.0.1
| 85b4f4ee-9401-4555-bb5c-cbbb1014be8f |                                                 | 02d4b231650e4622bce9496f4463c1a6 | fa:16:3e:59:3a:55 | {"subnet_id": "de2c205e-599c-4d1e-ac64-4be08ce93329", "ip_address": "70.0.0.1"}       |

[root@overcloud-controller-0 ~]# neutron port-show 85b4f4ee-9401-4555-bb5c-cbbb1014be8f
+-----------------------+-----------------------------------------------------------------------+
| Field                 | Value                                                                 |
+-----------------------+-----------------------------------------------------------------------+
| admin_state_up        | True                                                                  |
| allowed_address_pairs |                                                                       |
| binding:host_id       | overcloud-controller-1.localdomain                                    |
| binding:profile       | {}                                                                    |
| binding:vif_details   | {"port_filter": true, "ovs_hybrid_plug": true}                        |
| binding:vif_type      | ovs                                                                   |
| binding:vnic_type     | normal                                                                |
| created_at            | 2017-05-01T14:18:43Z                                                  |
| description           |                                                                       |
| device_id             | 95ff521d-d906-441a-baae-20c6609a8b22                                  |
| device_owner          | network:ha_router_replicated_interface                                |
| extra_dhcp_opts       |                                                                       |
| fixed_ips             | {"subnet_id": "de2c205e-599c-4d1e-ac64-4be08ce93329", "ip_address":   |
|                       | "70.0.0.1"}                                                           |
| id                    | 85b4f4ee-9401-4555-bb5c-cbbb1014be8f                                  |
| mac_address           | fa:16:3e:59:3a:55                                                     |
| name                  |                                                                       |
| network_id            | e37ad31a-7920-450a-bb35-f62dc25c4f74                                  |
| port_security_enabled | False                                                                 |
| project_id            | 02d4b231650e4622bce9496f4463c1a6                                      |
| qos_policy_id         |                                                                       |
| revision_number       | 8                                                                     |
| security_groups       |                                                                       |
| status                | ACTIVE                                                                |
| tags                  |                                                                       |
| tenant_id             | 02d4b231650e4622bce9496f4463c1a6                                      |
| updated_at            | 2017-05-01T14:18:51Z                                                  |
+-----------------------+-----------------------------------------------------------------------+

[root@overcloud-controller-0 ~]# nova secgroup-list
+--------------------------------------+---------+------------------------+
| Id                                   | Name    | Description            |
+--------------------------------------+---------+------------------------+
| 0da20519-d695-4ce6-9a5e-1a9e04b07fcf | default | Default security group |
+--------------------------------------+---------+------------------------+

[root@overcloud-controller-0 ~]# openstack security group rule create \
 0da20519-d695-4ce6-9a5e-1a9e04b07fcf \
>  --protocol tcp --dst-port 22:22 --remote-ip 0.0.0.0/0
+-------------------+--------------------------------------+
| Field             | Value                                |
+-------------------+--------------------------------------+
| created_at        | 2017-05-01T14:23:45Z                 |
| description       |                                      |
| direction         | ingress                              |
| ether_type        | IPv4                                 |
| id                | fb813d43-8472-4b5d-8bbd-62e1898114fe |
| name              | None                                 |
| port_range_max    | 22                                   |
| port_range_min    | 22                                   |
| project_id        | 02d4b231650e4622bce9496f4463c1a6     |
| protocol          | tcp                                  |
| remote_group_id   | None                                 |
| remote_ip_prefix  | 0.0.0.0/0                            |
| revision_number   | 1                                    |
| security_group_id | 0da20519-d695-4ce6-9a5e-1a9e04b07fcf |
| updated_at        | 2017-05-01T14:23:45Z                 |
+-------------------+--------------------------------------+

[root@overcloud-controller-0 ~]# nova secgroup-list
+--------------------------------------+---------+------------------------+
| Id                                   | Name    | Description            |
+--------------------------------------+---------+------------------------+
| 0da20519-d695-4ce6-9a5e-1a9e04b07fcf | default | Default security group |
+--------------------------------------+---------+------------------------+

[root@overcloud-controller-0 ~]# neutron port-create \
--security-group 0da20519-d695-4ce6-9a5e-1a9e04b07fcf internal02
Created a new port:
+-----------------------+-----------------------------------------------------------------------+
| Field                 | Value                                                                 |
+-----------------------+-----------------------------------------------------------------------+
| admin_state_up        | True                                                                  |
| allowed_address_pairs |                                                                       |
| binding:host_id       |                                                                       |
| binding:profile       | {}                                                                    |
| binding:vif_details   | {}                                                                    |
| binding:vif_type      | unbound                                                               |
| binding:vnic_type     | normal                                                                |
| created_at            | 2017-05-01T14:33:22Z                                                  |
| description           |                                                                       |
| device_id             |                                                                       |
| device_owner          |                                                                       |
| extra_dhcp_opts       |                                                                       |
| fixed_ips             | {"subnet_id": "de2c205e-599c-4d1e-ac64-4be08ce93329", "ip_address":   |
|                       | "70.0.0.8"}                                                           |
| id                    | 918ac735-0ebe-471c-a2aa-8f00550a68b7                                  |
| mac_address           | fa:16:3e:ec:25:f1                                                     |
| name                  |                                                                       |
| network_id            | e37ad31a-7920-450a-bb35-f62dc25c4f74                                  |
| port_security_enabled | True                                                                  |
| project_id            | 02d4b231650e4622bce9496f4463c1a6                                      |
| qos_policy_id         |                                                                       |
| revision_number       | 5                                                                     |
| security_groups       | 0da20519-d695-4ce6-9a5e-1a9e04b07fcf                                  |
| status                | DOWN                                                                  |
| tags                  |                                                                       |
| tenant_id             | 02d4b231650e4622bce9496f4463c1a6                                      |
| updated_at            | 2017-05-01T14:33:22Z                                                  |
+-----------------------+-----------------------------------------------------------------------+
[root@overcloud-controller-0 ~]# nova interface-attach --port-id \
   918ac735-0ebe-471c-a2aa-8f00550a68b7  centos73devs01

[root@overcloud-controller-0 ~]# openstack server list
+---------------------------+----------------+--------+----------------------------+------------+
| ID                        | Name           | Status | Networks                   | Image Name |
+---------------------------+----------------+--------+----------------------------+------------+
| dd9f458d-0d54-465e-       | centos73devs01 | ACTIVE | internal01=50.0.0.10;      |            |
| b8c4-79f73abecf53         |                |        | internal02=70.0.0.8        |            |
+---------------------------+----------------+--------+----------------------------+------------+
[root@overcloud-controller-0 ~]# openstack server stop centos73devs01
[root@overcloud-controller-0 ~]# openstack server list
+---------------------------+----------------+---------+---------------------------+------------+
| ID                        | Name           | Status  | Networks                  | Image Name |
+---------------------------+----------------+---------+---------------------------+------------+
| dd9f458d-0d54-465e-       | centos73devs01 | SHUTOFF | internal01=50.0.0.10;     |            |
| b8c4-79f73abecf53         |                |         | internal02=70.0.0.8       |            |
+---------------------------+----------------+---------+---------------------------+------------+
[root@overcloud-controller-0 ~]# openstack server start centos73devs01
[root@overcloud-controller-0 ~]# openstack server list
+---------------------------+----------------+--------+----------------------------+------------+
| ID                        | Name           | Status | Networks                   | Image Name |
+---------------------------+----------------+--------+----------------------------+------------+
| dd9f458d-0d54-465e-       | centos73devs01 | ACTIVE | internal01=50.0.0.10;      |            |
| b8c4-79f73abecf53         |                |        | internal02=70.0.0.8        |            |
+---------------------------+----------------+--------+----------------------------+------------+

[root@overcloud-controller-0 ~]# openstack server list +---------------------------+----------------+--------+----------------------------+------------+ | ID                        | Name           | Status | Networks                   | Image Name | +---------------------------+----------------+--------+----------------------------+------------+ | dd9f458d-0d54-465e-       | centos73devs01 | ACTIVE | internal01=50.0.0.10;      |            | | b8c4-79f73abecf53         |                |        | internal02=70.0.0.8,       |            | |                           |                |        | 192.168.24.105             |            | +---------------------------+----------------+--------+----------------------------+------------+

No comments:

Post a Comment