/l3/users/oleglevitskiy/lab-nt-voip/aster-3/root :1 :2 :3 :4 :5 :6 :7 |
|
#asterisk -rcvvvvvvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... 1301/1301 192.168.12.103 D N 5060 Unmonitored 1302/1302 192.168.12.206 D N 5060 Unmonitored 1303 (Unspecified) D N 0 Unmonitored frankfurt/berlin 192.168.12.6 D N 5060 Unmonitored kiev/berlin (Unspecified) D N 0 Unmonitored viena/berlin (Unspecified) D N 0 Unmonitored 6 sip peers [Monitored: 0 online, 0 offline Unmonitored: 3 online, 3 offline] aster-3*CLI> exit Executing last minute cleanups Asterisk cleanly ending (0). |
#cat sip.conf
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/viena ; peer ; 1301 - 1399 всё моё [1301] type=friend ... [kiev] type=friend secret=1234 host=dynamic username=berlin [viena] type=friend secret=1234 host=dynamic username=berlin |
#nano sip.conf
--- /tmp/l3-saved-3577.10978.2057 2014-04-23 12:33:41.260789188 +0300 +++ sip.conf 2014-04-23 12:34:48.984790685 +0300 @@ -4,11 +4,7 @@ register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev -register => berlin:1234@192.168.12.5/viena - - -; peer -; 1301 - 1399 всё моё +register => berlin:1234@192.168.12.5/vienna [1301] type=friend @@ -37,7 +33,7 @@ host=dynamic username=berlin -[viena] +[vienna] type=friend secret=1234 host=dynamic |
#[default]
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... -- Auto fallthrough, channel 'SIP/1302-0000001e' status is 'CHANUNAVAIL' == Using SIP RTP CoS mark 5 -- Executing [2201@default:1] Dial("SIP/1302-0000001f", "SIP/vienna/2201") in new stack [Apr 23 13:03:26] WARNING[4334]: app_dial.c:2274 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Unknown) == Everyone is busy/congested at this time (1:0/0/1) -- Auto fallthrough, channel 'SIP/1302-0000001f' status is 'CHANUNAVAIL' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano extensions.conf
|
#[default]
|
#secret=1234
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... kiev 1234 default No Yes vienna 1234 default No Yes 1303 1234 default No Yes 1302 1234 default No Yes 1301 1234 default No Yes frankfurt 1234 default No Yes aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#service asterisk reload
Reloading Asterisk PBX configuration files. |
#asterisk -rcvvvvvvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... vienna/berlin (Unspecified) D N 0 Unmonitored 6 sip peers [Monitored: 0 online, 0 offline Unmonitored: 3 online, 3 offline] -- Remote UNIX connection -- Remote UNIX connection disconnected aster-3*CLI> sip reload Reloading SIP aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano extensions.conf
|
#[default]
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#cat sip.conf
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#nano extensions.conf
|
#[default]
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#nano sip.conf
|
#secret=1234
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#nano extensions.conf
--- /tmp/l3-saved-3577.28178.29245 2014-04-23 13:12:06.860839984 +0300 +++ extensions.conf 2014-04-23 13:13:24.636841705 +0300 @@ -8,9 +8,9 @@ exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) -exten => _12XX,1,Dial(SIP/kiev/${EXTEN}) +exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) -exten => _22XX,1,Dial(SIP/vienna/${EXTEN}) +exten => _2XXX,1,Dial(SIP/vienna/${EXTEN}) |
#[default]
Reloading Asterisk PBX configuration files. |
#nano extensions.conf
|
#[default]
Reloading Asterisk PBX configuration files. |
#asterisk -rcvvvvvvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... 6 sip peers [Monitored: 0 online, 0 offline Unmonitored: 3 online, 3 offline] == Using SIP RTP CoS mark 5 -- Executing [1201@default:1] Dial("SIP/192.168.12.5-0000002b", "SIP/kiev/1201") in new stack [Apr 23 13:15:57] WARNING[4583]: app_dial.c:2274 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Unknown) == Everyone is busy/congested at this time (1:0/0/1) -- Auto fallthrough, channel 'SIP/192.168.12.5-0000002b' status is 'CHANUNAVAIL' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano sip.conf
--- /tmp/l3-saved-3577.8392.15210 2014-04-23 13:18:05.924847897 +0300 +++ sip.conf 2014-04-23 13:22:03.280853140 +0300 @@ -29,12 +29,12 @@ [kiev] type=friend -secret=1234 -host=dynamic -username=berlin +secret=1234 +host=dynamic +username=berlin -[vienna] -type=friend -secret=1234 -host=dynamic +[vienna] +type=friend +secret=1234 +host=dynamic username=berlin |
#asterisk -rcvvvvvvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... == Using SIP RTP CoS mark 5 -- Executing [1301@default:1] Dial("SIP/frankfurt-0000003e", "SIP/1301") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/1301 -- SIP/1301-0000003f is ringing == Spawn extension (default, 1301, 1) exited non-zero on 'SIP/frankfurt-0000003e' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano sip.conf
|
#[general]
|
#[default]
|
#[default]
|
#[general]
Reloading Asterisk PBX configuration files. |
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 2628) ... -- Auto fallthrough, channel 'SIP/192.168.12.5-00000051' status is 'CHANUNAVAIL' == Using SIP RTP CoS mark 5 -- Executing [1202@default:1] Dial("SIP/192.168.12.5-00000052", "SIP/kiev/1202") in new stack [Apr 23 13:31:26] WARNING[4748]: app_dial.c:2274 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Unknown) == Everyone is busy/congested at this time (1:0/0/1) -- Auto fallthrough, channel 'SIP/192.168.12.5-00000052' status is 'CHANUNAVAIL' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano sip.conf
--- /tmp/l3-saved-3577.15544.27757 2014-04-23 13:31:47.532865999 +0300 +++ sip.conf 2014-04-23 13:32:09.656866476 +0300 @@ -4,7 +4,7 @@ register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev -register => berlin:1234@192.168.12.5/viena +register => berlin:1234@192.168.12.5/vienna [1301] type=friend @@ -33,7 +33,7 @@ host=dynamic username=berlin -[viena] +[vienna] type=friend secret=1234 host=dynamic |
#[general]
|
#[default]
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 4813) ... == Everyone is busy/congested at this time (1:0/0/1) -- Auto fallthrough, channel 'SIP/192.168.12.2-00000005' status is 'CHANUNAVAIL' == Using SIP RTP CoS mark 5 -- Executing [2301@default:1] Dial("SIP/192.168.12.2-00000006", "SIP/frankfurt/2301") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/frankfurt/2301 -- SIP/frankfurt-00000007 is ringing aster-3*CLI> exit Executing last minute cleanups Asterisk cleanly ending (0). |
#nano sip.conf
|
#secret=1234
|
#[default]
|
#[default]
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 4953) ... == Spawn extension (default, 1301, 1) exited non-zero on 'SIP/192.168.12.5-00000004' == Using SIP RTP CoS mark 5 -- Executing [3201@default:1] Dial("SIP/1302-00000006", "SIP/kiev/3201") in new stack [Apr 23 13:37:12] WARNING[5009]: app_dial.c:2274 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Unknown) == Everyone is busy/congested at this time (1:0/0/1) -- Auto fallthrough, channel 'SIP/1302-00000006' status is 'CHANUNAVAIL' aster-3*CLI> sip show peers Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano extensions.conf ^C
|
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 4953) ... 1302/1302 192.168.12.206 D N 5060 Unmonitored 1303 (Unspecified) D N 0 Unmonitored frankfurt/berlin 192.168.12.6 D N 5060 Unmonitored kiev/berlin (Unspecified) D N 0 Unmonitored vienna/berlin (Unspecified) D N 0 Unmonitored 6 sip peers [Monitored: 0 online, 0 offline Unmonitored: 3 online, 3 offline] aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano sip.conf
|
#[general]
|
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 4953) ... == Using SIP RTP CoS mark 5 -- Executing [1302@default:1] Dial("SIP/192.168.12.2-00000023", "SIP/1302") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/1302 -- SIP/1302-00000024 is ringing == Spawn extension (default, 1302, 1) exited non-zero on 'SIP/192.168.12.2-00000023' aster-3*CLI> sip show peers Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#cat sip.conf
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 4953) ... -- Executing [2101@default:1] Dial("SIP/kiev-000000c3", "SIP/vienna/2101") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/vienna/2101 -- SIP/vienna-000000c4 answered SIP/kiev-000000c3 -- Locally bridging SIP/kiev-000000c3 and SIP/vienna-000000c4 == Spawn extension (default, 2101, 1) exited non-zero on 'SIP/kiev-000000c3' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#cat sip.conf
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#cat extensions.conf
[default] ;exten => 1301,1,Answer ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup exten => _13XX,1,Dial(SIP/${EXTEN}) exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) |
#cat sip.conf
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic ... [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin |
#nano extensions.conf
--- /tmp/l3-saved-3577.5385.5878 2014-04-23 14:15:15.132923455 +0300 +++ extensions.conf 2014-04-23 14:15:41.872924033 +0300 @@ -4,15 +4,11 @@ ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup -exten => _13XX,1,Dial(SIP/${EXTEN}) - -exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) - -exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) - -exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) - -exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) +;exten => _13XX,1,Dial(SIP/${EXTEN}) +;exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) +;exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) +;exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) +;exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) |
#[default]
GNU nano 2.2.6 File: extensions.conf Modified [default] ;exten => 1301,1,Answer ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup ;exten => _13XX,1,Dial(SIP/${EXTEN}) ;exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) [internal] [local] exten => _13XX,1,Dial(SIP/${EXTEN}) [national] exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) [international] ^G Get Help ^O WriteOut ^R Read File ^Y Prev Page ^K Cut Text ^C Cur Pos ^X Exit ^J Justify ^W Where Is ^V Next Page ^U UnCut Text^T To Spell |
#[default]
|
#{EXTEN})
|
#[general]
|
#nano extensions.conf
|
#{EXTEN})
|
#cat extensions.conf
[default] ;exten => 1301,1,Answer ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup ;exten => _13XX,1,Dial(SIP/${EXTEN}) ;exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) [internal] ... include => local include => national include => international [gr2] include => internal include => local include => national [gr3] include => internal include => local |
#nano extensions.conf
--- /tmp/l3-saved-3577.13118.19852 2014-04-23 14:35:50.516950674 +0300 +++ extensions.conf 2014-04-23 14:36:45.588951879 +0300 @@ -26,21 +26,26 @@ exten => _3[123]XX,1,Dial(SIP/vienna/${EXTEN}) -[gr1] +[gr_relay] include => internal include => local include => national include => international -[gr2] +[gr1] include => internal include => local include => national +include => international -[gr3] +[gr2] +include => internal +include => local +include => national +[gr3] include => internal include => local |
#[general]
|
#[default]
|
#secret=1234
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#nano sip.conf
--- /tmp/l3-saved-3577.7456.15332 2014-04-23 14:38:21.776954010 +0300 +++ sip.conf 2014-04-23 14:38:45.356954523 +0300 @@ -11,11 +11,13 @@ secret=1234 host=dynamic + [1302] type=friend secret=1234 host=dynamic + [1303] type=friend secret=1234 |
#[general]
|
#{EXTEN})
GNU nano 2.2.6 File: sip.conf Modified [general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 ... username=berlin context=gr_relay [kiev] type=friend secret=1234 host=dynamic username=berlin context=gr_relay ^G Get Help ^O WriteOut ^R Read File ^Y Prev Page ^K Cut Text ^C Cur Pos ^X Exit ^J Justify ^W Where Is ^V Next Page ^U UnCut Text^T To Spell |
#nano extensions.conf
|
#{EXTEN})
|
#[general]
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#service asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#asterisk -rcvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 5892) ... == Using SIP RTP CoS mark 5 -- Executing [1102@gr_relay:1] Dial("SIP/vienna-00000014", "SIP/kiev/1102") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/kiev/1102 == Everyone is busy/congested at this time (1:0/1/0) -- Auto fallthrough, channel 'SIP/vienna-00000014' status is 'CONGESTION' aster-3*CLI> sip show peers Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano sip.conf
|
#[1303]
|
#{EXTEN})
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 5892) ... == Using SIP RTP CoS mark 5 -- Executing [3301@gr_relay:1] Dial("SIP/kiev-00000281", "SIP/vienna/3301") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/vienna/3301 -- SIP/vienna-00000282 is ringing == Spawn extension (gr_relay, 3301, 1) exited non-zero on 'SIP/kiev-00000281' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#nano extensions.conf
--- /tmp/l3-saved-3577.830.27844 2014-04-23 14:51:26.176971288 +0300 +++ extensions.conf 2014-04-23 14:55:16.380976360 +0300 @@ -25,27 +25,30 @@ exten => _1[12]XX,1,Dial(SIP/kiev/${EXTEN}) exten => _3[123]XX,1,Dial(SIP/vienna/${EXTEN}) - +[fallback] +exten => _.,1,Playback(nepravilno-nabran-nomer) [gr_relay] include => internal include => local include => national include => international - +include => fallback [gr1] include => internal include => local include => national include => international +include => fallback [gr2] include => internal include => local include => national +include => fallback [gr3] include => internal include => local - +include => fallback |
#{EXTEN})
l3script: la: command not found |
#ls -al /usr/share/asterisk/sounds/en/
total 2296 drwxr-xr-x 8 root root 20480 Apr 22 14:26 . drwxr-xr-x 3 root root 4096 Apr 22 14:27 .. -rw-r--r-- 1 root root 8943 Oct 5 2011 agent-alreadyon.gsm -rw-r--r-- 1 root root 8085 Oct 5 2011 agent-incorrect.gsm -rw-r--r-- 1 root root 2244 Oct 5 2011 agent-loggedoff.gsm -rw-r--r-- 1 root root 2277 Oct 5 2011 agent-loginok.gsm -rw-r--r-- 1 root root 5049 Oct 5 2011 agent-newlocation.gsm -rw-r--r-- 1 root root 4752 Oct 5 2011 agent-pass.gsm -rw-r--r-- 1 root root 7326 Oct 5 2011 agent-user.gsm ... -rw-r--r-- 1 root root 2871 Oct 5 2011 vm-tooshort.gsm -rw-r--r-- 1 root root 3267 Oct 5 2011 vm-toreply.gsm -rw-r--r-- 1 root root 4158 Oct 5 2011 vm-torerecord.gsm -rw-r--r-- 1 root root 2376 Oct 5 2011 vm-undeleted.gsm -rw-r--r-- 1 root root 4389 Oct 5 2011 vm-undelete.gsm -rw-r--r-- 1 root root 2838 Oct 5 2011 vm-unknown-caller.gsm -rw-r--r-- 1 root root 1683 Oct 5 2011 vm-Urgent.gsm -rw-r--r-- 1 root root 4818 Oct 5 2011 vm-whichbox.gsm -rw-r--r-- 1 root root 1056 Oct 5 2011 vm-Work.gsm -rw-r--r-- 1 root root 1452 Oct 5 2011 vm-youhave.gsm |
#nano extensions.conf
--- /tmp/l3-saved-3577.29677.7258 2014-04-23 14:57:33.936979389 +0300 +++ extensions.conf 2014-04-23 14:57:44.800979610 +0300 @@ -26,7 +26,7 @@ exten => _3[123]XX,1,Dial(SIP/vienna/${EXTEN}) [fallback] -exten => _.,1,Playback(vm-review.gsm) +exten => _.,1,Playback(vm-review) [gr_relay] include => internal |
#[default]
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#nano extensions.conf
--- /tmp/l3-saved-3577.5005.15823 2014-04-23 15:04:49.728989000 +0300 +++ extensions.conf 2014-04-23 15:05:52.404990369 +0300 @@ -21,7 +21,7 @@ ;exten => _14XX,1,Dial(SIP/frankfurt/${EXTEN}) [international] -exten => _2[12]XX,1,Dial(SIP/vienna/${EXTEN}) +exten => _2[123]XX,1,Dial(SIP/vienna/${EXTEN}) exten => _1[12]XX,1,Dial(SIP/kiev/${EXTEN}) exten => _3[123]XX,1,Dial(SIP/vienna/${EXTEN}) |
#[default]
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#service asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#nano extensions.conf
|
#[default]
|
#[default]
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#cat extensions.conf
[default] ;exten => 1301,1,Answer ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup ;exten => _13XX,1,Dial(SIP/${EXTEN}) ;exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) [internal] ... include => fallback [gr2] include => internal include => local include => national include => fallback [gr3] include => internal include => local include => fallback |
#asterisk -rvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 7737) ... -- Executing [3101@gr_relay:1] Dial("SIP/vienna-00000402", "SIP/vienna/3101") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/vienna/3101 [Apr 23 15:13:08] WARNING[7775]: chan_sip.c:20366 handle_response_invite: Received response: "Forbidden" from '"2201" <sip:2201@192.168.12.3>;tag=as357d714c' == Everyone is busy/congested at this time (1:0/1/0) -- Auto fallthrough, channel 'SIP/vienna-00000402' status is 'CONGESTION' -- Executing [h@gr_relay:1] Playback("SIP/vienna-00000402", "vm-review") in new stack == Spawn extension (gr_relay, h, 1) exited non-zero on 'SIP/vienna-00000402' aster-3*CLI> quit Executing last minute cleanups |
#cat extensions.conf
cat: extensions.conf: No such file or directory |
#cat extensions.conf
cat: extensions.conf: No such file or directory |
#pwd
/root |
#cd /etc/asterisk/
|
#cat extensions.conf
[default] ;exten => 1301,1,Answer ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup ;exten => _13XX,1,Dial(SIP/${EXTEN}) ;exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) [internal] ... include => fallback [gr2] include => internal include => local include => national include => fallback [gr3] include => internal include => local include => fallback |
#asterisk -rcvvvvvvvvvvvvvvvv
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 7737) ... -- Executing [1101@gr_relay:1] Dial("SIP/vienna-00000b1c", "SIP/kiev/1101") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/kiev/1101 -- SIP/kiev-00000b1d is ringing == Spawn extension (gr_relay, 1101, 1) exited non-zero on 'SIP/vienna-00000b1c' -- Executing [h@gr_relay:1] Playback("SIP/vienna-00000b1c", "vm-review") in new stack == Spawn extension (gr_relay, h, 1) exited non-zero on 'SIP/vienna-00000b1c' aster-3*CLI> quit Executing last minute cleanups Asterisk cleanly ending (0). |
#[default]
|
#[default]
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 7737) ... -- Got SIP response 503 "Service Unavailable" back from 192.168.12.2:5060 -- SIP/kiev-00000fb8 is circuit-busy == Everyone is busy/congested at this time (1:0/1/0) -- Auto fallthrough, channel 'SIP/kiev-00000fb7' status is 'CONGESTION' -- Executing [h@gr_relay:1] Playback("SIP/kiev-00000fb7", "vm-review") in new stack == Spawn extension (gr_relay, h, 1) exited non-zero on 'SIP/kiev-00000fb7' aster-3*CLI> Disconnected from Asterisk server Executing last minute cleanups Asterisk cleanly ending (0). |
#[default]
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core 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 'core show license' for details. ========================================================================= == Parsing '/etc/asterisk/asterisk.conf': == Found == Parsing '/etc/asterisk/extconfig.conf': == Found Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on aster-3 (pid = 7737) ... -- Executing [3102@gr1:1] Dial("SIP/1302-000011f2", "SIP/kiev/3102") in new stack == Using SIP RTP CoS mark 5 -- Called SIP/kiev/3102 -- SIP/kiev-000011f3 is ringing == Spawn extension (gr1, 3102, 1) exited non-zero on 'SIP/1302-000011f2' -- Executing [h@gr1:1] Playback("SIP/1302-000011f2", "vm-review") in new stack == Spawn extension (gr1, h, 1) exited non-zero on 'SIP/1302-000011f2' aster-3*CLI> exit Executing last minute cleanups Asterisk cleanly ending (0). |
#cd /usr/share/asterisk/sounds
|
#ls
custom en en_US en_US_f_Allison recordings |
#/usr/share/asterisk/sounds^C
|
#apt-get install asterisk-sounds-ru
Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package asterisk-sounds-ru |
#apt-get install asterisk-sounds-ru~~~~~~~~~~~~~~^C
|
#cd /etc/asterisk/
|
#nano extensions.conf
--- /tmp/l3-saved-8435.19117.11744 2014-04-23 15:57:08.509058148 +0300 +++ extensions.conf 2014-04-23 15:58:32.509059997 +0300 @@ -13,9 +13,10 @@ [internal] [local] - exten => _13XX,1,Dial(SIP/${EXTEN}) + + [national] exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _14XX,1,Dial(SIP/frankfurt/${EXTEN}) |
[default] ;exten => 1301,1,Answer ;exten => 1301,n,Dial(SIP/1301) ;exten => 1301,n,Hangup ;exten => _13XX,1,Dial(SIP/${EXTEN}) ;exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _1XXX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _3[12]XX,1,Dial(SIP/kiev/${EXTEN}) ;exten => _[23]XXX,1,Dial(SIP/vienna/${EXTEN}) [internal] [local] exten => _13XX,1,Dial(SIP/${EXTEN}) [national] exten => _23XX,1,Dial(SIP/frankfurt/${EXTEN}) ;exten => _14XX,1,Dial(SIP/frankfurt/${EXTEN}) [international] exten => _2[12]XX,1,Dial(SIP/vienna/${EXTEN}) exten => _1[12]XX,1,Dial(SIP/kiev/${EXTEN}) exten => _3[123]XX,1,Dial(SIP/vienna/${EXTEN}) [fallback] exten => _.,1,Playback(vm-review) [gr_relay] include => internal include => local include => national include => international include => fallback [gr1] include => internal include => local include => national include => international include => fallback [gr2] include => internal include => local include => national include => fallback [gr3] include => internal include => local include => fallback
[general] context=default directmedia=no register => berlin:1234@192.168.12.6/frankfurt register => berlin:1234@192.168.12.2/kiev register => berlin:1234@192.168.12.5/vienna [1301] type=friend secret=1234 host=dynamic [1302] type=friend secret=1234 host=dynamic [1303] type=friend secret=1234 host=dynamic [frankfurt] type=friend secret=1234 host=dynamic username=berlin [kiev] type=friend secret=1234 host=dynamic username=berlin [vienna] type=friend secret=1234 host=dynamic username=berlin
Время первой команды журнала | 11:31:53 2014- 4-23 | ||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 14:57:00 2014- 4-23 | ||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | ||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 3.96 | ||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 0.99 | ||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 3.42 | ||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.49 | ||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду w. В поле WHAT, соответствующем текущему терминалу, должна быть указана программа script.
Команды, при наборе которых были допущены синтаксические ошибки, выводятся перечёркнутым текстом:
$ l s-l bash: l: command not found |
Если код завершения команды равен нулю, команда была выполнена без ошибок. Команды, код завершения которых отличен от нуля, выделяются цветом.
$ test 5 -lt 4 |
Команды, ход выполнения которых был прерван пользователем, выделяются цветом.
$ find / -name abc find: /home/devi-orig/.gnome2: Keine Berechtigung find: /home/devi-orig/.gnome2_private: Keine Berechtigung find: /home/devi-orig/.nautilus/metafiles: Keine Berechtigung find: /home/devi-orig/.metacity: Keine Berechtigung find: /home/devi-orig/.inkscape: Keine Berechtigung ^C |
Команды, выполненные с привилегиями суперпользователя, выделяются слева красной чертой.
# id uid=0(root) gid=0(root) Gruppen=0(root) |
Изменения, внесённые в текстовый файл с помощью редактора, запоминаются и показываются в журнале в формате ed. Строки, начинающиеся символом "<", удалены, а строки, начинающиеся символом ">" -- добавлены.
$ vi ~/.bashrc
|
Для того чтобы изменить файл в соответствии с показанными в диффшоте изменениями, можно воспользоваться командой patch. Нужно скопировать изменения, запустить программу patch, указав в качестве её аргумента файл, к которому применяются изменения, и всавить скопированный текст:
$ patch ~/.bashrc |
Для того чтобы получить краткую справочную информацию о команде, нужно подвести к ней мышь. Во всплывающей подсказке появится краткое описание команды.
Если справочная информация о команде есть, команда выделяется голубым фоном, например: vi. Если справочная информация отсутствует, команда выделяется розовым фоном, например: notepad.exe. Справочная информация может отсутствовать в том случае, если (1) команда введена неверно; (2) если распознавание команды LiLaLo выполнено неверно; (3) если информация о команде неизвестна LiLaLo. Последнее возможно для редких команд.
Большие, в особенности многострочные, всплывающие подсказки лучше всего показываются браузерами KDE Konqueror, Apple Safari и Microsoft Internet Explorer. В браузерах Mozilla и Firefox они отображаются не полностью, а вместо перевода строки выводится специальный символ.
Время ввода команды, показанное в журнале, соответствует времени начала ввода командной строки, которое равно тому моменту, когда на терминале появилось приглашение интерпретатора
Имя терминала, на котором была введена команда, показано в специальном блоке. Этот блок показывается только в том случае, если терминал текущей команды отличается от терминала предыдущей.
Вывод не интересующих вас в настоящий момент элементов журнала, таких как время, имя терминала и других, можно отключить. Для этого нужно воспользоваться формой управления журналом вверху страницы.
Небольшие комментарии к командам можно вставлять прямо из командной строки. Комментарий вводится прямо в командную строку, после символов #^ или #v. Символы ^ и v показывают направление выбора команды, к которой относится комментарий: ^ - к предыдущей, v - к следующей. Например, если в командной строке было введено:
$ whoami
user
$ #^ Интересно, кто я?в журнале это будет выглядеть так:
$ whoami
user
Интересно, кто я? |
Если комментарий содержит несколько строк, его можно вставить в журнал следующим образом:
$ whoami
user
$ cat > /dev/null #^ Интересно, кто я?
Программа whoami выводит имя пользователя, под которым мы зарегистрировались в системе. - Она не может ответить на вопрос о нашем назначении в этом мире.В журнале это будет выглядеть так:
$ whoami user
|
Комментарии, не относящиеся непосредственно ни к какой из команд, добавляются точно таким же способом, только вместо симолов #^ или #v нужно использовать символы #=
1 2 3 4Группы команд, выполненных на разных терминалах, разделяются специальной линией. Под этой линией в правом углу показано имя терминала, на котором выполнялись команды. Для того чтобы посмотреть команды только одного сенса, нужно щёкнуть по этому названию.
LiLaLo (L3) расшифровывается как Live Lab Log.
Программа разработана для повышения эффективности обучения Unix/Linux-системам.
(c) Игорь Чубин, 2004-2008