xl create ... -c
Has anyone else noticed that "xl create DOM -c" does not work when using Xen 4.1.0 RC4? This seems to contradict xl's usage message.
I see:
$ sudo xl create Client.conf -c Usage: xl [-v] create <ConfigFile> [options] [vars]
Create a domain from config file <filename>.
Options:
-h Print this help. -p Leave the domain paused after it is created. -c Connect to the console after the domain is created.
So the documentation states that "-c" should accepted in this position, but the program does not accept it.
On the other hand, "xl create -c Client.conf" works.
Signature · 3 lines
Mike :wq
W. Michael Petullo writes ("[Xen-devel] xl create ... -c"):
Quoted 2 lines
Has anyone else noticed that "xl create DOM -c" does not work when using Xen 4.1.0 RC4? This seems to contradict xl's usage message.
Thanks for the report. I think this patch should fix it.
Ian.
xl: allow config filename to precede options
"xm create" supports options which follow the domain config filename. So xl should do as well.
This is an ad-hoc fixup to the "xl create" command line parser. We should revisit the xl command line parser in 4.2.
--- tools/libxl/xl_cmdimpl.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-)
tools/libxl/xl_cmdimpl.c +5 -0
@@ -3255,6 +3255,11 @@ int main_create(int argc, char **argv) {0, 0, 0, 0} }; +if (argv[1 ] && argv[1 ][0 ] !='-' && !strchr (argv[1 ],'=' )) { + filename = argv[1 ]; + argc--; argv++; + } +while (1 ) { opt =getopt_long (argc, argv,"hnqf:pcde" , long_options, &option_index);if (opt ==-1 )
Signature · 1 line
1.5.6.5
Ian Jackson writes ("[PATCH] Re: [Xen-devel] xl create ... -c"):
Quoted 1 line
xl: allow config filename to precede options
I have applied this patch.
Ian.