Ask Your Question
0

how to test LBaaS on VM instance

asked 2015-02-19 05:15:35 -0600

deepa gravatar image

updated 2015-02-23 15:20:05 -0600

smaffulli gravatar image

Hi,

I am new to openstack and trying to create two server and one client instance for lbaas testing using juno installation guide on fedora 20 . Below is my server and client detail.

[root@controller ~]# nova list
+--------------------------------------+----------------+--------+------------+-------------+-----------------------+
| ID                                   | Name           | Status | Task State | Power State | Networks              |
+--------------------------------------+----------------+--------+------------+-------------+-----------------------+
| e3835e48-29bb-487a-a0be-1057f8404b4d | demo-instance1 | ACTIVE | -          | Running     | demo-net=192.168.1.9  |
| 4a123ae1-dc48-422e-83df-f12da082d9ee | server1        | ACTIVE | -          | Running     | demo-net=192.168.1.10 |
| 53a051e5-614f-45bd-abaf-91d5a9228e90 | server2        | ACTIVE | -          | Running     | demo-net=192.168.1.11 |
+--------------------------------------+----------------+--------+------------+-------------+-----------------------+

After installing openstack using juno guide, I have referred the below link to run lbaas https://wiki.openstack.org/wiki/Neutr...

Accordingly I tried to start webserver on server1 and server2 on its VNC session using below command

On VNC server1 session:

while true; do echo -e 'HTTP/1.0 200 OK\r\n\r\nserver1' | sudo nc -l -p 80 ; done

On VNC server2 session:

while true; do echo -e 'HTTP/1.0 200 OK\r\n\r\nserver1' | sudo nc -l -p 80 ; done

Please let me know if above command is correct or not to start a webserver because I found that ever after starting webserver pool member health monitoring got failed .

[root@controller ~]# neutron lb-member-list 
+--------------------------------------+--------------+---------------+--------+----------------+----------+
| id                                   | address      | protocol_port | weight | admin_state_up | status   |
+--------------------------------------+--------------+---------------+--------+----------------+----------+
| 724c64d9-a829-4413-9102-a11d4d45b831 | 192.168.1.11 |            80 |      1 | True           | INACTIVE |
| 94276426-d147-4898-a18a-1a885b852be2 | 192.168.1.10 |            80 |      1 | True           | INACTIVE |
+--------------------------------------+--------------+---------------+--------+----------------+----------+

Question 2: Below is the health monitor detail

[root@controller ~]# neutron lb-healthmonitor-list 
+--------------------------------------+------+----------------+
| id                                   | type | admin_state_up |
+--------------------------------------+------+----------------+
| 91ec5d75-7424-4b55-b9cf-4ed058469f81 | HTTP | True           |
+--------------------------------------+------+----------------+
[root@controller ~]# neutron lb-healthmonitor-show 91ec5d75-7424-4b55-b9cf-4ed058469f81
+----------------+-----------------------------------------------------------------------------------------------------+
| Field          | Value                                                                                               |
+----------------+-----------------------------------------------------------------------------------------------------+
| admin_state_up | True                                                                                                |
| delay          | 3                                                                                                   |
| expected_codes | 200                                                                                                 |
| http_method    | GET                                                                                                 |
| id             | 91ec5d75-7424-4b55-b9cf-4ed058469f81                                                                |
| max_retries    | 3                                                                                                   |
| pools          | {"status": "ACTIVE", "status_description": null, "pool_id": "8b47f06a-ec53-4c42-9575-dfd0541333b9"} |
| tenant_id      | 3170cbf17a734c97a968aef04e32f463                                                                    |
| timeout        | 3                                                                                                   |
| type           | HTTP                                                                                                |
| url_path       | /                                                                                                   |
+----------------+-----------------------------------------------------------------------------------------------------+

server1 on both sever is just typo here but I have started with proper server name. Today I just restarted webserver on VM VNC server1 using the below command :

 while true; do echo -e 'HTTP/1.0 200 OK\r\n\r\nserver1' | sudo nc -l -p 80 ;

After this I tried to verify the webserver1 by sending request from network node as mentioned below and it failed.

 #wget -O - http://192.168.1.10 (server1 fixed IP)
--2015-02-23 20:48:59-- http://192.168.1.10/ 
Connecting to 192.168.1.10:80... failed: No route to host.
# wget -O - http://192.168.1.13 (VIP fixed IP)
--2015-02-23 21:09:05--  http://192.168.1.13/
Connecting to 192.168.1.13:80... failed: No route to host.

I have few more doubt on my validation step mentioned above :

  1. Do I need to send HTTP request to floation IP associated with server1 or fixed IP of server1 ? -I have tried with fixed IP
  2. Do I need to make any change in http config file running at network node ?

Later I tired to associate floating IP 10.130.98.240 to server1 then send HTTP request but still no luck

wget -O - http://10.130.98.240
--2015-02-23 21:18:29--  http://10.130.98.240/
Connecting to 10.130.98.240:80... failed: Connection timed out.
Retrying.

--2015-02-23 21:20:37--  (try ...
(more)
edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
1

answered 2015-02-23 04:42:20 -0600

deepa gravatar image

updated 2015-02-23 15:16:28 -0600

smaffulli gravatar image

After adding the below rule :

neutron security-group-rule-create --protocol tcp --port-range-min 80 --port-range-max 80 --direction ingress default

I am succefully able to test lbass and health monitoring.

edit flag offensive delete link more
0

answered 2015-02-19 10:02:34 -0600

You've got both servers returning 'server1' as part of the webserver startup command, but I don't think that's related.

Do the servers actually listen - do the following commands work?

wget -O - http://<server1-ip> 
wget -O - http://<server2-ip>

What about the LB IP itself?

wget -O - http://<vip-ip>

...and finally, what about the LB itself? Run 'lb-healthmonitor-list', and 'lb-healthmonitor-show <healthmonitor-id> to get a bit more info.

edit flag offensive delete link more

Comments

Hi, Thanks for response . Please check validation steps and few more doubt which I have tagged as "question 2" in detail section Regards, Deepa

deepa gravatar imagedeepa ( 2015-02-23 01:11:16 -0600 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2015-02-19 05:15:35 -0600

Seen: 455 times

Last updated: Feb 23 '15