Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
4.3.0
-
Security Level: Public (Anyone can view this level - this is the default.)
-
Latest build from 4.3 branch with commit: 6f309b8a87d3376950a60234d399c6e3749ad1c7
Description
[Hyper-v] Nic hot plug-in does not happen if public IP is acquired from different vlan
Steps to reproduce:
================
1.Bring up CS in advanced zone with hyper-v cluster
2.Create isolated guest network and deploy few vms in the network
3.Exhaust all the public IP addresses present in the zone (in user_ip_address table set the allocated=now())
4.Add new public IP range in new vlan and new subnet
5.Acquire one ip address from the new ip range and configure PF and assign one vm deployed at step2
Expected Result:
=============
since the IP address acquired at step5 is from different vlan nic hot plug-in should happen on the VR and the acquired ip address should be configured on this new nic
Actual Result:
===========
Nic hot plug-in does not happen and the acquired ip is configured on the existing public interface which is eth2 on VR.
Following is the "ip addr show" command output from VR:
root@r-4-VM:~# ip addr show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 02:00:67:79:00:02 brd ff:ff:ff:ff:ff:ff
inet 10.1.1.1/24 brd 10.1.1.255 scope global eth0
inet6 fe80::67ff:fe79:2/64 scope link
valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 02:00:57:ab:00:05 brd ff:ff:ff:ff:ff:ff
inet 10.147.40.230/23 brd 10.147.41.255 scope global eth1
inet6 fe80::57ff:feab:5/64 scope link
valid_lft forever preferred_lft forever
4: eth2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 06:78:3c:00:00:17 brd ff:ff:ff:ff:ff:ff
inet 10.147.48.5/24 brd 10.147.48.255 scope global eth2
inet 10.147.31.240/24 brd 10.147.31.255 scope global eth2
inet6 fe80::478:3cff:fe00:17/64 scope link
valid_lft forever preferred_lft forever
Log snippet from MS log :
====================
2014-01-07 11:29:36,252 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (catalina-exec-10:ctx-c9945336 ctx-4a2f8773) submit async job-62, details: AsyncJobVO {id:62, userId: 2, accountId: 2, instanceType: IpAddress, instanceId: 19, cmd: org.apache.cloudstack.api.command.user.address.AssociateIPAddrCmd, cmdInfo:
, cmdVersion: 0, status: IN_PROGRESS, processStatus: 0, resultCode: 0, result: null, initMsid: 132129494109518, completeMsid: null, lastUpdated: null, lastPolled: null, created: null}
2014-01-07 11:29:36,253 INFO [o.a.c.f.j.i.AsyncJobMonitor] (Job-Executor-30:ctx-17a9f9c9) Add job-62 into job monitoring
2014-01-07 11:29:36,253 DEBUG [c.c.a.ApiServlet] (catalina-exec-10:ctx-c9945336 ctx-4a2f8773) ===END=== 10.146.0.133 – GET command=associateIpAddress&response=json&sessionkey=Yc2RY308FJ0FALdFfefofIWKnKY%3D&networkid=d2b7326e-99f9-453e-9535-f6982da49e2f&_=1389074372490
2014-01-07 11:29:36,256 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-30:ctx-17a9f9c9) Executing AsyncJobVO {id:62, userId: 2, accountId: 2, instanceType: IpAddress, instanceId: 19, cmd: org.apache.cloudstack.api.command.user.address.AssociateIPAddrCmd, cmdInfo:
, cmdVersion: 0, status: IN_PROGRESS, processStatus: 0, resultCode: 0, result: null, initMsid: 132129494109518, completeMsid: null, lastUpdated: null, lastPolled: null, created: null}
2014-01-07 11:29:36,335 DEBUG [c.c.n.IpAddressManagerImpl] (Job-Executor-30:ctx-17a9f9c9 ctx-4a2f8773) Associating ip Ip[10.147.31.240-1] to network Ntwk[204|Guest|8]
2014-01-07 11:29:36,441 DEBUG [c.c.n.IpAddressManagerImpl] (Job-Executor-30:ctx-17a9f9c9 ctx-4a2f8773) Successfully associated ip address 10.147.31.240 to network Ntwk[204|Guest|8]
2014-01-07 11:29:36,507 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-30:ctx-17a9f9c9 ctx-4a2f8773) Complete async job-62, jobStatus: SUCCEEDED, resultCode: 0, result: org.apache.cloudstack.api.response.IPAddressResponse/ipaddress/
2014-01-07 11:29:36,575 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-30:ctx-17a9f9c9) Done executing org.apache.cloudstack.api.command.user.address.AssociateIPAddrCmd for job-62
2014-01-07 11:29:36,608 INFO [o.a.c.f.j.i.AsyncJobMonitor] (Job-Executor-30:ctx-17a9f9c9) Remove job-62 from job monitoring
2014-01-07 11:30:38,773 DEBUG [c.c.a.ApiServlet] (catalina-exec-18:ctx-01cf46a4) ===START=== 10.146.0.133 – GET command=createPortForwardingRule&response=json&sessionkey=Yc2RY308FJ0FALdFfefofIWKnKY%3D&ipaddressid=76cab7f0-a385-44f1-ab93-dadbaea8caa9&privateport=22&privateendport=22&publicport=22&publicendport=22&protocol=tcp&virtualmachineid=a97f69e2-f745-4dc7-b16c-eebfd2595186&openfirewall=false&networkid=d2b7326e-99f9-453e-9535-f6982da49e2f&_=1389074435292
2014-01-07 11:30:38,801 DEBUG [c.c.n.f.FirewallManagerImpl] (catalina-exec-18:ctx-01cf46a4 ctx-d423299a) No network rule conflicts detected for Rule[6-PortForwarding-Staged] against 0 existing rules
2014-01-07 11:30:39,141 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (catalina-exec-18:ctx-01cf46a4 ctx-d423299a) submit async job-63, details: AsyncJobVO {id:63, userId: 2, accountId: 2, instanceType: FirewallRule, instanceId: 6, cmd: org.apache.cloudstack.api.command.user.firewall.CreatePortForwardingRuleCmd, cmdInfo:
, cmdVersion: 0, status: IN_PROGRESS, processStatus: 0, resultCode: 0, result: null, initMsid: 132129494109518, completeMsid: null, lastUpdated: null, lastPolled: null, created: null}
2014-01-07 11:30:39,142 INFO [o.a.c.f.j.i.AsyncJobMonitor] (Job-Executor-31:ctx-26e587af) Add job-63 into job monitoring
2014-01-07 11:30:39,142 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-31:ctx-26e587af) Executing AsyncJobVO {id:63, userId: 2, accountId: 2, instanceType: FirewallRule, instanceId: 6, cmd: org.apache.cloudstack.api.command.user.firewall.CreatePortForwardingRuleCmd, cmdInfo:
, cmdVersion: 0, status: IN_PROGRESS, processStatus: 0, resultCode: 0, result: null, initMsid: 132129494109518, completeMsid: null, lastUpdated: null, lastPolled: null, created: null}
2014-01-07 11:30:39,142 DEBUG [c.c.a.ApiServlet] (catalina-exec-18:ctx-01cf46a4 ctx-d423299a) ===END=== 10.146.0.133 – GET command=createPortForwardingRule&response=json&sessionkey=Yc2RY308FJ0FALdFfefofIWKnKY%3D&ipaddressid=76cab7f0-a385-44f1-ab93-dadbaea8caa9&privateport=22&privateendport=22&publicport=22&publicendport=22&protocol=tcp&virtualmachineid=a97f69e2-f745-4dc7-b16c-eebfd2595186&openfirewall=false&networkid=d2b7326e-99f9-453e-9535-f6982da49e2f&_=1389074435292
2014-01-07 11:30:39,250 DEBUG [c.c.n.r.VirtualNetworkApplianceManagerImpl] (Job-Executor-31:ctx-26e587af ctx-d423299a) Applying ip association in network Ntwk[204|Guest|8]
2014-01-07 11:30:39,274 DEBUG [c.c.a.t.Request] (Job-Executor-31:ctx-26e587af ctx-d423299a) Seq 4-2034961238: Sending { Cmd , MgmtId: 132129494109518, via: 4(10.147.40.31), Ver: v1, Flags: 100001, [{"com.cloud.agent.api.routing.IpAssocCommand":{"ipAddresses":[
],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"wait":0}},{"com.cloud.agent.api.routing.IpAssocCommand":{"ipAddresses":[
{"accountId":2,"publicIp":"10.147.31.240","sourceNat":true,"add":true,"oneToOneNat":false,"firstIP":true,"broadcastUri":"vlan://31","vlanGateway":"10.147.31.1","vlanNetmask":"255.255.255.0","vifMacAddress":"06:78:3e:00:00:17","networkRate":200,"trafficType":"Public"}],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"wait":0}}] }
2014-01-07 11:30:39,275 INFO [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Executing resource IPAssocCommand: {"ipAddresses":[
],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"contextMap":{},"wait":0}
2014-01-07 11:30:39,275 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Use router's private IP for SSH control. IP : 10.147.40.230
2014-01-07 11:30:39,275 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Plug new NIC to associate10.147.40.230 to 10.147.48.5
2014-01-07 11:30:39,276 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Run command on domain router 10.147.40.230, /opt/cloud/bin/ipassoc.sh -A -s -f -l 10.147.48.5/24 -c eth2 -g 10.147.48.1 -n
2014-01-07 11:30:39,330 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-1:null) SeqA 2-9842: Processing Seq 2-9842: { Cmd , MgmtId: -1, via: 2, Ver: v1, Flags: 11, [{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":1,"_loadInfo":"
","wait":0}}] }
2014-01-07 11:30:39,406 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-1:null) SeqA 2-9842: Sending Seq 2-9842: { Ans: , MgmtId: 132129494109518, via: 2, Ver: v1, Flags: 100010, [{"com.cloud.agent.api.AgentControlAnswer":{"result":true,"wait":0}}] }
2014-01-07 11:30:39,606 INFO [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) ipassoc command on domain router 10.147.40.230 completed
2014-01-07 11:30:39,608 INFO [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Executing resource IPAssocCommand: {"ipAddresses":[
],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"contextMap":{},"wait":0}
2014-01-07 11:30:39,608 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Use router's private IP for SSH control. IP : 10.147.40.230
2014-01-07 11:30:39,608 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Plug new NIC to associate10.147.40.230 to 10.147.31.240
2014-01-07 11:30:39,608 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) Run command on domain router 10.147.40.230, /opt/cloud/bin/ipassoc.sh -A -s -f -l 10.147.31.240/24 -c eth2 -g 10.147.31.1 -n
2014-01-07 11:30:39,963 INFO [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-135:ctx-f2f40e07) ipassoc command on domain router 10.147.40.230 completed
2014-01-07 11:30:39,964 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-135:ctx-f2f40e07) Seq 4-2034961238: Response Received:
2014-01-07 11:30:39,965 DEBUG [c.c.a.t.Request] (DirectAgent-135:ctx-f2f40e07) Seq 4-2034961238: Processing: { Ans: , MgmtId: 132129494109518, via: 4, Ver: v1, Flags: 0, [{"com.cloud.agent.api.routing.IpAssocAnswer":{"results":["10.147.48.5 - success"],"result":true,"wait":0}},{"com.cloud.agent.api.routing.IpAssocAnswer":{"results":["10.147.31.240 - success"],"result":true,"wait":0}}] }
2014-01-07 11:30:39,965 DEBUG [c.c.a.t.Request] (Job-Executor-31:ctx-26e587af ctx-d423299a) Seq 4-2034961238: Received: { Ans: , MgmtId: 132129494109518, via: 4, Ver: v1, Flags: 0,
}
2014-01-07 11:30:39,971 DEBUG [c.c.n.r.VirtualNetworkApplianceManagerImpl] (Job-Executor-31:ctx-26e587af ctx-d423299a) Applying firewall rules in network Ntwk[204|Guest|8]
2014-01-07 11:30:39,977 DEBUG [c.c.a.t.Request] (Job-Executor-31:ctx-26e587af ctx-d423299a) Seq 4-2034961239: Sending { Cmd , MgmtId: 132129494109518, via: 4(10.147.40.31), Ver: v1, Flags: 100001, [{"com.cloud.agent.api.routing.SetPortForwardingRulesCommand":{"rules":[
],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"wait":0}}] }
2014-01-07 11:30:39,978 DEBUG [c.c.a.t.Request] (Job-Executor-31:ctx-26e587af ctx-d423299a) Seq 4-2034961239: Executing: { Cmd , MgmtId: 132129494109518, via: 4(10.147.40.31), Ver: v1, Flags: 100001, [{"com.cloud.agent.api.routing.SetPortForwardingRulesCommand":{"rules":[
],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"wait":0}}] }
2014-01-07 11:30:39,978 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-134:ctx-ad1d536b) Seq 4-2034961239: Executing request
2014-01-07 11:30:39,978 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-134:ctx-ad1d536b) Seq 4-2034961239: Executing request
2014-01-07 11:30:39,978 INFO [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-134:ctx-ad1d536b) Executing resource SetPortForwardingRulesCommand: {"rules":[
],"accessDetails":
{"router.guest.ip":"10.1.1.1","zone.network.type":"Advanced","router.ip":"10.147.40.230","router.name":"r-4-VM"},"contextMap":{},"wait":0}
2014-01-07 11:30:39,978 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-134:ctx-ad1d536b) Use router's private IP for SSH control. IP : 10.147.40.230
2014-01-07 11:30:40,333 DEBUG [c.c.h.h.r.HypervDirectConnectResource] (DirectAgent-134:ctx-ad1d536b) Executing script on domain router 10.147.40.230: /root/firewall.sh -A -P tcp -l 10.147.31.240 -p 22:22 -r 10.1.1.26 -d 22:22
2014-01-07 11:30:40,333 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-134:ctx-ad1d536b) Seq 4-2034961239: Response Received:
2014-01-07 11:30:40,334 DEBUG [c.c.a.t.Request] (DirectAgent-134:ctx-ad1d536b) Seq 4-2034961239: Processing: { Ans: , MgmtId: 132129494109518, via: 4, Ver: v1, Flags: 0, [{"com.cloud.agent.api.routing.SetPortForwardingRulesAnswer":{"results":[null],"result":true,"wait":0}}] }
2014-01-07 11:30:40,334 DEBUG [c.c.a.t.Request] (Job-Executor-31:ctx-26e587af ctx-d423299a) Seq 4-2034961239: Received: { Ans: , MgmtId: 132129494109518, via: 4, Ver: v1, Flags: 0,
}
2014-01-07 11:30:40,488 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-31:ctx-26e587af ctx-d423299a) Complete async job-63, jobStatus: SUCCEEDED, resultCode: 0, result: org.apache.cloudstack.api.response.FirewallRuleResponse/portforwardingrule/
2014-01-07 11:30:40,539 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-31:ctx-26e587af) Done executing org.apache.cloudstack.api.command.user.firewall.CreatePortForwardingRuleCmd for job-63
2014-01-07 11:30:40,564 INFO [o.a.c.f.j.i.AsyncJobMonitor] (Job-Executor-31:ctx-26e587af) Remove job-63 from job monitoring
Attachments
Attachments
Issue Links
- duplicates
-
CLOUDSTACK-5561 support of multiple nics for VR running in HyperV
- Resolved