Ceph subnet_range calculation improvement
Gate scripts are trying to calculate the SUBNET_RANGE basing on IP address of default interface. There is ipcalc tool used. The issue is that based on infra datacenter selected to run the VM gate, the default interface can have address with /32 network. If IP has /32 network, the ipcalc would not calculate the network address, for example 192.168.0.0/24, which is needed for ceph to be configured. As a workaround, try to change the /32 to /24 after getting the IP of the default interface, and then calculate the network address. Change-Id: Ia2858c6a2b4c56fbc42ef06b5f157625a56beb3c
This commit is contained in:
parent
ecdf097885
commit
ece78c448d
@ -17,7 +17,7 @@ function net_default_iface {
|
||||
}
|
||||
|
||||
function net_default_host_addr {
|
||||
sudo ip addr | awk "/inet / && /$(net_default_iface)/{print \$2; exit }"
|
||||
sudo ip addr | awk "/inet / && /$(net_default_iface)/{print \$2; exit }" | sed 's/\/32/\/24/'
|
||||
}
|
||||
|
||||
function net_default_host_ip {
|
||||
|
Loading…
x
Reference in New Issue
Block a user