Exercise 3

Create a Topology using Neutron CLI Commands as per the below diagram,

Remarks: This exercise demonstrates the Host Route, Addition of Static Route in the Router.

Keypoints :

In the Office Network VMs, static routes to be added for LAB Network (192.168.101.0/24) pointing to 10.10.10.254. This can be achieved by Neutron "Host Route" feature.

In the Office Router, Static route to be added for 192.168.101.0/24 pointing to 10.10.10.254.

In the Lab router, Static route to be added for 0.0.0.0/0(default route) pointing to 10.10.10.1. This can be achieved by Neutron router-update command.

Tests to be done:

  1. Login to Office VM and ping LAB VM and Internet.
  2. Login to LAB VM and ping Office VM and Internet.

Solution:

1. Create a Networks and Routers:

Create a office Network:

neutron net-create Office-Net

Create a subnet for office-Network

neutron subnet-create --name Office-Sub --gateway 10.10.10.1 --allocation-pool start=10.10.10.10,end=10.10.10.50  --host-route destination=192.168.101.0/24,nexthop=10.10.10.254  Office-Net 10.10.10.0/24

Note: Specified the gateway as 10.10.10.1, subnet pool is 10.10.10.10 to 10.10.10.50

Specified Host Route (Static routes will be added in the VMs in this subnet) : 192.168.101.0/24 nexthop: 10.10.10.254

Create a Lab Network & Subnet:

neutron net-create Lab-Net
neutron subnet-create --name Lab-Sub --gateway 192.168.101.1 --allocation-pool start=192.168.101.10,end=192.168.101.50 Lab-Net 192.168.101.0/24

Create the Internet Router, Setup the Gateway and attach the Office Subnet:

neutron router-create I-Router
neutron router-gateway-set I-Router public
neutron router-interface-add I-Router Office-Sub

Add the static router to the Internet Router:

neutron router-update --route destination=192.168.101.0/24,nexthop=10.10.10.254 I-Router

Create the Lab Router:

Lab Router doesnt require gateway as per the topology. One interface is connected to Lab Network, other interface is connected to Office Network

neutron router-create Lab-Router
neutron router-interface-add Lab-Router Lab-Sub

Add the router interface:

Office Network IP(10.10.10.254) is configured for the Router Port. Hence we need to create a Port with 10.10.10.254 and attach with router.

neutron port-create --fixed-ip subnet_id=Office-Sub,ip_address=10.10.10.254 Office-Net
neutron router-interface-add Lab-Router port=34d8d339-b17a-45ef-8220-e4ff529f2b03

Update the static routes(default route pointing to Internet Router) in to the Lab Router

neutron router-update --route destination=0.0.0.0/0,nexthop=10.10.10.1 Lab-Router

2. Create a VMs:

Create a office VM:

VM Fixed IP is 10.10.10.100. Hence we need to create a port with this IP.

neutron port-create --fixed-ip subnet_id=Office-Sub,ip_address=10.10.10.100 Office-Net
nova boot --flavor 6 --image ubuntu14 --key-name testkey --security-groups default --nic port-id=dda54413-3324-4ea6-b0b9-64446aafcc61 Office-VM

Associate the Free Floating IP to this VM:

neutron floatingip-list
neutron floatingip-associate dcb48f7f-cb4c-4289-a27b-62b4e3399647 dda54413-3324-4ea6-b0b9-64446aafcc61

Create a Lab VM:

neutron port-create --fixed-ip subnet_id=Lab-Sub,ip_address=192.168.101.100 Lab-Net
nova boot --flavor 6 --image ubuntu14 --key-name testkey --security-groups default --nic port-id=cf8f294b-1bbc-4c92-9259-e77b5084870d Lab-VM

3. Testing:

Office VM:

Ping the office VM Floating ip

ping  172.24.4.12

It is pinging.

SSH to the Office VM floating IP

ssh -i testkey [email protected]

Ping google.com from the Office VM

ping google.com

Its it pinging.

Ping Lab VM from the Office VM

Ping 192.168.101.100

It is pinging.

Check the routes in the Office VM

route

Static route is present for Lab Network.

LAB VM:

Lab VM doesnt have floating IP. Hence we cannot directly SSH to it. But via Office-VM we can SSH.

Copy(scp) the keyfile(testkey) in to officeVM and SSH to Office VM. And SSH again to LAB VM.

scp -i testkey testkey [email protected]:/home/ubuntu/.
ssh -i testkey [email protected]
ssh -i testkey [email protected]

Ping google.com from LAB VM

ping google.com

Execution Logs:

1. Create a Networks and Routers:

(osclient) cloud@dev1:~$ neutron net-create Office-Net
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new network:
+-------------------------+--------------------------------------+
| Field                   | Value                                |
+-------------------------+--------------------------------------+
| admin_state_up          | True                                 |
| availability_zone_hints |                                      |
| availability_zones      |                                      |
| created_at              | 2017-08-22T09:30:16Z                 |
| description             |                                      |
| id                      | 2e69acda-02d5-4c3e-babc-4ef598267c4c |
| ipv4_address_scope      |                                      |
| ipv6_address_scope      |                                      |
| mtu                     | 1450                                 |
| name                    | Office-Net                           |
| port_security_enabled   | True                                 |
| project_id              | bccf45eee4544264a526c4bca56fdb3c     |
| revision_number         | 3                                    |
| router:external         | False                                |
| shared                  | False                                |
| status                  | ACTIVE                               |
| subnets                 |                                      |
| tags                    |                                      |
| tenant_id               | bccf45eee4544264a526c4bca56fdb3c     |
| updated_at              | 2017-08-22T09:30:16Z                 |
+-------------------------+--------------------------------------+
(osclient) cloud@dev1:~$ neutron subnet-create --name Office-Sub --gateway 10.10.10.1 --allocation-pool start=10.10.10.10,end=10.10.10.50  --host-route destination=192.168.101.0/24,nexthop=10.10.10.254  Office-Net 10.10.10.0/24
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new subnet:
+-------------------+----------------------------------------------------------------+
| Field             | Value                                                          |
+-------------------+----------------------------------------------------------------+
| allocation_pools  | {"start": "10.10.10.10", "end": "10.10.10.50"}                 |
| cidr              | 10.10.10.0/24                                                  |
| created_at        | 2017-08-22T09:30:28Z                                           |
| description       |                                                                |
| dns_nameservers   |                                                                |
| enable_dhcp       | True                                                           |
| gateway_ip        | 10.10.10.1                                                     |
| host_routes       | {"destination": "192.168.101.0/24", "nexthop": "10.10.10.254"} |
| id                | 45f3e43c-c4a1-4a9b-9db0-0285175794e7                           |
| ip_version        | 4                                                              |
| ipv6_address_mode |                                                                |
| ipv6_ra_mode      |                                                                |
| name              | Office-Sub                                                     |
| network_id        | 2e69acda-02d5-4c3e-babc-4ef598267c4c                           |
| project_id        | bccf45eee4544264a526c4bca56fdb3c                               |
| revision_number   | 2                                                              |
| service_types     |                                                                |
| subnetpool_id     |                                                                |
| tags              |                                                                |
| tenant_id         | bccf45eee4544264a526c4bca56fdb3c                               |
| updated_at        | 2017-08-22T09:30:28Z                                           |
+-------------------+----------------------------------------------------------------+
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ neutron net-create Lab-Net
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new network:
+-------------------------+--------------------------------------+
| Field                   | Value                                |
+-------------------------+--------------------------------------+
| admin_state_up          | True                                 |
| availability_zone_hints |                                      |
| availability_zones      |                                      |
| created_at              | 2017-08-22T09:32:11Z                 |
| description             |                                      |
| id                      | b422d2ad-908e-420d-a71b-9e82ee976b5b |
| ipv4_address_scope      |                                      |
| ipv6_address_scope      |                                      |
| mtu                     | 1450                                 |
| name                    | Lab-Net                              |
| port_security_enabled   | True                                 |
| project_id              | bccf45eee4544264a526c4bca56fdb3c     |
| revision_number         | 3                                    |
| router:external         | False                                |
| shared                  | False                                |
| status                  | ACTIVE                               |
| subnets                 |                                      |
| tags                    |                                      |
| tenant_id               | bccf45eee4544264a526c4bca56fdb3c     |
| updated_at              | 2017-08-22T09:32:11Z                 |
+-------------------------+--------------------------------------+
(osclient) cloud@dev1:~$ neutron subnet-create --name Lab-Sub --gateway 192.168.101.1 --allocation-pool start=192.168.101.10,end=192.168.101.50 Lab-Net 192.168.101.0/24
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new subnet:
+-------------------+------------------------------------------------------+
| Field             | Value                                                |
+-------------------+------------------------------------------------------+
| allocation_pools  | {"start": "192.168.101.10", "end": "192.168.101.50"} |
| cidr              | 192.168.101.0/24                                     |
| created_at        | 2017-08-22T09:32:21Z                                 |
| description       |                                                      |
| dns_nameservers   |                                                      |
| enable_dhcp       | True                                                 |
| gateway_ip        | 192.168.101.1                                        |
| host_routes       |                                                      |
| id                | 3173862b-93cd-487d-aa1c-84c8a3ef0b3a                 |
| ip_version        | 4                                                    |
| ipv6_address_mode |                                                      |
| ipv6_ra_mode      |                                                      |
| name              | Lab-Sub                                              |
| network_id        | b422d2ad-908e-420d-a71b-9e82ee976b5b                 |
| project_id        | bccf45eee4544264a526c4bca56fdb3c                     |
| revision_number   | 2                                                    |
| service_types     |                                                      |
| subnetpool_id     |                                                      |
| tags              |                                                      |
| tenant_id         | bccf45eee4544264a526c4bca56fdb3c                     |
| updated_at        | 2017-08-22T09:32:21Z                                 |
+-------------------+------------------------------------------------------+
(osclient) cloud@dev1:~$ 

(osclient) cloud@dev1:~$ neutron router-create I-Router
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new router:
+-------------------------+--------------------------------------+
| Field                   | Value                                |
+-------------------------+--------------------------------------+
| admin_state_up          | True                                 |
| availability_zone_hints |                                      |
| availability_zones      |                                      |
| created_at              | 2017-08-22T09:34:00Z                 |
| description             |                                      |
| external_gateway_info   |                                      |
| flavor_id               |                                      |
| id                      | 02fc87c6-28e3-40cf-bf07-9a00a00be834 |
| name                    | I-Router                             |
| project_id              | bccf45eee4544264a526c4bca56fdb3c     |
| revision_number         | 3                                    |
| routes                  |                                      |
| status                  | ACTIVE                               |
| tags                    |                                      |
| tenant_id               | bccf45eee4544264a526c4bca56fdb3c     |
| updated_at              | 2017-08-22T09:34:00Z                 |
+-------------------------+--------------------------------------+
(osclient) cloud@dev1:~$ neutron router-gateway-set I-Router public
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Set gateway for router I-Router
(osclient) cloud@dev1:~$ neutron router-interface-add I-Router Office-Sub
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Added interface e3942431-11de-4a35-9283-ee4426643d0c to router I-Router.
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ neutron router-update --route destination=192.168.101.0/24,nexthop=10.10.10.254 I-Router
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Updated router: I-Router
(osclient) cloud@dev1:~$

(osclient) cloud@dev1:~$ neutron router-list --fit-width
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
+--------------------------------------+----------+---------------------------------------------------------------------------+
| id                                   | name     | external_gateway_info                                                     |
+--------------------------------------+----------+---------------------------------------------------------------------------+
| 02fc87c6-28e3-40cf-bf07-9a00a00be834 | I-Router | {"network_id": "975dd3d1-3576-4c34-991e-eaf24f45295e", "enable_snat":     |
|                                      |          | true, "external_fixed_ips": [{"subnet_id":                                |
|                                      |          | "543ef8a3-5717-44d1-81f9-70c5057e889c", "ip_address": "172.24.4.11"},     |
|                                      |          | {"subnet_id": "8171e8c6-2953-4ffa-beab-8f07b43a08c4", "ip_address":       |
|                                      |          | "2001:db8::1"}]}                                                          |
+--------------------------------------+----------+---------------------------------------------------------------------------+
(osclient) cloud@dev1:~$ 

(osclient) cloud@dev1:~$ neutron router-create Lab-Router
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new router:
+-------------------------+--------------------------------------+
| Field                   | Value                                |
+-------------------------+--------------------------------------+
| admin_state_up          | True                                 |
| availability_zone_hints |                                      |
| availability_zones      |                                      |
| created_at              | 2017-08-22T09:36:11Z                 |
| description             |                                      |
| external_gateway_info   |                                      |
| flavor_id               |                                      |
| id                      | 5f164473-14bc-47be-be0d-749ed8143c0c |
| name                    | Lab-Router                           |
| project_id              | bccf45eee4544264a526c4bca56fdb3c     |
| revision_number         | 3                                    |
| routes                  |                                      |
| status                  | ACTIVE                               |
| tags                    |                                      |
| tenant_id               | bccf45eee4544264a526c4bca56fdb3c     |
| updated_at              | 2017-08-22T09:36:11Z                 |
+-------------------------+--------------------------------------+
(osclient) cloud@dev1:~$ neutron router-interface-add Lab-Router Lab-Sub
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Added interface 600eccdc-4982-4b7f-94db-b7b1163bc36f to router Lab-Router.
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ neutron port-create --fixed-ip subnet_id=Office-Sub,ip_address=10.10.10.254 Office-Net
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new port:
+-----------------------+-------------------------------------------------------------------------------------+
| Field                 | Value                                                                               |
+-----------------------+-------------------------------------------------------------------------------------+
| admin_state_up        | True                                                                                |
| allowed_address_pairs |                                                                                     |
| binding:vnic_type     | normal                                                                              |
| created_at            | 2017-08-22T09:38:46Z                                                                |
| description           |                                                                                     |
| device_id             |                                                                                     |
| device_owner          |                                                                                     |
| extra_dhcp_opts       |                                                                                     |
| fixed_ips             | {"subnet_id": "45f3e43c-c4a1-4a9b-9db0-0285175794e7", "ip_address": "10.10.10.254"} |
| id                    | 34d8d339-b17a-45ef-8220-e4ff529f2b03                                                |
| mac_address           | fa:16:3e:33:bc:08                                                                   |
| name                  |                                                                                     |
| network_id            | 2e69acda-02d5-4c3e-babc-4ef598267c4c                                                |
| port_security_enabled | True                                                                                |
| project_id            | bccf45eee4544264a526c4bca56fdb3c                                                    |
| revision_number       | 5                                                                                   |
| security_groups       | bffcafe4-3baa-49f7-836e-2bf335d4f366                                                |
| status                | DOWN                                                                                |
| tags                  |                                                                                     |
| tenant_id             | bccf45eee4544264a526c4bca56fdb3c                                                    |
| updated_at            | 2017-08-22T09:38:46Z                                                                |
+-----------------------+-------------------------------------------------------------------------------------+
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ neutron router-interface-add Lab-Router port=34d8d339-b17a-45ef-8220-e4ff529f2b03
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Added interface 34d8d339-b17a-45ef-8220-e4ff529f2b03 to router Lab-Router.
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ neutron router-update --route destination=0.0.0.0/0,nexthop=10.10.10.1 Lab-Router
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Updated router: Lab-Router
(osclient) cloud@dev1:~$ neutron router-show Lab-Router
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
+-------------------------+-------------------------------------------------------+
| Field                   | Value                                                 |
+-------------------------+-------------------------------------------------------+
| admin_state_up          | True                                                  |
| availability_zone_hints |                                                       |
| availability_zones      | nova                                                  |
| created_at              | 2017-08-22T09:36:11Z                                  |
| description             |                                                       |
| external_gateway_info   |                                                       |
| flavor_id               |                                                       |
| id                      | 5f164473-14bc-47be-be0d-749ed8143c0c                  |
| name                    | Lab-Router                                            |
| project_id              | bccf45eee4544264a526c4bca56fdb3c                      |
| revision_number         | 6                                                     |
| routes                  | {"destination": "0.0.0.0/0", "nexthop": "10.10.10.1"} |
| status                  | ACTIVE                                                |
| tags                    |                                                       |
| tenant_id               | bccf45eee4544264a526c4bca56fdb3c                      |
| updated_at              | 2017-08-22T09:41:38Z                                  |
+-------------------------+-------------------------------------------------------+
(osclient) cloud@dev1:~$

2. Create VMs:

(osclient) cloud@dev1:~$ neutron port-create --fixed-ip subnet_id=Office-Sub,ip_address=10.10.10.100 Office-Net
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new port:
+-----------------------+-------------------------------------------------------------------------------------+
| Field                 | Value                                                                               |
+-----------------------+-------------------------------------------------------------------------------------+
| admin_state_up        | True                                                                                |
| allowed_address_pairs |                                                                                     |
| binding:vnic_type     | normal                                                                              |
| created_at            | 2017-08-22T09:44:38Z                                                                |
| description           |                                                                                     |
| device_id             |                                                                                     |
| device_owner          |                                                                                     |
| extra_dhcp_opts       |                                                                                     |
| fixed_ips             | {"subnet_id": "45f3e43c-c4a1-4a9b-9db0-0285175794e7", "ip_address": "10.10.10.100"} |
| id                    | dda54413-3324-4ea6-b0b9-64446aafcc61                                                |
| mac_address           | fa:16:3e:8e:e7:68                                                                   |
| name                  |                                                                                     |
| network_id            | 2e69acda-02d5-4c3e-babc-4ef598267c4c                                                |
| port_security_enabled | True                                                                                |
| project_id            | bccf45eee4544264a526c4bca56fdb3c                                                    |
| revision_number       | 5                                                                                   |
| security_groups       | bffcafe4-3baa-49f7-836e-2bf335d4f366                                                |
| status                | DOWN                                                                                |
| tags                  |                                                                                     |
| tenant_id             | bccf45eee4544264a526c4bca56fdb3c                                                    |
| updated_at            | 2017-08-22T09:44:38Z                                                                |
+-----------------------+-------------------------------------------------------------------------------------+
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ nova boot --flavor 6 --image ubuntu14 --key-name testkey --security-groups default --nic port-id=dda54413-3324-4ea6-b0b9-64446aafcc61 Office-VM
+--------------------------------------+-------------------------------------------------+
| Property                             | Value                                           |
+--------------------------------------+-------------------------------------------------+
| OS-DCF:diskConfig                    | MANUAL                                          |
| OS-EXT-AZ:availability_zone          |                                                 |
| OS-EXT-STS:power_state               | 0                                               |
| OS-EXT-STS:task_state                | scheduling                                      |
| OS-EXT-STS:vm_state                  | building                                        |
| OS-SRV-USG:launched_at               | -                                               |
| OS-SRV-USG:terminated_at             | -                                               |
| accessIPv4                           |                                                 |
| accessIPv6                           |                                                 |
| adminPass                            | xstYj3N2w84F                                    |
| config_drive                         |                                                 |
| created                              | 2017-08-22T09:48:20Z                            |
| description                          | -                                               |
| flavor                               | m1.tiny2 (6)                                    |
| hostId                               |                                                 |
| id                                   | c9f6e200-e688-4138-a903-78921d60caca            |
| image                                | ubuntu14 (eb570c2e-46e2-4cc3-928a-fe5cdffa7822) |
| key_name                             | testkey                                         |
| locked                               | False                                           |
| metadata                             | {}                                              |
| name                                 | Office-VM                                       |
| os-extended-volumes:volumes_attached | []                                              |
| progress                             | 0                                               |
| security_groups                      | default                                         |
| status                               | BUILD                                           |
| tags                                 | []                                              |
| tenant_id                            | bccf45eee4544264a526c4bca56fdb3c                |
| updated                              | 2017-08-22T09:48:20Z                            |
| user_id                              | 9b2d58dc14b2456fa5b7e5adae366f04                |
+--------------------------------------+-------------------------------------------------+
(osclient) cloud@dev1:~$ 
(osclient) cloud@dev1:~$ nova list
+--------------------------------------+-----------+--------+------------+-------------+-------------------------+
| ID                                   | Name      | Status | Task State | Power State | Networks                |
+--------------------------------------+-----------+--------+------------+-------------+-------------------------+
| c9f6e200-e688-4138-a903-78921d60caca | Office-VM | ACTIVE | -          | Running     | Office-Net=10.10.10.100 |
+--------------------------------------+-----------+--------+------------+-------------+-------------------------+
(osclient) cloud@dev1:~$ neutron floatingip-list
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
+--------------------------------------+------------------+---------------------+---------+
| id                                   | fixed_ip_address | floating_ip_address | port_id |
+--------------------------------------+------------------+---------------------+---------+
| 110f5f61-1f30-4ad6-8aca-40bfcf485af4 |                  | 172.24.4.2          |         |
| dcb48f7f-cb4c-4289-a27b-62b4e3399647 |                  | 172.24.4.12         |         |
+--------------------------------------+------------------+---------------------+---------+
(osclient) cloud@dev1:~$ neutron floatingip-associate dcb48f7f-cb4c-4289-a27b-62b4e3399647 dda54413-3324-4ea6-b0b9-64446aafcc61neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Associated floating IP dcb48f7f-cb4c-4289-a27b-62b4e3399647
(osclient) cloud@dev1:~$ nova list
+--------------------------------------+-----------+--------+------------+-------------+--------------------------------------+
| ID                                   | Name      | Status | Task State | Power State | Networks                             |
+--------------------------------------+-----------+--------+------------+-------------+--------------------------------------+
| c9f6e200-e688-4138-a903-78921d60caca | Office-VM | ACTIVE | -          | Running     | Office-Net=10.10.10.100, 172.24.4.12 |
+--------------------------------------+-----------+--------+------------+-------------+--------------------------------------+
(osclient) cloud@dev1:~$ 


(osclient) cloud@dev1:~$ neutron port-create --fixed-ip subnet_id=Lab-Sub,ip_address=192.168.101.100 Lab-Net
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
Created a new port:
+-----------------------+----------------------------------------------------------------------------------------+
| Field                 | Value                                                                                  |
+-----------------------+----------------------------------------------------------------------------------------+
| admin_state_up        | True                                                                                   |
| allowed_address_pairs |                                                                                        |
| binding:vnic_type     | normal                                                                                 |
| created_at            | 2017-08-22T09:52:35Z                                                                   |
| description           |                                                                                        |
| device_id             |                                                                                        |
| device_owner          |                                                                                        |
| extra_dhcp_opts       |                                                                                        |
| fixed_ips             | {"subnet_id": "3173862b-93cd-487d-aa1c-84c8a3ef0b3a", "ip_address": "192.168.101.100"} |
| id                    | cf8f294b-1bbc-4c92-9259-e77b5084870d                                                   |
| mac_address           | fa:16:3e:48:bd:f9                                                                      |
| name                  |                                                                                        |
| network_id            | b422d2ad-908e-420d-a71b-9e82ee976b5b                                                   |
| port_security_enabled | True                                                                                   |
| project_id            | bccf45eee4544264a526c4bca56fdb3c                                                       |
| revision_number       | 5                                                                                      |
| security_groups       | bffcafe4-3baa-49f7-836e-2bf335d4f366                                                   |
| status                | DOWN                                                                                   |
| tags                  |                                                                                        |
| tenant_id             | bccf45eee4544264a526c4bca56fdb3c                                                       |
| updated_at            | 2017-08-22T09:52:35Z                                                                   |
+-----------------------+----------------------------------------------------------------------------------------+
(osclient) cloud@dev1:~$ 
(osclient) cloud@dev1:~$ nova boot --flavor 6 --image ubuntu14 --key-name testkey --security-groups default --nic port-id=cf8f294b-1bbc-4c92-9259-e77b5084870d Lab-VM
+--------------------------------------+-------------------------------------------------+
| Property                             | Value                                           |
+--------------------------------------+-------------------------------------------------+
| OS-DCF:diskConfig                    | MANUAL                                          |
| OS-EXT-AZ:availability_zone          |                                                 |
| OS-EXT-STS:power_state               | 0                                               |
| OS-EXT-STS:task_state                | scheduling                                      |
| OS-EXT-STS:vm_state                  | building                                        |
| OS-SRV-USG:launched_at               | -                                               |
| OS-SRV-USG:terminated_at             | -                                               |
| accessIPv4                           |                                                 |
| accessIPv6                           |                                                 |
| adminPass                            | hvGSa3oENsLx                                    |
| config_drive                         |                                                 |
| created                              | 2017-08-22T09:53:29Z                            |
| description                          | -                                               |
| flavor                               | m1.tiny2 (6)                                    |
| hostId                               |                                                 |
| id                                   | 9df5b434-5e2f-4d51-adad-9da8048b3aff            |
| image                                | ubuntu14 (eb570c2e-46e2-4cc3-928a-fe5cdffa7822) |
| key_name                             | testkey                                         |
| locked                               | False                                           |
| metadata                             | {}                                              |
| name                                 | Lab-VM                                          |
| os-extended-volumes:volumes_attached | []                                              |
| progress                             | 0                                               |
| security_groups                      | default                                         |
| status                               | BUILD                                           |
| tags                                 | []                                              |
| tenant_id                            | bccf45eee4544264a526c4bca56fdb3c                |
| updated                              | 2017-08-22T09:53:29Z                            |
| user_id                              | 9b2d58dc14b2456fa5b7e5adae366f04                |
+--------------------------------------+-------------------------------------------------+
(osclient) cloud@dev1:~$
(osclient) cloud@dev1:~$ nova list
+--------------------------------------+-----------+--------+------------+-------------+--------------------------------------+
| ID                                   | Name      | Status | Task State | Power State | Networks                             |
+--------------------------------------+-----------+--------+------------+-------------+--------------------------------------+
| 9df5b434-5e2f-4d51-adad-9da8048b3aff | Lab-VM    | ACTIVE | -          | Running     | Lab-Net=192.168.101.100              |
| c9f6e200-e688-4138-a903-78921d60caca | Office-VM | ACTIVE | -          | Running     | Office-Net=10.10.10.100, 172.24.4.12 |
+--------------------------------------+-----------+--------+------------+-------------+--------------------------------------+
(osclient) cloud@dev1:~$

3. Testing:

(osclient) cloud@dev1:~$ ping 172.24.4.12
PING 172.24.4.12 (172.24.4.12) 56(84) bytes of data.
64 bytes from 172.24.4.12: icmp_seq=1 ttl=63 time=1.26 ms
64 bytes from 172.24.4.12: icmp_seq=2 ttl=63 time=0.432 ms
^C
--- 172.24.4.12 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 0.432/0.849/1.266/0.417 ms
(osclient) cloud@dev1:~$ ssh -i testkey [email protected]
The authenticity of host '172.24.4.12 (172.24.4.12)' can't be established.
ECDSA key fingerprint is 5d:92:dc:e6:ca:ef:5d:71:de:ef:0a:cf:d8:fe:64:72.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '172.24.4.12' (ECDSA) to the list of known hosts.
Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-126-generic x86_64)

 * Documentation:  https://help.ubuntu.com/

  System information as of Tue Aug 22 09:48:55 UTC 2017

  System load: 0.29              Memory usage: 4%   Processes:       52
  Usage of /:  58.4% of 1.32GB   Swap usage:   0%   Users logged in: 0

  Graph this data and manage this system at:
    https://landscape.canonical.com/

  Get cloud support with Ubuntu Advantage Cloud Guest:
    http://www.ubuntu.com/business/services/cloud

0 packages can be updated.
0 updates are security updates.



The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.

ubuntu@office-vm:~$ ping google.com
PING google.com (172.217.19.238) 56(84) bytes of data.
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=1 ttl=56 time=4.25 ms
^C
--- google.com ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 4.258/4.258/4.258/0.000 ms
ubuntu@office-vm:~$ ping 192.168.101.100
PING 192.168.101.100 (192.168.101.100) 56(84) bytes of data.
64 bytes from 192.168.101.100: icmp_seq=1 ttl=63 time=2.59 ms
64 bytes from 192.168.101.100: icmp_seq=2 ttl=63 time=0.859 ms
^C
--- 192.168.101.100 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 0.859/1.724/2.590/0.866 ms
ubuntu@office-vm:~$ route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         host-10-10-10-1 0.0.0.0         UG    0      0        0 eth0
10.10.10.0      *               255.255.255.0   U     0      0        0 eth0
169.254.169.254 host-10-10-10-1 255.255.255.255 UGH   0      0        0 eth0
192.168.101.0   host-10-10-10-2 255.255.255.0   UG    0      0        0 eth0
ubuntu@office-vm:~$
(osclient) cloud@dev1:~$ ssh -i testkey [email protected]
Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-126-generic x86_64)

 * Documentation:  https://help.ubuntu.com/

  System information as of Tue Aug 22 10:02:35 UTC 2017

  System load:  0.0               Processes:           70
  Usage of /:   19.9% of 3.90GB   Users logged in:     0
  Memory usage: 5%                IP address for eth0: 10.10.10.100
  Swap usage:   0%

  Graph this data and manage this system at:
    https://landscape.canonical.com/

  Get cloud support with Ubuntu Advantage Cloud Guest:
    http://www.ubuntu.com/business/services/cloud

0 packages can be updated.
0 updates are security updates.


Last login: Tue Aug 22 10:02:35 2017 from 172.24.4.1
ubuntu@office-vm:~$ ssh -i testkey [email protected]
Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-126-generic x86_64)

 * Documentation:  https://help.ubuntu.com/

  System information as of Tue Aug 22 10:03:06 UTC 2017

  System load:  0.16              Processes:           70
  Usage of /:   19.9% of 3.90GB   Users logged in:     0
  Memory usage: 5%                IP address for eth0: 192.168.101.100
  Swap usage:   0%

  Graph this data and manage this system at:
    https://landscape.canonical.com/

  Get cloud support with Ubuntu Advantage Cloud Guest:
    http://www.ubuntu.com/business/services/cloud

0 packages can be updated.
0 updates are security updates.


Last login: Tue Aug 22 10:03:12 2017 from 10.10.10.100
ubuntu@lab-vm:~$ ping google.com
PING google.com (172.217.19.238) 56(84) bytes of data.
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=1 ttl=55 time=3.68 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=2 ttl=55 time=1.72 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=3 ttl=55 time=1.60 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=4 ttl=55 time=1.65 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=5 ttl=55 time=1.63 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=6 ttl=55 time=1.86 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=7 ttl=55 time=1.54 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=8 ttl=55 time=1.69 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=9 ttl=55 time=1.69 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=10 ttl=55 time=1.76 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=11 ttl=55 time=1.76 ms
64 bytes from par21s11-in-f14.1e100.net (172.217.19.238): icmp_seq=12 ttl=55 time=1.78 ms
^C
--- google.com ping statistics ---
12 packets transmitted, 12 received, 0% packet loss, time 11023ms
rtt min/avg/max/mdev = 1.540/1.867/3.685/0.556 ms
ubuntu@lab-vm:~$

results matching ""

    No results matching ""