> > On 19-Dec-2013, at 3:58 PM, Andrei Mikhailovsky<andrei@...> wrote: > > > > Do you know if there is an easier way? Like via the api calls or the cloudmonkey command? Or is it currently > the only way? > > > > ----- Original Message ----- > > From: "Jayapal Reddy Uradi"<jayapalreddy.uradi@...> To: > "<users@...> > "<users@...> Sent: Thursday, 19 December, 2013 > 9:25:05 AM > > Subject: Re: Change of guest IP address > > > > Hi, > > > > If your VM is in isolated network please do the following > > > > 1. edit the nics table ip4_address column for your instance_id to new ip. > > 2. login to the router corresponds to the network and replace old ip with new ip in below files. > > > > a. /var/lib/misc/dnsmasq.leases > > b. /etc/dhcphosts.txt > > 3. restart the dnsmasq in router (service dnsmasq restart) 4. Reboot > > the VM or restart the network service in Vm so that VM gets the new ip from the dhcp. > > > > Thanks, > > Jayapal
I put Jayapal's solution into a script for convenience: http://pastebin.com/7yJtjNQX Just edit the first group of variables according to your needs and run it like this: set-vm-ip.sh old-address new-address