Ask Your Question
0

How can I change instance's fixed ip

asked 2015-02-10 21:52:17 -0500

Getter gravatar image

Hello everyone, I user nova-network to boot an instanace. After instance state is active , I login and change it's nic setting, when I have done network doesn't work.

For example, I use nova-network create 192.168.0.0/24, instance get ip 192.168.0.2 by DHCP instance network setting in /etc/network/interface is iface eth0 inet dhcp

I change to this

iface eth0 inet static address 192.168.0.3 netmask 255.255.255.0 gateway 192.168.0.1

Can anybody help me! Thank's a lot!

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
0

answered 2015-02-11 03:26:53 -0500

Getter gravatar image

updated 2015-02-11 03:27:47 -0500

this pic is after I killall iptable's rule ""http://ppt.cc/ea7P"" this pic is after I restart compute node and restart service is same ""http://ppt.cc/DrRq""

98.57 is my compute node br200's IP. 98.58 is my instance's IP got by DHCP. I have login instance and manually change to 98.59 ""http://ppt.cc/LUCK""

edit flag offensive delete link more
0

answered 2015-02-11 01:49:52 -0500

jtaguinerd gravatar image

Hi,

If you have manually changed the IP you need to kill all the running iptables from the compute node and then start the service again. From the dashboard if you want the new IP to be displayed you can manually update the mysql table reflect the IP you have assigned.

Cheers!

edit flag offensive delete link more

Comments

HI, I have killed all iptables and restarted nova-network service, but instance's network still not working.

Getter gravatar imageGetter ( 2015-02-11 02:06:32 -0500 )edit

Make sure that there was no child process when you killed iptables and dnsmasq. To be sure you can just try to restart the entire node.

jtaguinerd gravatar imagejtaguinerd ( 2015-02-11 02:10:42 -0500 )edit

HI, I compare iptable's rules and there is no different after I restarted it. Would you tell me which rule should I edit?

Getter gravatar imageGetter ( 2015-02-11 02:39:57 -0500 )edit

Restarted the service? or restarted the node? can you just post here the result of iptables -L please.

jtaguinerd gravatar imagejtaguinerd ( 2015-02-11 03:01:59 -0500 )edit

this pic is after I killall iptable's rule http://ppt.cc/ea7P (pic1) this pic is after I restart compute node and restart service is same http://ppt.cc/DrRq (pic2)

98.57 is my compute node br200's IP. 98.58 is my instance's IP got by DHCP. I have login instance and manually change to 98.59

Getter gravatar imageGetter ( 2015-02-11 03:21:55 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2015-02-10 21:52:17 -0500

Seen: 1,407 times

Last updated: Feb 11 '15