[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] tools: xl: add option to run in foreground but still monitor for reboot etc



Ian,


the xl migrate command gets a new option -F with this change.
Is it intentional? The "monitor" variable is not used in this part of
the patch.
It got applied in changeset 23350:f531ed84b066

Olaf

On Fri, May 06, Ian Campbell wrote:

> On Wed, 2011-05-04 at 16:36 +0100, Ian Campbell wrote:
> > # HG changeset patch
> > # User Ian Campbell <ian.campbell@xxxxxxxxxx>
> > # Date 1304523348 -3600
> > # Node ID 6f20fdf37a97db6ff6ce4690057b8fd6662582f5
> > # Parent  f033c864926375fd545af71a2f0229c00c4354a7
> > tools: xl: add option to run in foreground but still monitor for reboot etc
> 
> v3 updated for 23299:39f2942fe56b "xl: refactor common parts of command
> line parsing"
> 
> 8<----------------------
> 
> # HG changeset patch
> # User Ian Campbell <ian.campbell@xxxxxxxxxx>
> # Date 1304685600 -3600
> # Node ID c0d309593d78b3e7340b805f95330249e7142169
> # Parent  94ddef3d9f45fa36aa076a164dfbfa04c09eeb85
> tools: xl: add option to run in foreground but still monitor for reboot etc
> 
> Split daemonization option out from monitoring a domain for reboot
> etc. The 'e' option continues to disable both and a new 'F'(oreground)
> option disables only daemonization.
> 
> When I'm debugging xl in the foreground this is often the behaviour I
> would like.


> @@ -2864,9 +2877,9 @@ int main_migrate(int argc, char **argv)
>      const char *ssh_command = "ssh";
>      char *rune = NULL;
>      char *host;
> -    int opt, daemonize = 1, debug = 0;
> -
> -    while ((opt = def_getopt(argc, argv, "C:s:ed", "migrate", 2)) != -1) {
> +    int opt, daemonize = 1, monitor = 1, debug = 0;
> +
> +    while ((opt = def_getopt(argc, argv, "FC:s:ed", "migrate", 2)) != -1) {
>          switch (opt) {
>          case 0: case 2:
>              return opt;
> @@ -2876,8 +2889,12 @@ int main_migrate(int argc, char **argv)
>          case 's':
>              ssh_command = optarg;
>              break;
> +        case 'F':
> +            daemonize = 0;
> +            break;
>          case 'e':
>              daemonize = 0;
> +            monitor = 0;
>              break;
>          case 'd':
>              debug = 1;


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.