[openstack-dev] [Congress] Is it possible that congress policy do live-migration

Tim Hinrichs tim at styra.com
Wed Oct 18 18:01:14 UTC 2017


Adding [Congress] to the subject line for proper filtering...

Congress lets you execute most of the Nova client API calls.  You use the
same arguments you would use for the Nova client.  Here are the docs for
the live-migration API: scroll down to live-migrate.

https://docs.openstack.org/python-novaclient/latest/reference/api/novaclient.v2.servers.html

Congress doesn't let you pass in keyword args like host="foo" (others will
correct me if that's changed recently), so you will need to figure out what
non-keyword arguments live-migration allows you to pass.  It wasn't clear
to me from the docs.

Tim

On Wed, Oct 18, 2017 at 12:53 AM houzhian <houzhian at gmail.com> wrote:

>
> Hey guys, thanks for your efforts on OpenStack Congress, I am very puzzled
> about policy of Congress on recent days and I decided to ask you for some
> help, I am looking forward to your reply.
>
> openstack congress policy rule create \
> --name live_migrate_vm classification \
> 'execute[nova:servers.live_migrate(vmid,"
> overcloud-novacompute-1.opnfvlf.org","False","False")] :-
> host_down(host),
> active_instance_in_host(vmid, host)'
>
>
> Is this a valid policy? Is there some connection between nova client api
> and execute in congress policy which are allowed to use? I noticed that
>     nova pause vmid
>     'execute[nova:servers.pause(vmid)] :- condition' works properly
>     nova migrate vmid
>     'execute[nova:servers.pause(vmid)] :- condition' works properly
> there exist nova live-migration vmid
> but I can not add execute[nova:servers.live-migration(vmid,other params
> maybe)] to congress policy, nova:servers.live-migrate(vmid,other params)
> can be added successfuly but it didn't do live migration jobs, nothing
> happened.I am confused about this,
> Am I able to use congress to do some automatic fault recovery like live
> migration?
>
> 发自网易邮箱大师
>
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20171018/c0f67eea/attachment.html>


More information about the OpenStack-dev mailing list