[Pacemaker] Re: [Linux-HA] the crm command line interface

Serge Dubrouski sergeyfd at gmail.com
Wed Sep 10 00:33:26 UTC 2008


On Tue, Sep 9, 2008 at 5:13 PM, Dejan Muhamedagic <dejanmm at fastmail.fm> wrote:
> On Mon, Sep 08, 2008 at 04:10:04PM -0600, Serge Dubrouski wrote:
>> On Mon, Sep 8, 2008 at 4:01 PM, Lars Marowsky-Bree <lmb at suse.de> wrote:
>> > On 2008-09-08T15:53:39, Serge Dubrouski <sergeyfd at gmail.com> wrote:
>> >
>> >> > Part of this could be provided through command-line completion, which
>> >> > would be my personal preferences.
>
> The command-line completion has been implemented a few days ago.
>
>> >> Would be good but how one knows what is available?
>
> I'm trying to keep the doc up to date, but this time failed to do
> that. The help system should be quite good by now and I hope that
> most people should be able to get by just using that.
>
>> > Command-line completion would provide for that. You just hit tab-tab and
>> > all possible completions are listed.
>>
>> That would do. But there there has to be a possibility for multiline
>> input. Defining a primitive could be much larger than regular 80
>> characters and in one line it become unreadable. So one shall be
>> allowed to split let say defining parameters and operations to several
>> lines.
>
> You can use the continuation character (\) as in shell.
>
>> >> > "interactive menus" - we _are_ talking about a CLI, not a GUI here. ;-)
>> >> You know,  in old good times such thing did exist:
>> >>
>> >> 1. Create a primitive
>> >> 2. Delete a primitive
>> >> .......
>> >> 16. Commit
>> >> 17. Exit
>> >
>> > Right. I always hated that. ;-) I understand others might, but I dislike
>>
>> Matter of taste :-)
>
> I'm afraid that I can't promise anything of the kind right now.

And I'm not insisting on that :-) But there is a such thing that
required parameters defined in a meta data in RA, per my opinion CLI
has to check them and ask a user to provide values for them.

>
>> >> >>              <op id="monitor_myIP" name="monitor" interval="30s" timeout="30s"/>
>> >> >>              <op id="start_myIP" interval="30s" name="start" timeout="30s"/>
>> >> >>              <op id="stop_myIP" interval="30s" name="stop" timeout="30s"/>
>> >> >
>> >> > intervals on non-monitor? The CLI probably refuses to parse this because
>> >> > it's a semantic bug, which the DTD can't protect against ;-) But yes,
>> >> > that's a bug. Please file it.
>> >> A bug against what? CLI or cibadmin?
>> >
>> > CLI; it should not refuse to display it. Allowing you to define it from
>> > scratch - it probably shouldn't.
>>
>> It doesn't allow to define it but cibadmin refuses to accept it
>> without intervals complaining that it doesn't conform to DTD. That's
>> why I have it in my xml file.
>
> This was a lexer problem. Somehow it let the newline get into a
> token. It's fixed now.
>
> The cibadmin wouldn't complain about a missing interval. The DTD
> says nothing about that. The CRM could, not sure about that.
>
> The CLI is also not checking that. It may do so in future, not
> decided yet about it, as it may prove to be too difficult.
>
> Thanks,
>
> Dejan
>
>> > The pacemaker 0.7 release might be smarter to catch that at the schema
>> > layer, but I can't test that right now.
>> >
>> >
>> > Regards,
>> >    Lars
>> >
>> > --
>> > Teamlead Kernel, SuSE Labs, Research and Development
>> > SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG N?rnberg)
>> > "Experience is the name everyone gives to their mistakes." -- Oscar Wilde
>> >
>> >
>> > _______________________________________________
>> > Pacemaker mailing list
>> > Pacemaker at clusterlabs.org
>> > http://list.clusterlabs.org/mailman/listinfo/pacemaker
>> >
>>
>>
>>
>> --
>> Serge Dubrouski.
>>
>> _______________________________________________
>> Pacemaker mailing list
>> Pacemaker at clusterlabs.org
>> http://list.clusterlabs.org/mailman/listinfo/pacemaker
>
> _______________________________________________
> Pacemaker mailing list
> Pacemaker at clusterlabs.org
> http://list.clusterlabs.org/mailman/listinfo/pacemaker
>



-- 
Serge Dubrouski.




More information about the Pacemaker mailing list