openstack team mailing list archive
-
openstack team
-
Mailing list archive
-
Message #19760
Re: boot multi instances at a time issue
-
To:
openstack@xxxxxxxxxxxxxxxxxxx
-
From:
Jay Pipes <jaypipes@xxxxxxxxx>
-
Date:
Wed, 02 Jan 2013 11:15:45 -0500
-
In-reply-to:
<CAPP2CaW1vQjkhJR_bdjoBL13rYHKj2W6SD8ZD0Pvr4Z4uw=hTA@mail.gmail.com>
-
User-agent:
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0
On 01/02/2013 12:52 AM, heut2008 wrote:
> Hi,all
>
> When booting multi instances at a time , we face a hostname naming
> problem, now all instances will using the same hostname provideed at
> booting time,as a developer,I am looking for suggestions and
> requirements that from the user side, how do you want nova naming
> the hostname when booting multi instances?
> when provide a hostname at booting time ,is adding a number suffix ok?
> or more configurable naming is needed.
I believe the API should be modified to make suffix/templatized names
possible, as well as the ability to specify names as a list, with each
name in the list of names corresponding to a server.
Let's say I want to create 20 instances, with instances names
"instance-00" through "instance-19". Of course, there isn't any way to
do this right now, since the name parameter of the createServer call
sets the name the same for all instances. We could add a new parameter
called nameTemplate that would be filled in with some easy rules:
* Replace %(launch_id)d with the launch sequence. So, the third instance
booted with a nameTemplate of "instance-%(launch_id)d" would get the
name "instance-3"
* Replace %(image_name)s with the name of the image. For example, if the
nameTemplate was "%(image_name)s-%(launch_id)d" and the name of the
image was "UbuntuPrecise", then the third launched instance would be
named "UbuntuPrecise-3"
* Any other sensible rules one might want to give...
-jay
References