Журнал лабораторных работ

Содержание

Журнал

Понедельник (11/24/14)

/dev/pts/2
17:17:22
#asterisk -r
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.
=========================================================================
Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on debian1 (pid = 13150)
Verbosity is at least 3
debian1*CLI> dialplan reload
...
    -- Called SIP/1102
    -- SIP/1102-00000007 is ringing
    -- SIP/1102-00000007 answered SIP/1101-00000006
    -- Remotely bridging SIP/1101-00000006 and SIP/1102-00000007
  == Spawn extension (default, 1102, 1) exited non-zero on 'SIP/1101-00000006'
    -- Remote UNIX connection
    -- Remote UNIX connection disconnected
    -- Remote UNIX connection
    -- Remote UNIX connection disconnected
debian1*CLI> exit

Вторник (11/25/14)

/dev/pts/6
08:45:51
#screen -x
/dev/pts/8
08:49:13
#cat /etc/asterisk/sip.conf
[general]
context=default
[1101]
type=friend
secret=1234
host=dynamic
[1102]
type=friend
secret=1234
host=dynamic
08:49:19
#asterisk -rv
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.
=========================================================================
Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on debian1 (pid = 2476)
Verbosity was 0 and is now 1
debian1*CLI> sip show peers
Name/username              Host                                    Dyn Forcerport ACL Port     Status
1101/1101                  192.168.10.100                           D   N             5060     Unmonitored
1102/1102                  192.168.10.101                           D   N             35840    Unmonitored
2 sip peers [Monitored: 0 online, 0 offline Unmonitored: 2 online, 0 offline]
debian1*CLI> quit
Executing last minute cleanups
/dev/pts/4
08:57:10
#asterisk -rv
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.
=========================================================================
Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on debian1 (pid = 2476)
Verbosity is at least 1
debian1*CLI>  sip reload
...
[Nov 25 09:58:16] NOTICE[2717]: chan_sip.c:20886 handle_response_peerpoke: Peer '1101' is now Reachable. (34ms / 2000ms)
debian1*CLI> sip show peers
Name/username              Host                                    Dyn Forcerport ACL Port     Status
1101/1101                  192.168.10.100                           D   N             5060     OK (18 ms)
1102/1102                  192.168.10.101                           D   N             35840    OK (6 ms)
2 sip peers [Monitored: 2 online, 0 offline Unmonitored: 0 online, 0 offline]
debian1*CLI> q
No such command 'q' (type 'core show help q' for other possible commands)
debian1*CLI> quit
Executing last minute cleanups
прошло 16 минут
09:14:03
#asterisk -r
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.
=========================================================================
Connected to Asterisk 1.8.13.1~dfsg1-3+deb7u3 currently running on debian1 (pid = 2476)
Verbosity is at least 2
debian1*CLI> sip show peers
Name/username              Host                                    Dyn Forcerport ACL Port     Status
1101/1101                  192.168.10.100                           D   N             5060     OK (12 ms)
1102/1102                  192.168.10.101                           D   N             35840    OK (6 ms)
2 sip peers [Monitored: 2 online, 0 offline Unmonitored: 0 online, 0 offline]
debian1*CLI> quit
/dev/pts/8
09:14:13
#asterisk -rvv
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 debian1 (pid = 2476)
Verbosity was 1 and is now 2
debian1*CLI> sip show peers
Name/username              Host                                    Dyn Forcerport ACL Port     Status
1101/1101                  192.168.10.100                           D   N             5060     OK (17 ms)
1102/1102                  192.168.10.101                           D   N             35840    OK (5 ms)
2 sip peers [Monitored: 2 online, 0 offline Unmonitored: 0 online, 0 offline]
debian1*CLI> quit
Executing last minute cleanups
прошло 10 минут
/dev/pts/4
09:24:53
#mkdir /var/tmp/asterisk

прошло 89 минут
10:53:57
#chown asterisk:asterisk /var/tmp/asterisk

10:54:09
#exten => _81XX,n,Record(/var/tmp/asterisk/record${EXTEN:2})
bash: syntax error near unexpected token `('
прошло 25 минут
11:19:51
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-4151.27751.30313	2014-11-25 12:19:57.682823318 +0200
+++ /etc/asterisk/extensions.conf	2014-11-25 12:20:28.850823687 +0200
@@ -1,5 +1,7 @@
 
 [default]
 
-exten => _81XX,1,Record(var/tmp/asterisk/record${EXTEN:2}:gsm)
-exten => _82XX,1,Playback(var/tmp/asterisk/record${EXTEN:2})
+exten => _11XX,1,Dial(SIP/${EXTEN})
+
+exten => _81XX,1,Record(/var/tmp/asterisk/record${EXTEN:2}:gsm)
+exten => _82XX,1,Playback(/var/tmp/asterisk/record${EXTEN:2})
прошло 79 минут
12:39:14
#sip reload
bash: sip: command not found
12:42:28
#vi /etc/asterisk/extensions.conf
12:52:16
#vi /etc/asterisk/extensions.conf
--- /tmp/l3-saved-4151.11684.29861	2014-11-25 13:52:53.478889312 +0200
+++ /etc/asterisk/extensions.conf	2014-11-25 13:56:56.794892193 +0200
@@ -5,3 +5,4 @@
 
 exten => _81XX,1,Record(/var/tmp/asterisk/record${EXTEN:2}:gsm)
 exten => _82XX,1,Playback(/var/tmp/asterisk/record${EXTEN:2})
+exten => _1[12]XX,1,Dial(SIP/komsomolsk/${EXTEN})
прошло 29 минут
13:21:24
#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 debian1 (pid = 2476)
...
    -- Locally bridging SIP/komsomolsk-00000062 and SIP/1101-00000063
  == Spawn extension (default, 1101, 1) exited non-zero on 'SIP/komsomolsk-00000062'
  == Using SIP RTP CoS mark 5
    -- Executing [1102@default:1] Dial("SIP/1101-00000064", "SIP/1102") in new stack
  == Using SIP RTP CoS mark 5
    -- Called SIP/1102
    -- SIP/1102-00000065 is ringing
  == Spawn extension (default, 1102, 1) exited non-zero on 'SIP/1101-00000064'
debian1*CLI> quit
Executing last minute cleanups
прошло 65 минут
14:26:24
#username=kiev
include => international
[gr1]
[gr1]
[gr2]
[gr2]de => internal
[gr2]
include => local
include => national
[gr3]
[gr3]
include => internal
include => local
[gr4]
[gr4]
include => internal
include => local
include => national
include => international
-- INSERT --                                                  48,1          90%
прошло 12 минут
14:39:15
#vi /etc/asterisk/sip.conf
14:41:51
#[ ]
exten => _81XX,1,Record(/var/tmp/asterisk/record${EXTEN:2}:gsm)
exten => _82XX,1,Playback(/var/tmp/asterisk/record${EXTEN:2})
exten => _12XX,1,Dial(SIP/komsomolsk/${EXTEN})
exten => _[12]3XX,1,Dial(SIP/minsk/${EXTEN})
exten => _[23][123]XX,1,Dial(SIP/ny/${EXTEN})
[local]
exten => _11XX,1,Dial(SIP/${EXTEN})
[national]
exten => _12XX,1,Dial(SIP/komsomolsk/${EXTEN})
[international]
"/etc/asterisk/extensions.conf" 49L, 775C
exten => _[23][123]XX,1,Dial(SIP/ny/${EXTEN})
[gr1]
include => internal
include => local
include => national
include => international
[gr2]
include => internal
include => local
include => national
14:42:00
#[gr3]
secret=1234
host=dynamic
context=gr1
[1102]
type=friend
secret=1234
host=dynamic
context=gr3
"/etc/asterisk/sip.conf" 41L, 506C
[komsomolsk]
...
username=kiev
[minsk]
type=friend
host=dynamic
secret=1234
directmedia=no
username=kiev
[ny]
type=friend
host=dynamic
14:48:41
#vi /etc/asterisk/sip.conf
14:54:21
#vi /etc/asterisk/sip.conf
15:00:53
#vi /etc/asterisk/extensions.conf
15:10:01
#include => local
context=gr3
"/etc/asterisk/sip.conf" 44L, 542C
[komsomolsk]
type=friend
host=dynamic
secret=1234
directmedia=no
username=kiev
context=gr4
[minsk]
type=friend
host=dynamic
secret=1234
directmedia=no
username=kiev
context=gr4
[ny]
/dev/pts/8
15:11:32
#asterisk -rvv
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 debian1 (pid = 2476)
Verbosity is at least 3
debian1*CLI>
debian1*CLI>
debian1*CLI>
  == Using SIP RTP CoS mark 5
[Nov 25 16:11:36] NOTICE[2717]: chan_sip.c:22753 handle_request_invite: Call from 'kiev' (192.168.40.1:5060) to extension '1301' rejected because extension not found in context 'gr4'.
  == Spawn extension (gr4, 1201, 1) exited non-zero on 'SIP/ny-0000030e'
  == Using SIP RTP CoS mark 5
[Nov 25 16:11:40] NOTICE[2717]: chan_sip.c:22753 handle_request_invite: Call from 'kiev' (192.168.40.1:5060) to extension '1301' rejected because extension not found in context 'gr4'.
debian1*CLI> quit
Executing last minute cleanups
15:11:41
#vim /etc/asterisk/extensions.conf
/dev/pts/4
15:11:49
#type=friend
E325: ATTENTION
Found a swap file by the name "/etc/asterisk/.extensions.conf.swp"
          owned by: root   dated: Tue Nov 25 16:11:47 2014
         file name: /etc/asterisk/extensions.conf
          modified: no
         user name: root   host name: debian1
        process ID: 7200 (still running)
While opening file "/etc/asterisk/extensions.conf"
             dated: Tue Nov 25 15:57:13 2014
[             ]
...
include => internal
include => local
include => national
include => international
                                                              46,0-1        88%
Press ENTER or type command to continue
    to avoid this message. (see ":help recovery").
    If you did this already, delete the swap file "/etc/asterisk/.extensions.co
Swap file "/etc/asterisk/.extensions.conf.swp" already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (Q)uit, (A)bort:
/dev/pts/8
15:13:22
#less /var/log/asterisk/messages
/dev/pts/4
15:15:27
#qualify=yes
exten => _[23][123]XX,1,Dial(SIP/ny/${EXTEN})
"/etc/asterisk/extensions.conf" 48L, 658C
exten => _[12]3XX,1,Dial(SIP/minsk/${EXTEN})
[gr1]
include => internal
include => local
include => national
include => international
[gr2]
include => internal
include => local
include => national
[gr3]
15:16:33
#include => internal
[general]
context=default
qualify=yes
register => kiev:1234@192.168.20.1/komsomolsk
register => kiev:1234@192.168.30.1/minsk
"/etc/asterisk/sip.conf" 44L, 542C
[egister]=> kiev:1234@192.168.40.1/ny
[1101]
type=friend
[1101]=1234
...
context=gr4
[minsk]
type=friend
host=dynamic
secret=1234
directmedia=no
username=kiev
context=gr4
[ny]
type=friend
/dev/pts/8
15:25:13
#ls /var/tmp/asterisk/
record01.gsm  record02.gsm
/dev/pts/4
15:26:46
#apt-cache search sox gsm fmt
sox - Swiss army knife of sound processing
15:26:56
#apt-cache search sox gsm
asterisk-core-sounds-en-gsm - asterisk PBX sound files - en-us/gsm
asterisk-core-sounds-es-gsm - asterisk PBX sound files - es-mx/gsm
asterisk-core-sounds-fr-gsm - asterisk PBX sound files - fr-ca/gsm
asterisk-core-sounds-ru-gsm - asterisk PBX sound files - ru-ru/gsm
asterisk-moh-opsound-gsm - asterisk extra sound files - English/gsm
asterisk-prompt-it-menardi-gsm - asterisk PBX Italian sound files - gsm prompts
libsox-fmt-base - Minimal set of SoX format libraries
sox - Swiss army knife of sound processing
15:27:10
#apt-get install sox libsox-fmt-base
Reading package lists... Done
Building dependency tree
Reading state information... Done
libsox-fmt-base is already the newest version.
libsox-fmt-base set to manually installed.
sox is already the newest version.
sox set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
15:27:21
##play /path/to/a/gsm/file.gsm

15:28:00
#play /path/to/a/gsm/file.gsm
play WARN alsa: can't encode 0-bit Unknown or not applicable
play FAIL formats: can't open input file `/path/to/a/gsm/file.gsm': No such file or directory
15:28:26
#apt-get install sendmail-mta
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package sendmail-mta
15:29:30
#apt-get install sendmail-bin
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  sendmail-base sendmail-cf
Suggested packages:
  sendmail-doc logcheck resolvconf sasl2-bin
The following packages will be REMOVED:
  exim4 exim4-base exim4-config exim4-daemon-light
The following NEW packages will be installed:
...
Warning: These messages were issued while creating sendmail.cf
        make sure they are benign before starting sendmail!
Errors in generating sendmail.cf
*** ERROR: FEATURE() should be before MAILER()
*** MAILER(`local') must appear after FEATURE(`always_add_domain')*** ERROR: FEATURE() should be before MAILER()
*** MAILER(`local') must appear after FEATURE(`allmasquerade')*** ERROR: FEATURE() should be before MAILER()
Starting Mail Transport Agent (MTA): sendmail.
(Reading database ... 132029 files and directories currently installed.)
Removing exim4-base ...
Processing triggers for man-db ...
15:32:20
#cat /etc/mail/local-host-names
localhost
debian1
15:32:58
#echo debian1.unix.nt >> /etc/mail/local-host-names

15:38:05
#/etc/init.d/sendmail restart
Restarting Mail Transport Agent (MTA): sendmail.
15:41:29
#grep 127 /etc/hosts
127.0.0.1       localhost
127.0.1.1       debian1
15:46:19
#~
Restarting Mail Transport Agent (MTA): sendmail.

Среда (11/26/14)

08:59:35
#vi /etc/asterisk/voicemail.conf
прошло 11 минут
09:11:17
#vi /etc/asterisk/voicemail.conf
--- /tmp/l3-saved-4151.8539.6421	2014-11-26 10:11:19.963754588 +0200
+++ /etc/asterisk/voicemail.conf	2014-11-26 10:16:33.427758297 +0200
@@ -381,6 +381,7 @@
 
 [default]
 
+1101 => 1234,User 1 (1101),user@localhost
 1234 => 4242,Example Mailbox,root@localhost
 ;4200 => 9855,Mark Spencer,markster@linux-support.net,mypager@digium.com,attach=no|serveremail=myaddy@digium.com|tz=central|maxmsg=10
 ;4300 => 3456,Ben Rigas,ben@american-computer.net
09:18:10
#vi /etc/asterisk/voicemail.conf
/dev/pts/6
09:19:47
#less /var/log/asterisk/messages
/dev/pts/4
09:28:29
#vi /etc/asterisk/voicemail.conf
прошло 14 минут
09:42:39
#vi /etc/asterisk/extensions.conf
--- /tmp/l3-saved-4151.5865.19120	2014-11-26 10:45:45.303779036 +0200
+++ /etc/asterisk/extensions.conf	2014-11-26 10:48:23.967780912 +0200
@@ -7,7 +7,7 @@
 exten => _81XX,1,Record(/var/tmp/asterisk/record${EXTEN:2}:gsm)
 exten => _82XX,1,Playback(/var/tmp/asterisk/record${EXTEN:2})
 exten => 8001,1,VoiceMailMain()
-exten => 8300,1,VoiceMailMain(11${EXTEN:2}@default)
+exten => _83XX,1,VoiceMailMain(11${EXTEN:2}@default)
 
 
 [local]
прошло 19 минут
/dev/pts/6
10:02:11
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-14629.7039.24265	2014-11-26 11:02:16.051790759 +0200
+++ /etc/asterisk/extensions.conf	2014-11-26 11:03:29.911791634 +0200
@@ -12,7 +12,8 @@
 
 [local]
 
-exten => _11XX,1,Dial(SIP/${EXTEN})
+; не было таймаута в Dial
+exten => _11XX,1,Dial(SIP/${EXTEN},5)
 exten => _11XX,n,VoiceMail(${EXTEN}@default)
 
 
10:03:29
#less /etc/asterisk/voicemail.conf
/dev/pts/4
10:10:45
#vi /etc/asterisk/extensions.conf
прошло 42 минуты
10:53:11
#vi /etc/asterisk/sip.conf
--- /tmp/l3-saved-4151.5545.10515	2014-11-26 11:53:18.283827004 +0200
+++ /etc/asterisk/sip.conf	2014-11-26 11:53:52.031827403 +0200
@@ -12,7 +12,7 @@
 host=dynamic
 context=gr1
 mailbox=1101@default
-language=fr
+language=ru
 
 [1102]
 type=friend
@@ -20,7 +20,7 @@
 host=dynamic
 context=gr1
 mailbox=1102@default
-language=de
+language=ru
 
 [komsomolsk]
 type=friend
11:00:55
#cat /tmp/1
cat: /tmp/1: No such file or directory
11:01:34
#.tar.gz.tar.gz
bash: .tar.gz.tar.gz: command not found
11:02:16
#.tar.gz
bash: .tar.gz: command not found
11:04:16
#tar xfz asterisk-core-sounds-ru-gsm-current.tar.gz

прошло 19 минут
11:24:00
#vi /etc/asterisk/extensions.conf
--- /tmp/l3-saved-4151.4448.29592	2014-11-26 12:24:14.139848969 +0200
+++ /etc/asterisk/extensions.conf	2014-11-26 12:40:08.083860261 +0200
@@ -17,6 +17,8 @@
 ; не было таймаута в Dial
 exten => _11XX,1,Dial(SIP/${EXTEN},5)
 exten => _11XX,n,VoiceMail(${EXTEN}@default)
+exten => _11XX,n,Set(CALLFILENAME=${EXTEN:1}-${CALLERID(num)}-${STRFTIME(${EPOCH},Europe/Kiev,"%Y-%m-%d-%H:%M:%S")})
+exten => _11XX,n,Monitor(wav,${CALLFILENAME},m)
 
 
 [national]
прошло 16 минут
11:40:19
#vi /etc/asterisk/extensions.conf
--- /tmp/l3-saved-4151.17263.22476	2014-11-26 13:09:00.887880773 +0200
+++ /etc/asterisk/extensions.conf	2014-11-26 13:12:21.443883143 +0200
@@ -17,7 +17,7 @@
 ; не было таймаута в Dial
 exten => _11XX,1,Dial(SIP/${EXTEN},5)
 exten => _11XX,n,VoiceMail(${EXTEN}@default)
-exten => _11XX,n,Set(CALLFILENAME=${EXTEN:1}-${CALLERID(num)}-${STRFTIME(${EPOCH},Europe/Kiev,"%Y-%m-%d-%H:%M:%S")})
+exten => _11XX,n,Set(CALLFILENAME=${EXTEN}-${CALLERID(num)}-${STRFTIME(${EPOCH},Europe/Kiev,"%Y-%m-%d-%H:%M:%S")})
 exten => _11XX,n,Monitor(wav,${CALLFILENAME},m)
 
 
прошло 36 минут
12:16:38
#ls /var/spool/asterisk/monitor

/dev/pts/8
12:17:29
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-16416.7309.110	2014-11-26 13:17:36.991886876 +0200
+++ /etc/asterisk/extensions.conf	2014-11-26 13:18:04.003887196 +0200
@@ -15,10 +15,11 @@
 [local]
 
 ; не было таймаута в Dial
-exten => _11XX,1,Dial(SIP/${EXTEN},5)
+exten => _11XX,1,NoOp(Processing local calls)
 exten => _11XX,n,VoiceMail(${EXTEN}@default)
 exten => _11XX,n,Set(CALLFILENAME=${EXTEN}-${CALLERID(num)}-${STRFTIME(${EPOCH},Europe/Kiev,"%Y-%m-%d-%H:%M:%S")})
 exten => _11XX,n,Monitor(wav,${CALLFILENAME},m)
+exten => _11XX,n,Dial(SIP/${EXTEN},5)
 
 
 [national]
12:18:04
#asterisk -vvv
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
Privilege escalation protection disabled!
See https://wiki.asterisk.org/wiki/x/1gKfAQ for more details.
  == Parsing '/etc/asterisk/extconfig.conf':   == Found
Asterisk already running on /var/run/asterisk/asterisk.ctl.  Use 'asterisk -r' to connect.
12:18:09
#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 debian1 (pid = 2476)
...
    -- merging incls/swits/igpats from old(demo) to new(demo) context, registrar = pbx_config
    -- Including switch 'Lua/' in context 'demo'
    -- Time to scan old dialplan and merge leftovers back into the new: 0.001541 sec
    -- Time to restore hints and swap in new dialplan: 0.000005 sec
    -- Time to delete the old dialplan: 0.000088 sec
    -- Total time merge_contexts_delete: 0.001634 sec
debian1*CLI>
debian1*CLI>
debian1*CLI> quit
Executing last minute cleanups
/dev/pts/8
12:22:02
#less /etc/asterisk/extensions.conf
12:22:14
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-16647.21282.24786	2014-11-26 13:22:16.051890181 +0200
+++ /etc/asterisk/extensions.conf	2014-11-26 13:22:23.759890270 +0200
@@ -16,10 +16,10 @@
 
 ; не было таймаута в Dial
 exten => _11XX,1,NoOp(Processing local calls)
-exten => _11XX,n,VoiceMail(${EXTEN}@default)
 exten => _11XX,n,Set(CALLFILENAME=${EXTEN}-${CALLERID(num)}-${STRFTIME(${EPOCH},Europe/Kiev,"%Y-%m-%d-%H:%M:%S")})
 exten => _11XX,n,Monitor(wav,${CALLFILENAME},m)
 exten => _11XX,n,Dial(SIP/${EXTEN},5)
+exten => _11XX,n,VoiceMail(${EXTEN}@default)
 
 
 [national]
прошло 14 минут
/dev/pts/4
12:36:40
#[ ]
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libmpg123-0
Suggested packages:
  alsa-utils jackd nas oss-compat oss4-base
The following NEW packages will be installed:
  libmpg123-0 mpg123
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
...
(Reading database ... 133180 files and directories currently installed.)
Unpacking libmpg123-0:amd64 (from .../libmpg123-0_1.14.4-1_amd64.deb) ...
Selecting previously unselected package mpg123.
Unpacking mpg123 (from .../mpg123_1.14.4-1_amd64.deb) ...
Processing triggers for man-db ...
Processing triggers for mime-support ...
Setting up libmpg123-0:amd64 (1.14.4-1) ...
Setting up mpg123 (1.14.4-1) ...
update-alternatives: using /usr/bin/mpg123.bin to provide /usr/bin/mpg123 (mpg123) in auto mode
update-alternatives: using /usr/bin/mpg123.bin to provide /usr/bin/mp3-decoder (mp3-decoder) in auto mode
12:40:14
#mpg123 -w /tmp/adele.wav /home/user/Downloads/
queen_-_show_must_go_on_(zaycev.net).mp3
X-Lite_Win32_4.7.1_74247.exe
12:40:39
#sox -t wav /tmp/queen.wav -r 8000 -c1 -t gsm /tmp/queen.gsm

12:41:01