Re: [asterisk-users] CLI History

2006-12-12 Thread Tzafrir Cohen
On Mon, Dec 11, 2006 at 10:31:41AM -0700, Douglas Garstang wrote:
 What's wrong with the Asterisk CLI history? When I exit the CLI, and 
 re-enter, the last command in the history always defaults to 'stop now'. 
 This is very bad, and it's caused accidental shutdowns more than once.

Let's ignore the tone of the question, and try to answer it. Here is
what I consider may be wrong:

1. The shell does not exit on Ctrl-D / EOF
2. When the shell does exist on Ctrl-C (SIGHUP) 
3. When it exists on Ctrl-C (SIGHUP) it does not save history.
4. (Potentially a problem) saving stop now in the history.

For starters, I hope you agree that (4) is not the real problem here.

(1) and (2) make the Asterisk shell different from standard shells. In s
standard shell Ctrl-C is supressed (so it will only affect programs you
run from it, and not the shell). Ctrl-D and end of input cause the shell
to exit.

(3) seems to be the real thing that bothers Douglas.


And as usual, Douglas manages to complain with the wrong tone and thus
getting people to flame him rather than consider his argument seriously.

-- 
   Tzafrir Cohen   
icq#16849755jabber:[EMAIL PROTECTED]
+972-50-7952406   mailto:[EMAIL PROTECTED]   
http://www.xorcom.com  iax:[EMAIL PROTECTED]/tzafrir
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-12 Thread Anselm Martin Hoffmeister
Am Montag, den 11.12.2006, 22:19 -0800 schrieb Luki:
  thats prety smart...   think hard.. wot was the command u gave to exit
  the CLI??
 
 OK, come on everyone. This is getting ridiculous. That's the entire
 point that stop now was NOT the last command on the CLI, yet it
 shows up at the most recent upon recall with the Up key. I have the
 same, except in my case it's stuck on show channels (which is rather
 convenient so I didn't complain). And yes, it doesn't matter if I exit
 the CLI with Ctrl+C or exit. In my case it's probably a permission
 issue since I run * non-root and chroot'ed.
 
 Either way, I don't see why the history could not be save upon exit
 with Ctrl+C -- the mySQL client does it.

Actually using quit the history is saved. That makes three more
keystrokes, but using Ctrl+C to end something gracefully just makes me
shudder. I even do not like using that combination for CopyPaste
(preferring CtrlIns)...

I think a point has been made that having stop now in the history is
inconvenient for many people. My personal opinion is that NOT storing
the commands
- exit
- stop
- quit
in the history would improve its usability.

Getting Ctrl+D to work would help too. IIRC it boils down to catching
SIGHUP (instead of/additional to SIGINT for Ctrl+C).

I do not know wether those discussions have been had on the developers
list, so it could be worth to bring it to attention over there. The code
changes in question would expectedly be trivial; if there was some kind
of consensus (more complicated) someone e.g. me could do that.

(Following the old rule of OpenSource Feature Requests: If you want
something done, best offer to do it yourself... :-)

Best Regards,

Anselm


___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] CLI History

2006-12-11 Thread Douglas Garstang
What's wrong with the Asterisk CLI history? When I exit the CLI, and re-enter, 
the last command in the history always defaults to 'stop now'. This is very 
bad, and it's caused accidental shutdowns more than once.

Connected to Asterisk 1.2.9.1 currently running on hera (pid = 17399)
Verbosity is at least 3
hera*CLI A
No such command 'A' (type 'help' for help)
hera*CLI B
No such command 'B' (type 'help' for help)
hera*CLI C
No such command 'C' (type 'help' for help)
hera*CLI D
No such command 'D' (type 'help' for help)
hera*CLI E
No such command 'E' (type 'help' for help)
hera*CLI 
[10:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. and others.
Created by Mark Spencer [EMAIL PROTECTED]
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for details.
This is free software, with components licensed under the GNU General Public
License version 2 and other licenses; you are welcome to redistribute it under
certain conditions. Type 'show license' for details.
=
Connected to Asterisk 1.2.9.1 currently running on hera (pid = 17399)
Verbosity is at least 3
hera*CLI stop now -- I pressed the UP arrow upon re-entering the console!

Doug


___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Dave Cotton
On Mon, 2006-12-11 at 10:31 -0700, Douglas Garstang wrote:
 What's wrong with the Asterisk CLI history? When I exit the CLI, and 
 re-enter, the last command in the history always defaults to 'stop now'. This 
 is very bad, and it's caused accidental shutdowns more than once.

Nothing wrong here. 
-- 
Dave Cotton [EMAIL PROTECTED]

___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [asterisk-users] CLI History

2006-12-11 Thread Douglas Garstang
 -Original Message-
 From: Dave Cotton [mailto:[EMAIL PROTECTED]
 Sent: Monday, December 11, 2006 10:55 AM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [asterisk-users] CLI History
 
 
 On Mon, 2006-12-11 at 10:31 -0700, Douglas Garstang wrote:
  What's wrong with the Asterisk CLI history? When I exit the 
 CLI, and re-enter, the last command in the history always 
 defaults to 'stop now'. This is very bad, and it's caused 
 accidental shutdowns more than once.
 
 Nothing wrong here. 

Can you possibly be a little more specific on why it isn't a problem?

Doug.
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [asterisk-users] CLI History

2006-12-11 Thread Jonathan k. Creasy
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:asterisk-users-
 [EMAIL PROTECTED] On Behalf Of Douglas Garstang
 Sent: Monday, December 11, 2006 1:37 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: RE: [asterisk-users] CLI History
 
  -Original Message-
  From: Dave Cotton [mailto:[EMAIL PROTECTED]
  Sent: Monday, December 11, 2006 10:55 AM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: Re: [asterisk-users] CLI History
 
 
  On Mon, 2006-12-11 at 10:31 -0700, Douglas Garstang wrote:
   What's wrong with the Asterisk CLI history? When I exit the
  CLI, and re-enter, the last command in the history always
  defaults to 'stop now'. This is very bad, and it's caused
  accidental shutdowns more than once.
 
  Nothing wrong here.
 
 Can you possibly be a little more specific on why it isn't a problem?
 
 Doug.
 ___

Sounds like it is working as intended if that is the last command you
executed. I'd say be more careful when executing commands. 
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Carla Schroder
On Monday 11 December 2006 9:31 am, Douglas Garstang wrote:
 What's wrong with the Asterisk CLI history? When I exit the CLI, and
 re-enter, the last command in the history always defaults to 'stop now'.
 This is very bad, and it's caused accidental shutdowns more than once.

 Connected to Asterisk 1.2.9.1 currently running on hera (pid = 17399)
 Verbosity is at least 3
 hera*CLI A
 No such command 'A' (type 'help' for help)
 hera*CLI B
 No such command 'B' (type 'help' for help)
 hera*CLI C
 No such command 'C' (type 'help' for help)
 hera*CLI D
 No such command 'D' (type 'help' for help)
 hera*CLI E
 No such command 'E' (type 'help' for help)
 hera*CLI
 [10:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
 Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. and others.
 Created by Mark Spencer [EMAIL PROTECTED]
 Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for
 details. This is free software, with components licensed under the GNU
 General Public License version 2 and other licenses; you are welcome to
 redistribute it under certain conditions. Type 'show license' for details.
 =
 Connected to Asterisk 1.2.9.1 currently running on hera (pid = 17399)
 Verbosity is at least 3
 hera*CLI stop now -- I pressed the UP arrow upon re-entering the console!


 I'm a bit confused by your example. What are A,B,C, etc? To exit the Asterisk 
console, I type 'exit'. Asterisk continues to run, as it should. To re-enter 
the console I use asterisk -rvvv.

-- 
~
Carla Schroder
Linux geek and random computer tamer
check out my Linux Cookbook! 
http://www.oreilly.com/catalog/linuxckbk/
best book for sysadmins and power users
~
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [asterisk-users] CLI History

2006-12-11 Thread Jonathan k. Creasy
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:asterisk-users-
 [EMAIL PROTECTED] On Behalf Of Carla Schroder
 Sent: Monday, December 11, 2006 2:17 PM
 To: asterisk-users@lists.digium.com
 Subject: Re: [asterisk-users] CLI History
 
 On Monday 11 December 2006 9:31 am, Douglas Garstang wrote:
  What's wrong with the Asterisk CLI history? When I exit the CLI, and
  re-enter, the last command in the history always defaults to 'stop
now'.
  This is very bad, and it's caused accidental shutdowns more than
once.
 
  Connected to Asterisk 1.2.9.1 currently running on hera (pid =
17399)
  Verbosity is at least 3
  hera*CLI A
  No such command 'A' (type 'help' for help)
  hera*CLI B
  No such command 'B' (type 'help' for help)
  hera*CLI C
  No such command 'C' (type 'help' for help)
  hera*CLI D
  No such command 'D' (type 'help' for help)
  hera*CLI E
  No such command 'E' (type 'help' for help)
  hera*CLI
  [10:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
  Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. and others.
  Created by Mark Spencer [EMAIL PROTECTED]
  Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for
  details. This is free software, with components licensed under the
GNU
  General Public License version 2 and other licenses; you are welcome
to
  redistribute it under certain conditions. Type 'show license' for
 details.
 


=
  Connected to Asterisk 1.2.9.1 currently running on hera (pid =
17399)
  Verbosity is at least 3
  hera*CLI stop now -- I pressed the UP arrow upon re-entering the
 console!
 
 

Mine appears to work: 

##Connected to Asterisk and execute stop now: 

dragon*CLI stop now
dragon*CLI
Disconnected from Asterisk server

## Restarted Asterisk: 

[EMAIL PROTECTED] ~]# asterisk -p

## Connected to Asterisk then ran exit: 

[EMAIL PROTECTED] ~]# asterisk -r
Asterisk 1.4.0-beta3, Copyright (C) 1999 - 2006 Digium, Inc. and
others.
Created by Mark Spencer [EMAIL PROTECTED]
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty'
for details.
This is free software, with components licensed under the GNU
General Public
License version 2 and other licenses; you are welcome to
redistributeit under
certain conditions. Type 'show license' for details.

==
===
Connected to Asterisk 1.4.0-beta3 currently running on dragon
(pid =  32521)
dragon*CLI exit

## Connected to Asterisk Again and hit the up arrow:

[EMAIL PROTECTED] ~]# asterisk -r
Asterisk 1.4.0-beta3, Copyright (C) 1999 - 2006 Digium, Inc. and
others.
Created by Mark Spencer [EMAIL PROTECTED]
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty'
for details.
This is free software, with components licensed under the GNU
General Public
License version 2 and other licenses; you are welcome to
redistributeit under
certain conditions. Type 'show license' for details.

==
===
Connected to Asterisk 1.4.0-beta3 currently running on dragon
(pid =  32521)
dragon*CLI exit

Exit is displayed not stop now. If you hit A and it's an invalid
command...maybe that is your problem...
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Aaron Daniel
On Mon, 2006-12-11 at 11:17 -0800, Carla Schroder wrote:
 On Monday 11 December 2006 9:31 am, Douglas Garstang wrote:
  What's wrong with the Asterisk CLI history? When I exit the CLI, and
  re-enter, the last command in the history always defaults to 'stop now'.
  This is very bad, and it's caused accidental shutdowns more than once.
 
  Connected to Asterisk 1.2.9.1 currently running on hera (pid = 17399)
  Verbosity is at least 3
  hera*CLI A
  No such command 'A' (type 'help' for help)
  hera*CLI B
  No such command 'B' (type 'help' for help)
  hera*CLI C
  No such command 'C' (type 'help' for help)
  hera*CLI D
  No such command 'D' (type 'help' for help)
  hera*CLI E
  No such command 'E' (type 'help' for help)
  hera*CLI
  [10:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
  Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. and others.
  Created by Mark Spencer [EMAIL PROTECTED]
  Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for
  details. This is free software, with components licensed under the GNU
  General Public License version 2 and other licenses; you are welcome to
  redistribute it under certain conditions. Type 'show license' for details.
  =
  Connected to Asterisk 1.2.9.1 currently running on hera (pid = 17399)
  Verbosity is at least 3
  hera*CLI stop now -- I pressed the UP arrow upon re-entering the console!
 
 
  I'm a bit confused by your example. What are A,B,C, etc? To exit the 
 Asterisk 
 console, I type 'exit'. Asterisk continues to run, as it should. To re-enter 
 the console I use asterisk -rvvv.
 
He was demonstrating how the CLI history shows stop now as the last
command (which um... it's a history?  you're last command is gonna be
the um... last command you ran... i.e. stop now).

Douglas,  why're you even running stop now on a live production
server.  If you're not, quit complaining and watch what you type before
hitting enter.
-- 
Aaron Daniel
Senior Voice Analyst
Sam Houston State University
[EMAIL PROTECTED]
(936) 294-4198

___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [asterisk-users] CLI History

2006-12-11 Thread Douglas Garstang
 -Original Message-
 From: Aaron Daniel [mailto:[EMAIL PROTECTED]
 Sent: Monday, December 11, 2006 12:57 PM
 To: asterisk-users@lists.digium.com
 Subject: Re: [asterisk-users] CLI History
 
 
 On Mon, 2006-12-11 at 11:17 -0800, Carla Schroder wrote:
  On Monday 11 December 2006 9:31 am, Douglas Garstang wrote:
   What's wrong with the Asterisk CLI history? When I exit 
 the CLI, and
   re-enter, the last command in the history always defaults 
 to 'stop now'.
   This is very bad, and it's caused accidental shutdowns 
 more than once.
  
   Connected to Asterisk 1.2.9.1 currently running on hera 
 (pid = 17399)
   Verbosity is at least 3
   hera*CLI A
   No such command 'A' (type 'help' for help)
   hera*CLI B
   No such command 'B' (type 'help' for help)
   hera*CLI C
   No such command 'C' (type 'help' for help)
   hera*CLI D
   No such command 'D' (type 'help' for help)
   hera*CLI E
   No such command 'E' (type 'help' for help)
   hera*CLI
   [10:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
   Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. 
 and others.
   Created by Mark Spencer [EMAIL PROTECTED]
   Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show 
 warranty' for
   details. This is free software, with components licensed 
 under the GNU
   General Public License version 2 and other licenses; you 
 are welcome to
   redistribute it under certain conditions. Type 'show 
 license' for details.
   
 ==
 ===
   Connected to Asterisk 1.2.9.1 currently running on hera 
 (pid = 17399)
   Verbosity is at least 3
   hera*CLI stop now -- I pressed the UP arrow upon 
 re-entering the console!
  
  
   I'm a bit confused by your example. What are A,B,C, etc? 
 To exit the Asterisk 
  console, I type 'exit'. Asterisk continues to run, as it 
 should. To re-enter 
  the console I use asterisk -rvvv.
  
 He was demonstrating how the CLI history shows stop now as the last
 command (which um... it's a history?  you're last command is gonna be
 the um... last command you ran... i.e. stop now).

For crying out loud, why is this so hard to understand? It isn't rocket 
science. I said that when I exit the CLI and re-enter, no matter what my 
previous set of commands was, when I hit the UP arrow key, it was always 'stop 
now'. 'Stop now' WAS NOT MY PREVIOUS COMMAND.

For the person that suggested maybe unknown commands are not added to the 
history...

hera*CLI show channels
Channel  Location State   Application(Data) 
0 active channels
0 active calls
hera*CLI sip show channels
Peer User/ANRCall ID  Seq (Tx/Rx)  Form  Hold Last 
Message   
0 active SIP channels
hera*CLI 
(I Pressed Ctrl-c here)

[13:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. and others.
Created by Mark Spencer [EMAIL PROTECTED]
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for details.
This is free software, with components licensed under the GNU General Public
License version 2 and other licenses; you are welcome to redistribute it under
certain conditions. Type 'show license' for details.
=
Connected to Asterisk 1.2.9.1 currently running on hera (pid = 18149)
Verbosity is at least 3
hera*CLI stop now (I pressed the up arrow key here)

As you can see, my previous commands where 'show channels' and 'sip show 
channels'. When I exited the CLI and re-entered and pressed ctrl-c, the 
commands in the history where not 'show channels and 'sip show channels' but 
'stop now' instead.

Doug.


___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Mailing List


- Original Message - 


On Mon, 2006-12-11 at 10:31 -0700, Douglas Garstang wrote:
 What's wrong with the Asterisk CLI history? When I exit the 
CLI, and re-enter, the last command in the history always 
defaults to 'stop now'. This is very bad, and it's caused 
accidental shutdowns more than once.


Nothing wrong here. 


Can you possibly be a little more specific on why it isn't a problem?


It's most likely how he is quitting the client.
If you exit properly (exit or quit) it retains it but if you can cancel out 
(ctrl-c) it just drops.
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Todd- Asterisk

short version:  me too

long version:  The same thing happens on my asterisk boxes - both  
built with the latest trixbox image...  perhaps that's a factor?  My  
history is always restart now, although I typically connect and run  
sip show peers.  I haven't typed restart now in a long time, but  
that is the first thing when I hit up-arrrow upon connecting


I have had history written to when I type 'exit' at the console  
instead of ctrl-c.   I haven't tested though as the school bus just  
arrived  ;)

   Todd


On Dec 11, 2006, at 3:35 PM, Douglas Garstang wrote:


-Original Message-
From: Aaron Daniel [mailto:[EMAIL PROTECTED]
Sent: Monday, December 11, 2006 12:57 PM
To: asterisk-users@lists.digium.com
Subject: Re: [asterisk-users] CLI History


On Mon, 2006-12-11 at 11:17 -0800, Carla Schroder wrote:

On Monday 11 December 2006 9:31 am, Douglas Garstang wrote:

What's wrong with the Asterisk CLI history? When I exit

the CLI, and

re-enter, the last command in the history always defaults

to 'stop now'.

This is very bad, and it's caused accidental shutdowns

more than once.


Connected to Asterisk 1.2.9.1 currently running on hera

(pid = 17399)

Verbosity is at least 3
hera*CLI A
No such command 'A' (type 'help' for help)
hera*CLI B
No such command 'B' (type 'help' for help)
hera*CLI C
No such command 'C' (type 'help' for help)
hera*CLI D
No such command 'D' (type 'help' for help)
hera*CLI E
No such command 'E' (type 'help' for help)
hera*CLI
[10:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc.

and others.

Created by Mark Spencer [EMAIL PROTECTED]
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show

warranty' for

details. This is free software, with components licensed

under the GNU

General Public License version 2 and other licenses; you

are welcome to

redistribute it under certain conditions. Type 'show

license' for details.



==
===

Connected to Asterisk 1.2.9.1 currently running on hera

(pid = 17399)

Verbosity is at least 3
hera*CLI stop now -- I pressed the UP arrow upon

re-entering the console!




 I'm a bit confused by your example. What are A,B,C, etc?

To exit the Asterisk

console, I type 'exit'. Asterisk continues to run, as it

should. To re-enter

the console I use asterisk -rvvv.


He was demonstrating how the CLI history shows stop now as the last
command (which um... it's a history?  you're last command is gonna be
the um... last command you ran... i.e. stop now).


For crying out loud, why is this so hard to understand? It isn't  
rocket science. I said that when I exit the CLI and re-enter, no  
matter what my previous set of commands was, when I hit the UP  
arrow key, it was always 'stop now'. 'Stop now' WAS NOT MY PREVIOUS  
COMMAND.


For the person that suggested maybe unknown commands are not added  
to the history...


hera*CLI show channels
Channel  Location State   Application(Data)
0 active channels
0 active calls
hera*CLI sip show channels
Peer User/ANRCall ID  Seq (Tx/Rx)  Form   
Hold Last Message

0 active SIP channels
hera*CLI
(I Pressed Ctrl-c here)

[13:[EMAIL PROTECTED](pbx3):~]# asterisk -trv
Asterisk 1.2.9.1, Copyright (C) 1999 - 2006 Digium, Inc. and others.
Created by Mark Spencer [EMAIL PROTECTED]
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty'  
for details.
This is free software, with components licensed under the GNU  
General Public
License version 2 and other licenses; you are welcome to  
redistribute it under

certain conditions. Type 'show license' for details.
== 
===

Connected to Asterisk 1.2.9.1 currently running on hera (pid = 18149)
Verbosity is at least 3
hera*CLI stop now (I pressed the up arrow key here)

As you can see, my previous commands where 'show channels' and 'sip  
show channels'. When I exited the CLI and re-entered and pressed  
ctrl-c, the commands in the history where not 'show channels and  
'sip show channels' but 'stop now' instead.


Doug.


___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users



___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


RE: [asterisk-users] CLI History

2006-12-11 Thread Douglas Garstang
 -Original Message-
 From: Mailing List [mailto:[EMAIL PROTECTED]
 Sent: Monday, December 11, 2006 1:38 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: Re: [asterisk-users] CLI History
 
 
 
 - Original Message - 
  
  On Mon, 2006-12-11 at 10:31 -0700, Douglas Garstang wrote:
   What's wrong with the Asterisk CLI history? When I exit the 
  CLI, and re-enter, the last command in the history always 
  defaults to 'stop now'. This is very bad, and it's caused 
  accidental shutdowns more than once.
  
  Nothing wrong here. 
 
 Can you possibly be a little more specific on why it isn't a problem?
 
 
 It's most likely how he is quitting the client.
 If you exit properly (exit or quit) it retains it but if you 
 can cancel out (ctrl-c) it just drops.

Yes, I think that's it. It seems that hitting ctrl-c breaks the history.
I'd file a bug (the cli process should be able to catch SIGINT), but I'm not 
running the latest 1.2.

Doug.
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Benjamin Jacob



On Mon, 2006-12-11 at 10:31 -0700, Douglas Garstang wrote:
 


What's wrong with the Asterisk CLI history? When I exit the CLI, and re-enter, 
the last command in the history always defaults to 'stop now'. This is very 
bad, and it's caused accidental shutdowns more than once.
   

thats prety smart...   think hard.. wot was the command u gave to exit 
the CLI??

history is a last-in-first-out kinda setup, anywhere, not just in * CLI.

___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] CLI History

2006-12-11 Thread Luki

thats prety smart...   think hard.. wot was the command u gave to exit
the CLI??


OK, come on everyone. This is getting ridiculous. That's the entire
point that stop now was NOT the last command on the CLI, yet it
shows up at the most recent upon recall with the Up key. I have the
same, except in my case it's stuck on show channels (which is rather
convenient so I didn't complain). And yes, it doesn't matter if I exit
the CLI with Ctrl+C or exit. In my case it's probably a permission
issue since I run * non-root and chroot'ed.

Either way, I don't see why the history could not be save upon exit
with Ctrl+C -- the mySQL client does it.

--Luki
___
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users