/l3/users/LKudrich/voip/linux7.unix.nt.unix.nt/root :1 :2 :3 :4 |
|
#ls /var/spool/asterisk/monitor
voice-1701-1801-1288178506-in.wav voice-1701-1801-1288178529-out.wav voice-1701-1801-1288178506-out.wav voice-1701-1801-1288178653-in.wav voice-1701-1801-1288178529-in.wav voice-1701-1801-1288178653-out.wav |
#мÑvim /etc/samba/smb.conf
# Only bind to the named interfaces and/or networks; you must use the # 'interfaces' option above to use this. # It is recommended that you enable this feature if your Samba machine is # not protected by a firewall or is a firewall itself. However, this # option cannot handle dynamic or non-broadcast interfaces correctly. ; bind interfaces only = yes #### Debugging/Accounting #### 74,1 16% # This allows Unix users to be created on the domain controller via the SAMR # RPC pipe. The example command creates a user account with a disabled Unix ... ; postexec = /bin/umount /cdrom 326,0-1 ÐÐ½Ð¸Ð·Ñ [monitor] [ ] -- ÐСТР--ÐÐ -- 327,10 ÐÐ½Ð¸Ð·Ñ path=/var/spool/asterisk/monitor read only = yes 329,15 ÐÐ½Ð¸Ð·Ñ "/etc/samba/smb.conf" 329L, 11980C запиÑано ~ |
#usermod -G leonid asterisk
|
#smbpasswd leonid
New SMB password: Retype new SMB password: |
#/etc/init.d/smb restart
bash: /etc/init.d/smb: Нет такого файла или каталога |
#/etc/init.d/samba restart
Stopping Samba daemons: nmbd smbd. Starting Samba daemons: nmbd smbd. |
#not protected by a firewall or is a firewall itself. However, this
|
#[
voice-1701-1801-1288178506-in.wav voice-1701-1801-1288178529-out.wav voice-1701-1801-1288178506-out.wav voice-1701-1801-1288178653-in.wav voice-1701-1801-1288178529-in.wav voice-1701-1801-1288178653-out.wav |
#You may need to replace 'lpadmin' with the name of the group your
proxy:x:13:" 60L, 816C kmem:x:15: dialout:x:20:leonid fax:x:21: voice:x:22: cdrom:x:24:leonid floppy:x:25:leonid tape:x:26: sudo:x:27: audio:x:29:leonid ... stb-admin:x:114: haldaemon:x:115: powerdev:x:116:leonid leonid:x:1000:asterisk asterisk:x:117: smmta:x:118: leonid smmsp:x:119: sambashare:x:120: "/etc/group" 60L, 822C записано |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) exten => _1[234]XX,1,Dial(SIP/kv/${EXTEN}) exten => _12XX,1,Dial(SIP/kv/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) exten => _1[234]XX,1,Dial(SIP/kv/${EXTEN}) exten => _12XX,1,Dial(SIP/kv/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) exten => _1[234]XX,1,Dial(SIP/kv/${EXTEN}) exten => _12XX,1,Dial(SIP/kv/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#ps -ax
Warning: bad ps syntax, perhaps a bogus '-'? See http://procps.sf.net/faq.html PID TTY STAT TIME COMMAND 1 ? Ss 0:01 init [2] 2 ? S< 0:00 [kthreadd] 3 ? S< 0:00 [migration/0] 4 ? S< 0:00 [ksoftirqd/0] 5 ? S< 0:00 [watchdog/0] 6 ? S< 0:00 [migration/1] 7 ? S< 0:00 [ksoftirqd/1] 8 ? S< 0:00 [watchdog/1] ... 3839 tty4 S+ 0:00 script -f -c bash -q /root/.lilalo//23563113127144298 3840 pts/3 Ss 0:00 bash 5011 ? Ssl 0:01 /usr/sbin/asterisk -p -U asterisk 5053 pts/2 S+ 0:00 rasterisk rvvv 6078 ? S<s 0:00 /usr/sbin/nmbd -D 6080 ? S<s 0:00 /usr/sbin/smbd -D 6093 ? S< 0:00 /usr/sbin/smbd -D 6098 ? S< 0:00 /usr/sbin/smbd -D 6157 pts/3 S+ 0:00 ssh linux8 6223 pts/1 R+ 0:00 ps -ax |
#ps -ax | grep monitor
Warning: bad ps syntax, perhaps a bogus '-'? See http://procps.sf.net/faq.html 6241 pts/1 S+ 0:00 grep monitor |
#--
exten => _19XX,1,Dial(SIP/bb/${EXTEN}) exten => _1XXX,1,Dial(SIP/kv/${EXTEN}) exten => _2XXX,1,Dial(SIP/bb/${EXTEN}) [local] [local] [local] exten => _17XX,1,Answer exten => _17XX,n,Monitor(wav,${FILENAME},m) et(FILENAME=voice-${EXTEN}-${CALLERID(num)}-${EPOCH}) exten => _17XX,n,Dial(SIP/${EXTEN},10,g) exten => _17XX,n,GotoIf($[${DIALSTATUS} = ANSWER]?answer) "/etc/asterisk/extensions.conf" 69L, 1881C записано |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#apt-get install lame
Чтение списков пакетов... Готово Построение дерева зависимостей Чтение информации о состоянии... Готово Пакет lame недоступен, но упомянут в списке зависимостей другого пакета. Это может означать, что пакет отсутствует, устарел, или доступен из источников, не упомянутых в sources.list E: Для пакета lame не найдены кандидаты на установку |
#vi /etc/apt/sources.list
--- /tmp/l3-saved-3431.4752.14042 2010-10-27 16:22:47.000000000 +0400 +++ /etc/apt/sources.list 2010-10-27 16:23:47.000000000 +0400 @@ -11,3 +11,5 @@ deb http://volatile.debian.org/debian-volatile lenny/volatile main deb-src http://volatile.debian.org/debian-volatile lenny/volatile main + +deb http://www.debian-multimedia.org/ lenny main |
#apt-get update
Получено:1 http://www.debian-multimedia.org lenny Release.gpg [198B] Игн http://www.debian-multimedia.org lenny/main Translation-ru В кеше http://security.debian.org lenny/updates Release.gpg Игн http://security.debian.org lenny/updates/main Translation-ru Получено:2 http://www.debian-multimedia.org lenny Release [26,5kB] В кеше http://security.debian.org lenny/updates Release Игн http://security.debian.org lenny/updates/main Packages/DiffIndex Игн http://www.debian-multimedia.org lenny Release Игн http://security.debian.org lenny/updates/main Sources/DiffIndex Получено:3 http://www.debian-multimedia.org lenny/main Packages [66,3kB] ... Игн http://10.0.35.1 lenny/main Packages/DiffIndex Игн http://10.0.35.1 lenny/main Sources/DiffIndex Игн http://10.0.35.1 lenny/main Packages Игн http://10.0.35.1 lenny/main Sources В кеше http://10.0.35.1 lenny/main Packages В кеше http://10.0.35.1 lenny/main Sources Получено 443kБ за 12s (34,6kБ/c) Чтение списков пакетов... Готово W: GPG error: http://www.debian-multimedia.org lenny Release: Следующие подписи не могут быть проверены, так как недоступен открытый ключ: NO_PUBKEY 07DC563D1F41B907 W: Вы можете запустить 'apt-get update' для исправления этих ошибок |
#apt-get install lame
Чтение списков пакетов... Готово Построение дерева зависимостей Чтение информации о состоянии... Готово НОВЫЕ пакеты, которые будут установлены: lame обновлено 0, установлено 1 новых пакетов, для удаления отмечено 0 пакетов, и 4 пакетов не обновлено. Необходимо скачать 334kБ архивов. После данной операции, объём занятого дискового пространства возрастёт на 721kB. ВНИМАНИЕ: Следующие пакеты невозможно аутентифицировать! lame Установить эти пакеты без проверки [y/N]? y Получено:1 http://www.debian-multimedia.org lenny/main lame 3.98.2-0.4 [334kB] Получено 334kБ за 6s (54,7kБ/c) Выбор ранее не выбранного пакета lame. (Чтение базы данных... на данный момент установлено 102005 файлов и каталогов.) Распаковывается пакет lame (из файла .../lame_3.98.2-0.4_i386.deb)... Обрабатываются триггеры для man-db ... Настраивается пакет lame (3.98.2-0.4) ... |
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-3431.8184.26028 2010-10-27 17:00:40.000000000 +0400 +++ /etc/asterisk/extensions.conf 2010-10-27 17:04:34.000000000 +0400 @@ -20,18 +20,18 @@ [macro-answer-with-monitor] exten => s,1,Answer -exten => s,n,Set(FILENAME=voice-${EXTEN}-${CALLERID(num)}-${EPOCH}) +exten => s,n,Set(FILENAME=voice-${ARG1}-${CALLERID(num)}-${EPOCH}) exten => s,n,Monitor(wav,${FILENAME},m) -exten => s,n,Dial(SIP/${EXTEN},10,g) -exten => s,n,GotoIf($[${DIALSTATUS} = ANSWER]?answer) +exten => s,n,Dial(SIP/${ARG1},10,g) +;exten => s,n,GotoIf($[${DIALSTATUS} = ANSWER]?answer) exten => s,n,GotoIf($[${DIALSTATUS} = BUSY]?busy:unavail) exten => s,n(unavail),Playback(voicemail-greeting-${EXTEN}) -exten => s,n,Voicemail(${EXTEN}@default) +exten => s,n,Voicemail(${ARG1}@default) exten => s,n(busy),Hangup -exten => s,n(answer),StopMonitor -exten => s,n,System(lame /var/spool/asterisk/${FILENAME}.wav /var/spool/asterisk/${FILENAME}.mp3) +;exten => s,n(answer),StopMonitor +;exten => s,n,System(lame /var/spool/asterisk/${FILENAME} /var/spool/asterisk/${FILENAME}.mp3) exten => h,n(answer),StopMonitor -exten => h,n,System(lame /var/spool/asterisk/${FILENAME}.wav /var/spool/asterisk/${FILENAME}.mp3) +exten => h,n,System(lame /var/spool/asterisk/${FILENAME} /var/spool/asterisk/${FILENAME}.mp3) [local] exten => _17XX,1,Macro(answer-with-monitor,${EXTEN}) |
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-3431.9732.17868 2010-10-27 17:07:59.000000000 +0400 +++ /etc/asterisk/extensions.conf 2010-10-27 17:08:23.000000000 +0400 @@ -25,7 +25,7 @@ exten => s,n,Dial(SIP/${ARG1},10,g) ;exten => s,n,GotoIf($[${DIALSTATUS} = ANSWER]?answer) exten => s,n,GotoIf($[${DIALSTATUS} = BUSY]?busy:unavail) -exten => s,n(unavail),Playback(voicemail-greeting-${ARG1}) +exten => s,n(unavail),Playback(voicemail-greeting) exten => s,n,Voicemail(${ARG1}@default) exten => s,n(busy),Hangup ;exten => s,n(answer),StopMonitor |
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-3431.18129.29961 2010-10-27 17:10:57.000000000 +0400 +++ /etc/asterisk/extensions.conf 2010-10-27 17:21:28.000000000 +0400 @@ -21,6 +21,8 @@ [macro-answer-with-monitor] exten => s,1,Answer exten => s,n,Set(FILENAME=voice-${ARG1}-${CALLERID(num)}-${EPOCH}) +exten => s,n,Set(FILENAME=voice-${ARG1}-${CALLERID(num)}-${EPOCH}) + exten => s,n,Monitor(wav,${FILENAME},m) exten => s,n,Dial(SIP/${ARG1},10,g) ;exten => s,n,GotoIf($[${DIALSTATUS} = ANSWER]?answer) @@ -30,8 +32,8 @@ exten => s,n(busy),Hangup ;exten => s,n(answer),StopMonitor ;exten => s,n,System(lame /var/spool/asterisk/${FILENAME} /var/spool/asterisk/${FILENAME}.mp3) -exten => h,n(answer),StopMonitor -exten => h,n,System(lame /var/spool/asterisk/${FILENAME} /var/spool/asterisk/${FILENAME}.mp3) +;exten => h,n(answer),StopMonitor +;exten => h,n,System(lame /var/spool/asterisk/${FILENAME} /var/spool/asterisk/${FILENAME}.mp3) [local] exten => _17XX,1,Macro(answer-with-monitor,${EXTEN}) |
#vim /usr/local/monitor_exec
|
#~
|
#~
bin etc games include lib man sbin share src |
#ls /usr/local/share
applications desktop-directories icons mime ppd xml asterisk fonts man perl sgml |
#ls /usr/local/bin
l3-agent l3-config l3script monitor_exec |
#ls /var/spool/asterisk
dictate meetme monitor outgoing system tmp voicemail |
#ls /var/spool/asterisk/voicemail
default |
#ls /var/spool/asterisk/voicemail/default
1701 |
#ls /var/spool/asterisk/voicemail/default/1701
INBOX Old temp tmp |
#ls /var/spool/asterisk/voicemail/default/1701/inbox
ls: невозможно получить доступ к /var/spool/asterisk/voicemail/default/1701/inbox: Нет такого файла или каталога |
#ls /var/spool/asterisk/voicemail/default/1701/INBOX/
msg0000.gsm msg0000.wav msg0001.gsm msg0001.wav msg0000.txt msg0000.WAV msg0001.txt msg0001.WAV |
#ls /var/spool/asterisk/voicemail/default/1701/
INBOX Old temp tmp |
#ls /var/spool/asterisk/voicemail/default/1701/Old
|
#ls /var/spool/asterisk/voicemail/default/1701/Old/
|
#ls /var/spool/asterisk/voicemail/default/1701/temp/
|
#ls /var/spool/asterisk/voicemail/default/1701/temp
|
#ls /var/spool/asterisk/voicemail/default/1701/tmp
|
#mc
|
#ssh linux8.unix.nt
The authenticity of host 'linux8.unix.nt (192.168.108.1)' can't be established. RSA key fingerprint is da:4a:92:81:55:fc:a8:1b:fd:c8:e4:7a:2e:68:f0:fa. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added 'linux8.unix.nt' (RSA) to the list of known hosts. root@linux8.unix.nt's password: Linux linux8.unix.nt 2.6.26-2-686 #1 SMP Thu Sep 16 19:35:51 UTC 2010 i686 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Wed Oct 27 17:03:14 2010 from 192.168.112.2 l3-agent is already running: pid=21823; pidfile=/root/.lilalo/l3-agent.pid |
#ls /var/spool/asterisk/voicemail/default/1701/INBOX/
msg0000.gsm msg0000.WAV msg0001.wav msg0002.txt msg0003.gsm msg0003.WAV msg0000.txt msg0001.gsm msg0001.WAV msg0002.wav msg0003.txt msg0000.wav msg0001.txt msg0002.gsm msg0002.WAV msg0003.wav |
#ls /var/spool/asterisk
dictate meetme monitor outgoing system tmp voicemail |
#ls /var/spool/asterisk/
dictate meetme monitor outgoing sounds system tmp voicemail |
#play msg000.wav
play soxio: Can't open input file `msg000.wav': No such file or directory |
#play /var/spool/asterisk/sounds/msg000.wav
play soxio: Can't open input file `/var/spool/asterisk/sounds/msg000.wav': No such file or directory |
#play /var/spool/asterisk/sounds/msg0000.wav
Input File : '/var/spool/asterisk/sounds/msg0000.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:19.98 [00:00.00] of 00:19.98 (100% ) Samples out: 959k Clips: 25 play effects: resample clipped 20 samples; decrease volume? play sox: alsa: output clipped 5 samples; decrease volume? Done. |
#play /var/spool/asterisk/sounds/msg0000.wav
Input File : '/var/spool/asterisk/sounds/msg0000.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:19.98 [00:00.00] of 00:19.98 (100% ) Samples out: 959k Clips: 25 play effects: resample clipped 20 samples; decrease volume? play sox: alsa: output clipped 5 samples; decrease volume? Done. |
#ls
msg-4.wav |
#mv msg-4.wav /var/spool/asterisk/sounds/msg-4.wav
|
#play /var/spool/asterisk/sounds/msg0002.wav
-5.wav Input File : '/var/spool/asterisk/sounds/msg-5.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:03.30 [00:00.00] of 00:03.30 (100% ) Samples out: 158k Clips: 141 play effects: resample clipped 119 samples; decrease volume? play sox: alsa: output clipped 22 samples; decrease volume? Done. |
#play /var/spool/asterisk/sounds/msg0002.wav
ls /var/spool/asterisk/sounds/ msg0001.wav msg0003.wav msg-4.wav msg-5.wav |
#play /var/spool/asterisk/sounds/msg0001.wav
Input File : '/var/spool/asterisk/sounds/msg0001.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:02.72 [00:00.00] of 00:02.72 (100% ) Samples out: 131k Clips: 9 play effects: resample clipped 9 samples; decrease volume? Done. |
#play /var/spool/asterisk/sounds/msg0001.wav
-6.wav Input File : '/var/spool/asterisk/sounds/msg-6.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:02.72 [00:00.00] of 00:02.72 (100% ) Samples out: 131k Clips: 9 play effects: resample clipped 9 samples; decrease volume? Done. |
#play /var/spool/asterisk/sounds/msg0001.wav
ls /var/spool/asterisk/sounds/ msg0003.wav msg-4.wav msg-5.wav msg-6.wav |
#play /var/spool/asterisk/sounds/msg0003.wav
ls /var/spool/asterisk/sounds/ msg-4.wav msg-5.wav msg-6.wav msg-7.wav |
#ls /var/spool/asterisk/sounds/
|
#play /var/spool/asterisk/sounds/msg0003.wav
|
#play /var/spool/asterisk/sounds/msg0001.wav
|
#play /var/spool/asterisk/sounds/msg0002.wav
spool/asterisk/sounds/ar/spool/asterisk/voicemail/default/1701/INBOX/*.wav /var/s |
#play /var/spool/asterisk/sounds/msg0003.wav
0.wav Input File : '/var/spool/asterisk/sounds/msg0000.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:19.98 [00:00.00] of 00:19.98 (100% ) Samples out: 959k Clips: 25 play effects: resample clipped 20 samples; decrease volume? play sox: alsa: output clipped 5 samples; decrease volume? Done. |
#play /var/spool/asterisk/sounds/msg0000.wav
ls /var/spool/asterisk/sounds/ msg0001.wav msg0003.wav msg-2.wav msg-5.wav msg-7.wav msg0002.wav msg0004.wav msg-4.wav msg-6.wav |
#play /var/spool/asterisk/sounds/msg0000.wav
1.wav Input File : '/var/spool/asterisk/sounds/msg0001.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:02.72 [00:00.00] of 00:02.72 (100% ) Samples out: 131k Clips: 9 play effects: resample clipped 9 samples; decrease volume? Done. |
#play /var/spool/asterisk/sounds/msg0003.wav
Input File : '/var/spool/asterisk/sounds/msg0003.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:03.72 [00:00.00] of 00:03.72 (100% ) Samples out: 179k Clips: 0 Done. |
#play /var/spool/asterisk/sounds/msg0002.wav
Input File : '/var/spool/asterisk/sounds/msg0002.wav' Sample Size : 16-bit (2 bytes) Sample Encoding: signed (2's complement) Channels : 1 Sample Rate : 8000 Time: 00:03.30 [00:00.00] of 00:03.30 (100% ) Samples out: 158k Clips: 141 play effects: resample clipped 119 samples; decrease volume? play sox: alsa: output clipped 22 samples; decrease volume? Done. |
#rm /var/spool/asterisk/sounds/msg0002.wav
|
#rm /var/spool/asterisk/sounds/msg0003.wav
|
#rm /var/spool/asterisk/sounds/msg0004.wav
|
#play /var/spool/asterisk/sounds/msg0000.wav
ounds/msg-2.wav mv /var/spool/asterisk/sounds/msg0000.wav /var/spool/asterisk/so ls /var/spool/asterisk/sounds/ spool/asterisk/sounds/ar/spool/asterisk/voicemail/default/1701/INBOX/*.wav /var/s |
#play /var/spool/asterisk/sounds/msg0003.wav
|
#play /var/spool/asterisk/sounds/msg-6.wav
|
#play /var/spool/asterisk/sounds/msg0001.wav
|
#play /var/spool/asterisk/sounds/msg0002.wav
ls /var/spool/asterisk/voicemail/default/1701/INBOX/ l/asterisk/souns/*p /var/spool/asterisk/voicemail/default/1701/INBOX/ msg0000.gsm msg0001.gsm msg0002.gsm msg0003.gsm msg0004.gsm msg0000.txt msg0001.txt msg0002.txt msg0003.txt msg0004.txt msg0000.wav msg0001.wav msg0002.wav msg0003.wav msg0004.wav msg0000.WAV msg0001.WAV msg0002.WAV msg0003.WAV msg0004.WAV |
#ls /var/spool/asterisk/voicemail/default/1701/INBOX/
|
#ls /var/spool/asterisk/voicemail/default/1701/
INBOX Old temp tmp |
#ls /var/spool/asterisk/voicemail/default/1701/Old
msg0000.gsm msg0000.WAV msg0001.wav msg0002.txt msg0003.gsm msg0003.WAV msg0000.txt msg0001.gsm msg0001.WAV msg0002.wav msg0003.txt msg0000.wav msg0001.txt msg0002.gsm msg0002.WAV msg0003.wav |
#vim /etc/asterisk/extensions.conf
--- /tmp/l3-saved-3431.16958.8922 2010-10-27 18:43:54.000000000 +0400 +++ /etc/asterisk/extensions.conf 2010-10-28 10:45:13.000000000 +0400 @@ -18,6 +18,40 @@ exten => _1XXX,1,Dial(SIP/kv/${EXTEN}) exten => _2XXX,1,Dial(SIP/bb/${EXTEN}) +[menu] +exten => s,1,Background(/var/spool/asterisk/sounds/msg-1.wav) +exten => s,n(start),Background(/var/spool/asterisk/sounds/msg-2.wav) +exten => s,n,WaitExten(5) +exten => s,n,Background(/var/spool/asterisk/sounds/msg-6.wav) +exten => s,n,WaitExten(5) +exten => s,n,Background(/var/spool/asterisk/sounds/msg-2.wav) +exten => s,n,WaitExten(5) +exten => s,n,Background(/var/spool/asterisk/sounds/msg-7.wav) + +exten => i,1,Background(/var/spool/asterisk/sounds/msg-3.wav) +exten => i,n,GoTo(s,start) + +exten => 9,1,GoTo(s,start) +exten => 1,1,GoTo(submenu,s,1) +exten => 2,1,Background(/var/spool/asterisk/sounds/msg-5.wav) +exten => 2,n,System(touch /tmp/zdes-byl-asterisk) + + +[submenu] + +exten => s,1(start),Background(/var/spool/asterisk/sounds/msg-4) +exten => s,n,WaitExten(5) +exten => s,n,Background(/var/spool/asterisk/sounds/msg-2) +exten => s,n,WaitExten(5) +exten => s,n,Background(/var/spool/asterisk/sounds/msg-7) +exten => 1,1,Goto(local,1701,1) +exten => 2,1,Goto(local,1702,1) +exten => 9,1,Goto(s,start) +exten => 0,1,Goto(menu,s,start) + +exten => i,1,Background(/var/spool/asterisk/sounds/msg-3) +exten => i,n,Goto(s,start) + [macro-answer-with-monitor] exten => s,1,Answer exten => s,n,Set(FILENAME=voice-${ARG1}-${CALLERID(num)}-${EPOCH}) |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /etc/asterisk/extensions.conf
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ... include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local |
#cat /var/spool/asterisk/sounds/
cat: /var/spool/asterisk/sounds/: Это каталог |
#asterisk -rvvv
Asterisk 1.4.21.2~dfsg-3+lenny1, Copyright (C) 1999 - 2008 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. ========================================================================= This package has been modified for the Debian GNU/Linux distribution Please report all bugs to http://bugs.debian.org/asterisk ========================================================================= ... [Oct 28 12:51:38] WARNING[3592]: app_voicemail.c:2862 leave_voicemail: No entry in voicemail config file for '1790' -- Executing [s@macro-answer-with-monitor:9] Hangup("SIP/msk-087c4050", "") in new stack == Spawn extension (macro-answer-with-monitor, s, 9) exited non-zero on 'SIP/msk-087c4050' in macro 'answer-with-monitor' == Spawn extension (macro-answer-with-monitor, s, 9) exited non-zero on 'SIP/msk-087c4050' [Oct 28 12:51:38] NOTICE[3592]: res_monitor.c:339 ast_monitor_stop: monitor executing /usr/local/bin/monitor_exec "/var/spool/asterisk/monitor/voice-1790-1401-1288255898-in.wav" "/var/spool/asterisk/monitor/voice-1790-1401-1288255898-out.wav" "/var/spool/asterisk/monitor/voice-1790-1401-1288255898.wav" & -- Remote UNIX connection Executing last minute cleanups == Destroying musiconhold processes Disconnected from Asterisk server Executing last minute cleanups |
#--
[default] exten => 1799,1,Answer exten => 1799,n,Wait(1) exten =>1799,n,Playback(demo-thanks) exten => 1799,n,Hangup exten => _17XX,1,Dial(SIP/${EXTEN}) exten => _67XX,1,Wait(2) exten => _67XX,n,Playback(/tmp/warning1) exten => _67XX,n,Dial(SIP/17${EXTEN:2}) "/etc/asterisk/extensions.conf" 111L, 3302C ... exten => s,n(start),Background exten => s,n,WaitExten exten => s,n,Background [local] [ ] [ (1) exten => 1798,1,VoiceMailMain() () 80,31 65% |
#vim /etc/asterisk/ext
|
#vim /etc/asterisk/extensions.conf
|
#~
adsi.conf enum.conf logger.conf rpt.conf adtranvofr.conf esel.conf manager.conf rtp.conf agents.conf extconfig.conf manager.d say.conf alarmreceiver.conf extensions.ael meetme.conf sip.conf alsa.conf extensions.conf mgcp.conf sip.conf.orig amd.conf extensions.conf.orig misdn.conf sip_notify.conf asterisk.adsi features.conf modules.conf skinny.conf asterisk.conf festival.conf musiconhold.conf sla.conf cdr.conf followme.conf muted.conf smdi.conf cdr_custom.conf func_odbc.conf osp.conf telcordia-1.adsi cdr_manager.conf gtalk.conf oss.conf udptl.conf cdr_odbc.conf h323.conf phone.conf users.conf cdr_pgsql.conf http.conf privacy.conf voicemail.conf cdr_tds.conf iax.conf queues.conf vpb.conf codecs.conf iaxprov.conf res_odbc.conf watchdog.conf dnsmgr.conf indications.conf res_pgsql.conf zapata.conf dundi.conf jabber.conf res_snmp.conf |
[default] ;exten => 1801,1,Dial(SIP/${EXTEN},10) ;exten => 1801,n,Dial(SIP/1802,20) ;exten => _18XXX,1,Dial(SIP/1${EXTEN:1:4}) exten => _68XX,1,Wait(2) exten => _68XX,n,Playback(/tmp/warning1) exten => _68XX,n,Dial(SIP/18${EXTEN:2}) exten => 1898,1,Record(/tmp/warning1:gsm,,3) ;exten => _1[234]XX,1,Dial(SIP/msk/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) ;exten => _16XX,1,Dial(SIP/kzn/${EXTEN}) ;exten => _17XX,1,Dial(SIP/msk/${EXTEN}) [macro-answer-with-monitor] exten => s,1,Answer exten => s,n,Set(FILENAME=voice-${ARG1}-${CALLERID(num)}-${EPOCH}) ystem(touch /tmp/zdes-byl-asterisk) exten => s,n,Monitor(wav,${FILENAME},m) exten => s,n,Dial(SIP/${ARG1},10) ;exten => s,n,GotoIf($[${DIALSTATUS} = ANSWER]?answer) exten => s,n,GotoIf($[${DIALSTATUS} = BUSY]?busy:unavail) exten => s,n(unavail),Playback(voicemail-greeting-${ARG1}) exten => s,n,Voicemail(${ARG1}@default) exten => s,n(busy),Hangup ;exten => s,n(answer),StopMonitor() ;exten => s,n,System(lame /var/spool/asterisk/monitor/${FILENAME}.wav /var/spool/asterisk/monitor/${FILENAME}.mp3) ;exten => h,1,StopMonitor() ;exten => h,n,System(lame /var/spool/asterisk/monitor/${FILENAME}.wav /var/spool/asterisk/monitor/${FILENAME}.mp3) [local] exten => _18XX,1,Macro(answer-with-monitor,${EXTEN}) [service] exten => 1899,1,Answer exten => 1899,n,Wait(1) exten => 1899,n,Playback(demo-thanks) exten => 1899,n,Hangup exten => 1898,1,VoiceMailMain(${CALLERID(number)}) exten => 1897,n,Record(/tmp/voicemail-greeting-${CALLERID(number)}) exten => 1896,1,Goto(menu,s,1) exten => _1188X,1,Wait(1) exten => _1188X,n,Record(/tmp/message-${EXTEN:4}:gsm) [menu] exten => s,1,Background(/tmp/message-1) exten => s,n(start),Background(/tmp/message-2) exten => s,n,WaitExten(5) exten => s,n,Background(/tmp/message-6) exten => s,n,WaitExten(5) exten => s,n,Background(/tmp/message-2) exten => s,n,WaitExten(5) exten => s,n,Background(/tmp/message-7) exten => i,1,Background(/tmp/message-3) exten => i,n,Goto(s,start) exten => 9,1,Goto(s,start) exten => 1,1,Goto(submenu,s,1) exten => 2,1,Background(/tmp/message-5) exten => 2,n,System(touch /tmp/zdes-byl-asterisk) [submenu] exten => s,1(start),Background(/tmp/message-4) exten => s,n,WaitExten(5) exten => s,n,Background(/tmp/message-2) exten => s,n,WaitExten(5) exten => s,n,Background(/tmp/message-7) exten => 1,1,Goto(local,1801,1) exten => 2,1,Goto(local,1802,1) exten => 9,1,Goto(s,start) exten => 0,1,Goto(menu,s,start) exten => i,1,Background(/tmp/message-3) exten => i,n,Goto(s,start) [macro-dial-with-callerid] exten => s,1,Set(CALLERID(name)="${CALLERID(name)} (Tula)") exten => s,n,Dial(${ARG1}) [national] exten => _15XX,1,Macro(dial-with-callerid,SIP/ptr/${EXTEN}) ;exten => _15XX,1,Dial(SIP/ptr/${EXTEN}) exten => _16XX,1,Macro(dial-with-callerid,SIP/kzn/${EXTEN}) exten => _17XX,1,Macro(dial-with-callerid,SIP/msk/${EXTEN}) [international] exten => _1XXX,1,Dial(SIP/msk/${EXTEN}) exten => _2XXX,1,Dial(SIP/msk/${EXTEN}) [group1] include => service include => local include => national include => international [group2] include => service include => local include => national [group3] include => service include => local
Время первой команды журнала | 13:25:48 2010-10-27 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 09:44:04 2010-10-28 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 7.92 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 0.99 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 2.52 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.67 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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