bay-creation return 400 Bad Request with a valid fixed-network in baymodel
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Magnum |
In Progress
|
Undecided
|
HouMing Wang |
Bug Description
Reproduce steps:
1. Create a baymodel with a valid fixed network
[houming@bogon devstack]$ magnum baymodel-create --name swarmbaymodel --master-flavor-id m1.small --image-id fedora-21-atomic-5 --keypair-id testkey --fixed-network private --external-
+------
| Property | Value |
+------
| http_proxy | None |
| updated_at | None |
| master_flavor_id | m1.small |
| ssh_authorized_key | None |
| uuid | a0bee59e-
| no_proxy | None |
| https_proxy | None |
| tls_disabled | False |
| keypair_id | testkey |
| public | False |
| labels | {} |
| docker_volume_size | 5 |
| server_type | vm |
| external_network_id | public |
| cluster_distro | fedora-atomic |
| image_id | fedora-21-atomic-5 |
| registry_enabled | False |
| apiserver_port | None |
| name | swarmbaymodel |
| created_at | 2015-11-
| network_driver | flannel |
| fixed_network | private |
| coe | kubernetes |
| flavor_id | m1.small |
| dns_nameserver | 8.8.8.8 |
+------
2. Create a bay with this baymodel, 400 Bad Request returned:
[houming@bogon devstack]$ magnum bay-create --name swarmbay --baymodel swarmbaymodel --node-count 2
ERROR: Bad Request (HTTP 400)
We can see an "InvalidParamet
2015-11-25 18:18:19.216 TRACE oslo_messaging.
2015-11-25 18:18:19.216 TRACE oslo_messaging.
2015-11-25 18:18:19.216 TRACE oslo_messaging.
2015-11-25 18:18:19.216 TRACE oslo_messaging.
2015-11-25 18:18:19.216 ERROR oslo_messaging.
2015-11-25 18:18:19.216 ERROR oslo_messaging.
In magnum.
we should fix this to avoid bay-creation fails and misunderstanding.
Changed in magnum: | |
assignee: | nobody → Hou Ming Wang (houming-wang) |
description: | updated |
description: | updated |
After this change, /bugs.launchpad .net/magnum/ +bug/1450140 /review. openstack. org/#/c/ 178776/
https:/
https:/
The 'fixed_network' actually means 'fixed_ network_ cidr', or more precisely 'fixed_subnet'. There're 2 possible ways to fix this:
1. Rename the 'fixed_network' to 'fixed_subnet', in Baymodel DB, Baymodel Object and MagnumClient.
2. Leave 'fixed_network' alone, add a new field 'fixed_subnet' to Baymodel, and use the 'fixed_subnet' to take the place of current 'fixed_network'.