can i assign some special ip to the special VM?
for example, i have an unused ip <192.168.1.10-192.168.1.100>. but i do want to start some special VM that run specail task. such as
i want to run DHCP at 192.168.1.20, Mysql at 192.168.1.30, NTP at 192.168.1.40....and so on.
i have read the four network mode, but i dont know how to config like this.
can a image that just installed DHCP start with ip 192.168.1.20? and Mysql with 192.168.1.30....
SYSTEM and STATIC mode , i think they can't do this. because they are obtain there ip by DHCP. if i can control VM MAC, VM ip can be controlled by DHCP, but i suppose that VM MAC can be controled. am i right?
in Manage or MANAGE-NOVLAN mode, you can assign ip to VM, but i have to allocate address until i obtain 192.168.1.20, then i can assign it to VM which i want a apecial server DHCP, MYSQL or NTP run at.
can i allocate special ip??
or how to run VM at special ip??
thanks
thanks a lot for your answer!
i have not try this cmd. but if i want to use euca-assosicate-address, i must euca-allocate-address first. am i right??
if this is true, ip address obtained by cmd "euca-allocate-address" is not always what i want to assign to Mysql DHCP or NTP server
that means , i must "euca-allocate-address" many times util i obtain the ip address that i want to assign to server.
Hello,
it doesn't really work that way: you can get an IP address using allocate-address. After that you are in full control of that IP, which means that you can make that IP special (for example having a fixed DNS name etc...). I guess you could try the way you mentioned (keep allocating till you get the one you want then releasing them) but is a bit counterintuitive.
cheers
graziano
I am using a cloud for a dev group so that they can create machines and destroy them when they don't need them anymore. However a few of the VMs are meant to be for specific purposes (QA servers) where we want to set up a DNS entry for those IPs. However, I had to recently shut down the cloud to do some other stuff and when I brought it back up
I realized I could not easily allocate the address that I had already gotten the IT group to set up the DNS for without doing what wangdawei was suggesting. I am sure if I went under the covers and did the same thing that allocate does I could probably get that address more directly but it surprises me that there isn't an option to do this. I imagine this probably doesn't make much sense in the AWS environment but in my isolated environment it would be nice :)
jC
Hello jC,
development and testing is indeed one of the common use for the cloud. I'm a bit confused here: if you have elastic IP (that is if you are running in MANAGED or MANAGED-NOVLAN mode) you should be able to allocate an IP, and having it at your disposal for the entire life span of your cloud. Isn't that the case? That's how we do it for our own internal services: we allocated public IPs, put them into our DNS, then when we start the service we associate the right IP to it.
cheers
graziano
Well as is often the case I am probably the one confused. I had noticed (or maybe remember incorrectly) the case that if I reboot the whole cloud (this is a dev environment and while it doesn't occur often occasionally we do have to do it) all the addresses are released. So lets say I have an IP address range of 192.168.1.0/24. If over time I allocate
and address of 192.168.1.200 and assign a DNS entry to that. if I reboot the cloud (lets say we upgrade the HVAC and have to power everything off -- for example). When I bring the cloud up, I have to do a dummy allocation of all the addresses from 1 - 200, assign 200 to a VM and then free up 1-199. While this sounds a little contrived I think this is a valid scenario unless I am remembering wrong that the IPs are all freed up on the reboot. I don't want to try it now as we do have services running.
If what I said is true, it still might be a good idea to be able to just allocate a specific IP (.200) and assign it to a VM without having to go through the dummy allocations.
Hello,
you are correct, that's why there Elastic IP: you use the euca-allocate-address, euca-associate-addres, euca-disassociate-address and euca-release-address to work with them. In short, you allocate for yourself (your user that is) one or more elastic IP: they will stay with you until you release them. You can then associate them to a running instance, so you can 'attach' them to whatever instance you want. That is, if you reboot your cloud, you restart the instance carrying your service, then attach to it (associate) the elastic IP (which is fixed) and you are good to go.
Does this make sense?
cheers
graziano