Web-UI creates all isolated Nets with IP range 10.1.1.0/24
ISSUE TYPE
- Bug Report
COMPONENT NAME
UI
CLOUDSTACK VERSION
4.11.0.0
CONFIGURATION
OS / ENVIRONMENT
SUMMARY
After upgrading to 4.11 we have the issue, that isolated nets created with the web-UI are always created for the IP range 10.1.1.0/24 - no matter what values are filled in the fields "Guest Gateway" and "Guest Netmask".
Creating an isolated network with CloudMonkey works perfectly using the syntax:
create network displaytext=deleteme-cloudmonkey name=deleteme-cloudmonkey networkofferingid=
Paul Angus confirmed on [email protected]:
Yes looks like a UI bug. I tried through the UI with the browser in developer mode to see what was sent. The guest netmask is missing.http://192.168.56.11:8080/client/api?command=createNetwork&response=json&zoneId=6d0ebc4e-1f70-4a87-b29b-cb98f9ab9594&name=test_net&displayText=test-sourcenat&networkOfferingId=e6425385-e5d2-457a-b3df-4845b9e79edc&gateway=10.0.0.1&_=1522849857187
STEPS TO REPRODUCE
Login to web-UI with DomainAdmin User.
Create new isolated network.
Specifiy
"Guest Gateway" other than 10.1.1.1 or
"Guest Netmask" other than 24
EXPECTED RESULTS
Have the "Guest Gateway" and "Guest Netmask" configured according to the values entered.
ACTUAL RESULTS
The network is created for guest IP range 10.1.1.1/24 no matter what values where entered for "Guest Gateway" and "Guest Netmask".
@sgoeminn
in commit 26759d1d139b52b8adfd8adba7809e32091423b5
you seem to have changed the network.js such that guestGateway appears twice and guestNetmask has been removed. https://github.com/apache/cloudstack/blob/master/ui/scripts/network.js#L730-L739
As this relates to your externalID, i haven't simply reverted it. Please could you look into it & also add the 'ui hint' (docID) to explain what External ID is for, it's a quite random field for most people.
@sgoeminn I fixed the c&p error but @PaulAngus still has a point about documentation. see #2534
reapplied for 4.11 in #2536
@DaanHoogland I have another issue for isolated networks created through the web-UI. Can you decide if that is a new ticket, of if it is fixed with this issue?
It is not possible to add a NIC on an isolated network created through the web-UI I. I receive an exception:
com.cloud.utils.exception.CloudRuntimeException: Insufficient capacity when adding NIC to VM[User|i-157-2357-VM]: com.cloud.exception.InsufficientAddressCapacityException: Insufficient address capacityScope=interface com.cloud.dc.DataCenter; id=1
For networks created with CloudMonkey and with explicit declaration of "gateway" and "netmask" adding NICs is working.
create network displaytext=testnet name=testnet networkofferingid=
@mdesaive I am not sure if I fully understand this second issue. It seems you are only adding a NIC in the UI and then comparing it with adding a network with cloudmonkey. It may well be related but I can't tell from your description. My guess is that it is a consequential error, due to the limited address space given to a network created through the UI, especially if a previous network had the same CIDR and the NIC is created on a VM connected to that previous network. (hope I make more sense to you than to myself)