• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1045
  • Last Modified:

Disable networking for suspended VM before starting it

Hello,

I have a SCO OpenServer 5.0.7 server running as a guest OS under VMware Server 1.0.10.  There are no vmware-tools for SCO 5 (except for the "V versions," which I do not have).  The host system is running CentOS 5.4

Every night, I have a perl script that suspends the VM and copies the VM files to a backup / test server and then starts up the VM again on the live server.

The problem is that I need a way to start up the suspended VM on the backup / test server without interfering with the live server.  Since they both have the same IP address, I cannot just start up the VM on the backup server, and, since the VM is suspended, I cannot change from Bridged to Host-only networking.

I am considering using IPTables on the host to accomplish this by blocking all in- and outgoing traffic to the IP of the VM, but I am not sure if this will prevent the VM from responding to ARP requests, etc.  

Preferably, I would like to turn off all networking for the VM  using vmware-cmd or similar, but I am not very knowledgeable in VMware.

Any help on this would be greatly appreciated.

Thanks,
Lars
0
Lars007
Asked:
Lars007
  • 6
  • 2
1 Solution
 
TolomirAdministratorCommented:
take a look at this:

Clone Virtual Machine with VMware Server 2.0
http://communities.vmware.com/message/1311110#1311110
0
 
TolomirAdministratorCommented:
so basically you clone the machine to make sure you don't have 2 virtual machines with the same id.

of cause you have to change the ip, dns name etc. But this is nothing vmware related.
0
 
TolomirAdministratorCommented:
since you clone the machine you CAN change the network to host only.
0
Improve Your Query Performance Tuning

In this FREE six-day email course, you'll learn from Janis Griffin, Database Performance Evangelist. She'll teach 12 steps that you can use to optimize your queries as much as possible and see measurable results in your work. Get started today!

 
TolomirAdministratorCommented:
you cannot change network settings for a suspended machine, it's like changing the motor in a driving car (while the driver sleeps ;-)
0
 
Lars007Author Commented:
Tolomir,

I looked at the post you referred to, but it did not answer my question.  

Obviously I would have to change the IP, etc. of the VM to use it on the network, but since there are no vmware tools for SCO, there is no way to automate this.  And the moment I start the VM on the backup host, I will have an IP conflict before I have a chance to change the IP.

The backup itself is working great.  All that remains is to solve this last issue of starting up the suspended VM without network access.  It may or may not be doable within VMware - it might have to be done via IPTables or similar.  Basically, I would like to "pull the virtual network cable" on the VM before starting it up.  This means I will only be able to run it via the VMware Server Console or similar, but this is ok.

Again, help on this would be appreciated.

Lars

0
 
TolomirAdministratorCommented:
ok check the vmx file of the backup.

scroll down to:

# First network interface card
ethernet0.present = "TRUE"
ethernet0.virtualDev = "vlance"
ethernet0.connectionType = "nat"
ethernet0.addressType = "generated"
ethernet0.generatedAddressOffset = "0"

---

change

ethernet0.present = "FALSE"

---

this should unplug the network cable.
0
 
TolomirAdministratorCommented:
safe the file and bootup the suspended machine.
0
 
Lars007Author Commented:
Tolomir,

That did it!  And it can easily be scripted as a find and replace.

Thanks for your help,
Lars
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

  • 6
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now