[Users] [rhevm-api] Assign IP address to VM using Java SDK

Shahar Havivi shaharh at redhat.com
Tue Feb 18 14:55:10 UTC 2014


On 18.02.14 17:56, Tejesh M wrote:
> I want to assign random password for Administrator & IP address through
> API, as we did for Linux OS using Cloud-init.
You suppose to run it via the API as you run regular VM (start action) and set the values in
the body:
do a PUT method to:
http://[HOST]:[PORT]/api/vms/[VM-GUID]/start

The body of the method:
<action>
<vm>
 <domain>
    <user_name>.. </user_name>
    <password>... </password>
 </domain>
</vm>
</action>


This is suppose to be the equivalent to to RunOnce
For more fields and option look at the rsdl file:
http://[HOST]:[PORT]/api?rsdl

> 
> 
> On Tue, Feb 18, 2014 at 5:45 PM, Shahar Havivi <shaharh at redhat.com> wrote:
> 
> > On 18.02.14 17:27, Tejesh M wrote:
> > > Yes, I tried that, it asks for Domain Name and Username & Password for
> > that
> > > domain to join. But no option to reset the Admin password.
> > What do you mean by reset?
> > Do you want to have no admin password?
> >
> > >
> > >
> > > On Tue, Feb 18, 2014 at 5:20 PM, Shahar Havivi <shaharh at redhat.com>
> > wrote:
> > >
> > > > On 18.02.14 17:08, Tejesh M wrote:
> > > > > I tried sysprep through web admin, but it shows only Domain name and
> > > > > alternate username & password. There is no option to reset
> > Administrator
> > > > > Password.
> > > > Please try via the Run-Once,
> > > > You need to attach Floppy in "Boot Options" and set it to "[Sysprep]"
> > > > Then you will see the credentials under the "Initial Run".
> > > >
> > > > >
> > > > >
> > > > > On Tue, Feb 18, 2014 at 1:01 PM, Itamar Heim <iheim at redhat.com>
> > wrote:
> > > > >
> > > > > > On 02/18/2014 07:27 AM, Tejesh M wrote:
> > > > > >
> > > > > >> Oh did silly mistake.. didn't check above 8 characters. Its
> > working.
> > > > > >>
> > > > > >> I want to set Adminstrator Password for windows through API.
> > > > > >> does cloud-init supports windows sysprep? or I need to install
> > some
> > > > > >> other component?
> > > > > >>
> > > > > >
> > > > > > you can use windows sysprep, which ovirt supports.
> > > > > > but that's not cloud-init.
> > > > > > iirc, there is some cloud-init compatibility package for windows
> > > > > >
> > > > > >
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >> On Mon, Feb 17, 2014 at 7:42 PM, Shahar Havivi <
> > shaharh at redhat.com
> > > > > >> <mailto:shaharh at redhat.com>> wrote:
> > > > > >>
> > > > > >>     On 17.02.14 18:25, Tejesh M wrote:
> > > > > >>      > Thanks.. thats solved the issue. but now when i try to
> > login
> > > > with
> > > > > >>     password
> > > > > >>      > i set through API using cloud-init. OS (RHEL 6) is asking
> > me to
> > > > > >>     assign new
> > > > > >>      > password & what ever i give weak or strong password, it is
> > not
> > > > > >>     accepting.
> > > > > >>     try more then 8 characters with upper lower numbers and
> > symbols :)
> > > > > >>      >
> > > > > >>      >
> > > > > >>      >
> > > > > >>      >
> > > > > >>      > On Mon, Feb 17, 2014 at 11:50 AM, Itamar Heim <
> > > > iheim at redhat.com
> > > > > >>     <mailto:iheim at redhat.com>> wrote:
> > > > > >>      >
> > > > > >>      > > On 02/17/2014 08:16 AM, Tejesh M wrote:
> > > > > >>      > >
> > > > > >>      > >> It's cloud-init-0.6.3-0.12.bzr532.el6.noarch.rpm
> > installed
> > > > on
> > > > > >>     guest.
> > > > > >>      > >>
> > > > > >>      > >
> > > > > >>      > > you need at least 0.7.2 iirc, its available in .el6.5
> > > > > >>      > >
> > > > > >>      > >
> > > > > >>      > >>
> > > > > >>      > >> On Fri, Feb 14, 2014 at 9:18 PM, Itamar Heim <
> > > > iheim at redhat.com
> > > > > >>     <mailto:iheim at redhat.com>
> > > > > >>      > >> <mailto:iheim at redhat.com <mailto:iheim at redhat.com>>>
> > wrote:
> > > > > >>      > >>
> > > > > >>      > >>     On 02/14/2014 03:07 PM, Tejesh M wrote:
> > > > > >>      > >>
> > > > > >>      > >>         Thanks, now i could see the cloud-init option
> > in Run
> > > > > >>     Once.. I did
> > > > > >>      > >>         selected "Other Linux" instead of exact Linux
> > > > flavor.
> > > > > >>     And sorry,
> > > > > >>      > >>         instead
> > > > > >>      > >>         of Reply All, i clicked on Reply and sent that
> > mail.
> > > > > >>      > >>
> > > > > >>      > >>
> > > > > >>      > >>     shahar - any reason 'other linux' doesn't have
> > > > cloud-init?
> > > > > >>     sounds
> > > > > >>      > >>     liek a bug?
> > > > > >>      > >>     Tejesh - which version of cloud-init in the guest?
> > > > > >>      > >>
> > > > > >>      > >>
> > > > > >>      > >>
> > > > > >>      > >>
> > > > > >>      > >> --
> > > > > >>      > >> Thanks & Regards
> > > > > >>      > >> Tejesh
> > > > > >>      > >>
> > > > > >>      > >
> > > > > >>      > >
> > > > > >>      >
> > > > > >>     >
> > > > > >>     > --
> > > > > >>     > Thanks & Regards
> > > > > >>     > Tejesh
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >> --
> > > > > >> Thanks & Regards
> > > > > >> Tejesh
> > > > > >>
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Thanks & Regards
> > > > > Tejesh
> > > >
> > >
> > >
> > >
> > > --
> > > Thanks & Regards
> > > Tejesh
> >
> 
> 
> 
> -- 
> Thanks & Regards
> Tejesh



More information about the Users mailing list