-1

When a VM offering a service is migrated to a different server is it an important requirement from the client applications point of view to retain the same IP the VM had before ?

For long lived TCP sessions it won't make a difference because the connection will be reset anyway. But with web based services typically the TCP sessions are not long lived. So the VM retaining the IP on a migration can significantly reduce the downtime for client applications.

Manohar
  • 229
  • 4
  • 10
  • Your question is collecting downvotes due to the fact that apparently (based on comments below) you are interested in completely different information than you asked about in your question above. I would suggest that you do two things: First, accept one of the below answers, as they both answer your question. Second, post another question with detailed information on what you are **actually** wondering about. – EEAA Dec 03 '15 at 23:08
  • I accepted your answer. I should have worded the question differently because what I wanted to know mainly was how important the IP stability is from application point of view. – Manohar Dec 03 '15 at 23:16
  • If that's your question, don't bother asking it again, as it's far too broad. If you can identify **specific** protocols, then perhaps it could turn into a worthwhile question, but even then, the best answer will likely be: "well, go test it yourself with *your* clients and *your* load to see how things behave". – EEAA Dec 03 '15 at 23:18

2 Answers2

3

Since you tagged the question with , I presume you're referring to VMware's VMotion live migration.

With VMotion, you do not need to worry about this - all network sessions will remain valid throughout the migration.

EEAA
  • 108,414
  • 18
  • 172
  • 242
  • No, I am not particularly interested in VMware. My intent is to understand how important it is for the clients that the service's IP doesn't change. – Manohar Dec 03 '15 at 22:36
  • That is far too broad for any of us to proffer an answer. It depends completely on what protocol your clients are using and what (if any) detection/retry/recovery mechanisms the clients have. – EEAA Dec 03 '15 at 22:38
  • I understand its hard to answer this without the application specifics. In the case of Vmotion do you know if the TCP sessions are also maintained across a migration ? – Manohar Dec 03 '15 at 22:52
  • I've already answered that above. Did you read my answer? – EEAA Dec 03 '15 at 22:53
2

A VM migration from one host to another won't change the ip address of the VM. The ip address is a VM OS level setting as is unrelated to which host the VM resides on, whether that VM migrates between hosts or not.

joeqwerty
  • 108,377
  • 6
  • 80
  • 171
  • IP address need not be a VM OS level setting. It could be from a DHCP server. So a higher level entity like a VM management software is involved typically to make sure the IP doesn't change. – Manohar Dec 03 '15 at 22:40
  • 1
    @Santhosh I have no idea what you're talking about. It does not matter if an IP address is assigned via DHCP or assigned manually. The IP does not change during migration. VM mac addresses move with the VMs from host to host, so in the case of DHCP, the lease will travel with the VM. – EEAA Dec 03 '15 at 22:42
  • To address your nebulous "VM management software" comment - none of the VM management software I've ever worked with (VMware, Hyper-V, XenServer, KVM) has anything to do with IP addressing. They operate at a completely different level and do not care what IP their VM guests have. – EEAA Dec 03 '15 at 22:44
  • Even if the ip address changes as a result of some DHCP wonkiness, that's not a function of the host server or the host management software. – joeqwerty Dec 03 '15 at 22:46
  • Probably the DHCP wasn't a right example. Correct me if I am wrong here, In the case of KVM, for VM migration libvirt does some work behind the scenes to make sure the UUIDs of the interface remain the same after the migration. My understanding is this helps the software like Nexus 1000v or Nuage to assign the same interface policies and config (which includes IP as well) – Manohar Dec 03 '15 at 22:48
  • Well, we're slicing a different loaf of bread now. Your original question was tagged as VMware-esxi and you asked what happens to the ip address of a VM when it migrates from one host to another. Maybe you should reword and retag your question to account for this new wrinkle. What specifically are you asking? – joeqwerty Dec 03 '15 at 22:54
  • Tagging vmware-esxi was a mistake. I removed it. And my previous comment about libvirt was just to clarify that retaining the same IP could depend on features provided by the management/orchestration software. Bottom line, what I was trying to understand was how important is it that the service's IP remain the same from an application point of view. – Manohar Dec 03 '15 at 23:10