/l3/users/igor-public/asterisk/debian4.net.nt/root :1 :2 :3 |
|
#ztmonitor
Usage: ztmonitor <channel num> [-v[v]] [-m] [-o] [-p] [-f FILE | -r FILE1 -t FILE2] [-F FILE | -R FILE1 -T FILE2] Options: -v: Visual mode. Implies -m. -vv: Visual/Verbose mode. Implies -m. -m: Separate rx/tx streams. -o: Output audio via OSS. Note: Only 'normal' combined rx/tx streams are output via OSS. -p: Get a pre-echocanceled stream. -f FILE: Save combined rx/tx stream to FILE. Cannot be used with -m. -r FILE: Save rx stream to FILE. Implies -m. -t FILE: Save tx stream to FILE. Implies -m. ... Save a stream to a file ztmonitor 1 -f stream.raw Visualize an rx/tx stream and save them to separate files. ztmonitor 1 -v -r streamrx.raw -t streamtx.raw Play a combined rx/tx stream via OSS and save it to a file ztmonitor 1 -o -f stream.raw Save a combined normal rx/tx stream and a combined 'preecho' rx/tx stream to files ztmonitor 1 -p -f stream.raw -F streampreecho.raw Save a normal rx/tx stream and a 'preecho' rx/tx stream to separate files ztmonitor 1 -m -p -r streamrx.raw -t streamtx.raw -R streampreechorx.raw -T streampreechotx.raw |
#ztmonitor
Usage: ztmonitor <channel num> [-v[v]] [-m] [-o] [-p] [-f FILE | -r FILE1 -t FILE2] [-F FILE | -R FILE1 -T FILE2] Options: -v: Visual mode. Implies -m. -vv: Visual/Verbose mode. Implies -m. -m: Separate rx/tx streams. -o: Output audio via OSS. Note: Only 'normal' combined rx/tx streams are output via OSS. -p: Get a pre-echocanceled stream. -f FILE: Save combined rx/tx stream to FILE. Cannot be used with -m. -r FILE: Save rx stream to FILE. Implies -m. -t FILE: Save tx stream to FILE. Implies -m. ... Save a stream to a file ztmonitor 1 -f stream.raw Visualize an rx/tx stream and save them to separate files. ztmonitor 1 -v -r streamrx.raw -t streamtx.raw Play a combined rx/tx stream via OSS and save it to a file ztmonitor 1 -o -f stream.raw Save a combined normal rx/tx stream and a combined 'preecho' rx/tx stream to files ztmonitor 1 -p -f stream.raw -F streampreecho.raw Save a normal rx/tx stream and a 'preecho' rx/tx stream to separate files ztmonitor 1 -m -p -r streamrx.raw -t streamtx.raw -R streampreechorx.raw -T streampreechotx.raw |
#asterisk -rvvv
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... agents agi application applications audio autoanswer channel channels channeltype channeltypes codec codecs config dialplan features file function functions globals hints image indications keys manager modules parkedcalls profile queue queues switches transcoder translation uptime version video voicemail debian4*CLI> quit Executing last minute cleanups |
#asterisk -rvvv
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... agents agi application applications audio autoanswer channel channels channeltype channeltypes codec codecs config dialplan features file function functions globals hints image indications keys manager modules parkedcalls profile queue queues switches transcoder translation uptime version video voicemail debian4*CLI> quit Executing last minute cleanups |
#; Default language
"/etc/asterisk/extensions.conf" 22L, 442C exten => _1XXX,n,Hangup [demo1] [demo1] exten => _2XXX,1,Dial(SIP/2xxx/${EXTEN},60) exten => _2XXX,n,Hangup exten => 111,1,Dial(ZAP/111/${EXTEN},60) 1 1,n,Hangup exten => _1XXX,n,Hangup exten => _9XX,1,Dial(SIP/2xxx/${EXTEN},60) exten => _9XX,n,Hangup exten => _4XXX,1,Dial(SIP/${EXTEN},60) "/etc/asterisk/extensions.conf" 25L, 506C written |
#; Default language
"/etc/asterisk/extensions.conf" 22L, 442C exten => _1XXX,n,Hangup [demo1] [demo1] exten => _2XXX,1,Dial(SIP/2xxx/${EXTEN},60) exten => _2XXX,n,Hangup exten => 111,1,Dial(ZAP/111/${EXTEN},60) 1 1,n,Hangup exten => _1XXX,n,Hangup exten => _9XX,1,Dial(SIP/2xxx/${EXTEN},60) exten => _9XX,n,Hangup exten => _4XXX,1,Dial(SIP/${EXTEN},60) "/etc/asterisk/extensions.conf" 25L, 506C written |
#vi /etc/asterisk/extensions.conf
--- /tmp/l3-saved-3305.26104.8391 2009-11-28 18:51:13.000000000 +0200 +++ /etc/asterisk/extensions.conf 2009-11-28 18:51:25.000000000 +0200 @@ -9,7 +9,7 @@ exten => 4000,n,Playback(demo-thanks) exten => 4000,n,Hangup -exten => 111,1,Dial(ZAP/111/${EXTEN},60) +exten => 111,1,Dial(ZAP/G1/${EXTEN},60) exten => 111,n,Hangup exten => _1XXX,1,Dial(SIP/1xxx/${EXTEN},60) |
#vi /etc/asterisk/zapata.conf
--- /tmp/l3-saved-3305.406.31947 2009-11-28 18:51:30.000000000 +0200 +++ /etc/asterisk/zapata.conf 2009-11-28 18:54:40.000000000 +0200 @@ -680,3 +680,6 @@ ;context=default ;channel => 1 +group=1 +context=demo1 +channel=1 |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#asterisk -rvvv
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... -- Executing [111@demo1:1] Dial("SIP/4444-08777460", "ZAP/G1/111|60") in new stack -- Called G1/111 -- Zap/1-1 is ringing -- Zap/1-1 is ringing -- Zap/1-1 answered SIP/4444-08777460 -- Hungup 'Zap/1-1' == Spawn extension (demo1, 111, 1) exited non-zero on 'SIP/4444-08777460' debian4*CLI> debian4*CLI> quit Executing last minute cleanups |
#asterisk -rvvv
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... -- Executing [111@demo1:1] Dial("SIP/4444-08777460", "ZAP/G1/111|60") in new stack -- Called G1/111 -- Zap/1-1 is ringing -- Zap/1-1 is ringing -- Zap/1-1 answered SIP/4444-08777460 -- Hungup 'Zap/1-1' == Spawn extension (demo1, 111, 1) exited non-zero on 'SIP/4444-08777460' debian4*CLI> debian4*CLI> quit Executing last minute cleanups |
#; d-channel for the trunk.
desaultzone=no fxoks=1-4 ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ "/etc/zaptel.conf" 4L, 48C written |
#; d-channel for the trunk.
desaultzone=no fxoks=1-4 ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ "/etc/zaptel.conf" 4L, 48C written |
#/etc/init.d/zaptel restart
Zaptel telephony kernel driver: ZT_CHANCONFIG failed on channel 1: Invalid argument (22) Did you forget that FXS interfaces are configured with FXO signalling and that FXO interfaces use FXS signalling? |
#/etc/init.d/zaptel restart
Zaptel telephony kernel driver: ZT_CHANCONFIG failed on channel 1: Invalid argument (22) Did you forget that FXS interfaces are configured with FXO signalling and that FXO interfaces use FXS signalling? |
#ztcfg -vvv
Zaptel Version: 1.4.11 Echo Canceller: MG2 Configuration ====================== Channel map: Channel 01: FXO Kewlstart (Default) (Slaves: 01) Channel 02: FXO Kewlstart (Default) (Slaves: 02) Channel 03: FXO Kewlstart (Default) (Slaves: 03) Channel 04: FXO Kewlstart (Default) (Slaves: 04) 4 channels to configure. |
#ztcfg -vvv
Zaptel Version: 1.4.11 Echo Canceller: MG2 Configuration ====================== Channel map: Channel 01: FXO Kewlstart (Default) (Slaves: 01) Channel 02: FXO Kewlstart (Default) (Slaves: 02) Channel 03: FXO Kewlstart (Default) (Slaves: 03) Channel 04: FXO Kewlstart (Default) (Slaves: 04) 4 channels to configure. |
#zts
ztscan ztspeed |
#ztscan
[1] active=yes alarms=OK description=Wildcard TDM410P Board 1 name=WCTDM/0 manufacturer=Digium devicetype=Wildcard TDM410P location=PCI Bus 03 Slot 01 basechan=1 totchans=4 irq=20 type=analog port=1,FXS port=2,none port=3,none port=4,none |
#ztscan
[1] active=yes alarms=OK description=Wildcard TDM410P Board 1 name=WCTDM/0 manufacturer=Digium devicetype=Wildcard TDM410P location=PCI Bus 03 Slot 01 basechan=1 totchans=4 irq=20 type=analog port=1,FXS port=2,none port=3,none port=4,none |
#asterisk -r
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... [Nov 28 19:14:43] WARNING[4495]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'default' not found -- Executing [112@demo1:1] Wait("SIP/4444-08775ed0", "1") in new stack -- Executing [112@demo1:2] MeetMe("SIP/4444-08775ed0", "1|dM") in new stack == Spawn extension (demo1, 112, 2) exited non-zero on 'SIP/4444-08775ed0' [Nov 28 19:15:05] WARNING[4495]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'default' not found -- Hungup 'Zap/pseudo-1353088816' == Spawn extension (demo1, 112, 2) exited non-zero on 'SIP/4442-08792de8' debian4*CLI> debian4*CLI> debian4*CLI> quit |
#asterisk -r
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... [Nov 28 19:14:43] WARNING[4495]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'default' not found -- Executing [112@demo1:1] Wait("SIP/4444-08775ed0", "1") in new stack -- Executing [112@demo1:2] MeetMe("SIP/4444-08775ed0", "1|dM") in new stack == Spawn extension (demo1, 112, 2) exited non-zero on 'SIP/4444-08775ed0' [Nov 28 19:15:05] WARNING[4495]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'default' not found -- Hungup 'Zap/pseudo-1353088816' == Spawn extension (demo1, 112, 2) exited non-zero on 'SIP/4442-08792de8' debian4*CLI> debian4*CLI> debian4*CLI> quit |
#pwd
/root |
#apt-get install sox mpg1243
Reading package lists... Done Building dependency tree Reading state information... Done E: Couldn't find package mpg1243 |
#apt-get install sox mpg123
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libmpg123-0 libsamplerate0 libsox-fmt-alsa libsox-fmt-base libsox0 Suggested packages: libsox-fmt-all libartsc0 The following NEW packages will be installed: libmpg123-0 libsamplerate0 libsox-fmt-alsa libsox-fmt-base libsox0 mpg123 sox ... Selecting previously deselected package sox. Unpacking sox (from .../sox_14.0.1-2+b1_i386.deb) ... Processing triggers for man-db ... Setting up libmpg123-0 (1.4.3-4) ... Setting up libsamplerate0 (0.1.4-1) ... Setting up libsox0 (14.0.1-2+b1) ... Setting up libsox-fmt-alsa (14.0.1-2+b1) ... Setting up libsox-fmt-base (14.0.1-2+b1) ... Setting up mpg123 (1.4.3-4) ... Setting up sox (14.0.1-2+b1) ... |
#ls
01 - Vrooom.mp3 |
#mpg123 -w vroom.wav 01\ -\ Vrooom.mp3
High Performance MPEG 1.0/2.0/2.5 Audio Player for Layers 1, 2 and 3 version 1.4.3; written and copyright by Michael Hipp and others free software (LGPL/GPL) without any warranty but with best wishes Playing MPEG stream 1 of 1: 01 - Vrooom.mp3 ... Title: Vrooom Artist: King Crimson Comment: Album: Vrooom Year: 1994 Genre: Unknown MPEG 1.0 layer III, 192 kbit/s, 44100 Hz joint-stereo [7:35] Decoding of 01 - Vrooom.mp3 finished. |
#apt-cache search gsm
asn1c - ASN.1 compiler for C dirmngr - server for managing certificate revocation lists gpe-soundbite - voice memo player/recorder for GPE gpgsm - GNU privacy guard - S/MIME version gsm-utils - GSM mobile phone access applications gsmc - Smith Chart calculator for impedance matching kandy - KDE mobile phone utility kannel - WAP and SMS gateway kannel-dev - WAP and SMS gateway headers and development files kannel-docs - WAP and SMS gateway documentation ... libsox-fmt-gsm - SoX GSM format library obexftp - file transfer utility for devices that use the OBEX protocol skyutils-dev - Many useful functions for the web like smssend (development) skyutils2 - Many useful functions for the web like smssend slang-gsl - GNU Scientific Library binding for S-Lang sms-pl - Send SMs via Polish GSM operators smstools - SMS server tools for GSM modems sox - Swiss army knife of sound processing sweep - An editor for sound samples twinkle - Voice over Internet Protocol (VoIP) SIP Phone |
#apt-get install libsox-fmt-gsm
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: libsox-fmt-gsm 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 34.9kB of archives. After this operation, 53.2kB of additional disk space will be used. Get:1 http://10.0.35.1 lenny/main libsox-fmt-gsm 14.0.1-2+b1 [34.9kB] Fetched 34.9kB in 0s (97.3kB/s) Selecting previously deselected package libsox-fmt-gsm. (Reading database ... 102117 files and directories currently installed.) Unpacking libsox-fmt-gsm (from .../libsox-fmt-gsm_14.0.1-2+b1_i386.deb) ... Setting up libsox-fmt-gsm (14.0.1-2+b1) ... |
#ls /usr/lib/asterisk/
modules |
#ls /usr/lib/asterisk/modules/
app_adsiprog.so app_sms.so format_jpeg.so app_alarmreceiver.so app_softhangup.so format_ogg_vorbis.so app_amd.so app_speech_utils.so format_pcm.so app_authenticate.so app_stack.so format_sln.so app_cdr.so app_system.so format_vox.so app_chanisavail.so app_talkdetect.so format_wav_gsm.so app_channelredirect.so app_test.so format_wav.so app_chanspy.so app_transfer.so func_base64.so app_controlplayback.so app_url.so func_callerid.so app_db.so app_userevent.so func_cdr.so ... app_read.so codec_speex.so res_indications.so app_realtime.so codec_ulaw.so res_jabber.so app_record.so codec_zap.so res_monitor.so app_sayunixtime.so format_g723.so res_musiconhold.so app_segfault.so format_g726.so res_odbc.so app_senddtmf.so format_g729.so res_smdi.so app_sendtext.so format_gsm.so res_snmp.so app_setcallerid.so format_h263.so res_speech.so app_setcdruserfield.so format_h264.so res_watchdog.so app_settransfercapability.so format_ilbc.so |
#. /etc/bash_completion
|
#dpkg -L asterisk-sounds-main
/. /usr /usr/share /usr/share/asterisk /usr/share/asterisk/sounds /usr/share/asterisk/sounds/es /usr/share/asterisk/sounds/fr /usr/share/asterisk/sounds/CHANGES-asterisk-core-en-1.4.9 /usr/share/asterisk/sounds/CREDITS-asterisk-core-en-1.4.9 /usr/share/asterisk/sounds/agent-alreadyon.gsm ... /usr/share/asterisk/moh /usr/share/lintian /usr/share/lintian/overrides /usr/share/lintian/overrides/asterisk-sounds-main /usr/share/doc /usr/share/doc/asterisk-sounds-main /usr/share/doc/asterisk-sounds-main/copyright /usr/share/doc/asterisk-sounds-main/NEWS.Debian.gz /usr/share/doc/asterisk-sounds-main/changelog.gz /usr/share/doc/asterisk-sounds-main/changelog.Debian.gz |
#cp vroom.gsm /usr/share/asterisk/sounds/
|
#vi /etc/asterisk/extensions.
|
#~
exten => _9XX,1,Dial(SIP/2xxx/${EXTEN},60) exten => _4XXX,1,Dial(SIP/${EXTEN},60) exten => _4XXX,n,Hangup exten => 112,1,Wait(1) exten => 112,n,MeetMe(1,dM) exten => 112,n,Hangup exten => 112,n,MusicOnHold(vroom) MeetMe(1,dM) 28,28 85% "/etc/asterisk/extensions.conf" 30L, 613C written |
#man asterisk
|
#asterisk -x dialplan reload
Asterisk already running on /var/run/asterisk/asterisk.ctl. Use 'asterisk -r' to connect. |
#asterisk -r -x dialplan reload
No such command 'dialplan' (type 'help dialplan' for other possible commands) |
#asterisk -r
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... [Nov 28 19:49:11] WARNING[5111]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'vroom' not found [Nov 28 19:49:11] WARNING[5111]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'default' not found [Nov 28 19:49:11] WARNING[5111]: res_musiconhold.c:597 moh0_exec: Unable to start music on hold (class 'vroom') on channel SIP/4444-08775ed0 -- Executing [112@demo1:3] MeetMe("SIP/4444-08775ed0", "1|dM") in new stack -- Created MeetMe conference 1023 for conference '1' -- <SIP/4444-08775ed0> Playing 'conf-onlyperson' (language 'en') [Nov 28 19:49:14] WARNING[5111]: res_musiconhold.c:660 get_mohbyname: Music on Hold class 'default' not found -- Hungup 'Zap/pseudo-1991800762' == Spawn extension (demo1, 112, 3) exited non-zero on 'SIP/4444-08775ed0' debian4*CLI> quit |
#vi /etc/asterisk/mu
|
#vi /etc/asterisk/musiconhold.conf
|
#; =========
|
#cp vroom.gsm /var/lib/asterisk/moh/
|
#; without transcoding (same as Playback would do in the dialplan).
exten => _4XXX,1,Dial(SIP/${EXTEN},60) exten => _4XXX,n,Hangup exten => 112,1,Wait(1) exten => 112,n,MusicOnHold(vroom) exten => 112,n,MeetMe(1,dM) exten => 112,n,Hangup ;exten => 112,n,MusicOnHold(vroom) 28,1 Bot 28,1 Bot "/etc/asterisk/extensions.conf" 30L, 614C written |
#vi /etc/asterisk/extensions.conf
|
#ls -l /var/lib/asterisk/moh/
total 737 -rw-r--r-- 1 root root 750783 2009-11-28 19:50 vroom.gsm |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#asterisk -r
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= Connected to Asterisk 1.4.21.2~dfsg-3 currently running on debian4 (pid = 5362) debian4*CLI> quit |
#asterisk -rvvv
Asterisk 1.4.21.2~dfsg-3, 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 ========================================================================= ... -- Starting simple switch on 'Zap/1-1' -- Hungup 'Zap/1-1' -- Starting simple switch on 'Zap/1-1' -- Hungup 'Zap/1-1' -- Stopped music on hold on SIP/4444-09769a10 -- Hungup 'Zap/pseudo-2144576766' == Spawn extension (demo1, 112, 2) exited non-zero on 'SIP/4444-09769a10' debian4*CLI> debian4*CLI> quit Executing last minute cleanups |
#/etc/init.d/zaptel restart
Zaptel telephony kernel driver: zaptel. |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#reboot
|
#vi /etc/asterisk/zapata.conf
--- /tmp/l3-saved-3315.19274.20268 2009-11-28 20:19:08.000000000 +0200 +++ /etc/asterisk/zapata.conf 2009-11-28 20:19:27.000000000 +0200 @@ -391,7 +391,7 @@ ; detection parameters. Relaxing them may make the DTMF detector more likely ; to have "talkoff" where DTMF is detected when it shouldn't be. ; -;relaxdtmf=yes +relaxdtmf=yes ; ; You may also set the default receive and transmit gains (in dB) ; |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#ifconfig
eth0 Link encap:Ethernet HWaddr 00:07:e9:0c:45:80 inet addr:192.168.7.4 Bcast:192.168.7.255 Mask:255.255.255.0 UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:202 errors:0 dropped:0 overruns:0 frame:0 TX packets:202 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:18222 (17.7 KiB) TX bytes:18222 (17.7 KiB) |
#sudo route -n
Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 192.168.7.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 0.0.0.0 192.168.7.254 0.0.0.0 UG 0 0 0 eth0 |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 1 packets transmitted, 0 received, 100% packet loss, time 0ms |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. From 192.168.7.4 icmp_seq=1 Destination Host Unreachable From 192.168.7.4 icmp_seq=2 Destination Host Unreachable From 192.168.7.4 icmp_seq=3 Destination Host Unreachable ^C --- 192.168.7.254 ping statistics --- 6 packets transmitted, 0 received, +3 errors, 100% packet loss, time 5017ms , pipe 3 |
#mii-tool
eth0: no link SIOCGMIIPHY on 'eth1' failed: Invalid argument |
#mii-tool
eth0: no link SIOCGMIIPHY on 'eth1' failed: Invalid argument |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 5 packets transmitted, 0 received, 100% packet loss, time 3999ms |
#mii-tool
eth0: negotiated 1000baseT-FD flow-control, link ok SIOCGMIIPHY on 'eth1' failed: Invalid argument |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 2 packets transmitted, 0 received, 100% packet loss, time 1012ms |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 6 packets transmitted, 0 received, 100% packet loss, time 4999ms |
#ifconfig
eth0 Link encap:Ethernet HWaddr 00:07:e9:0c:45:80 inet addr:192.168.7.4 Bcast:192.168.7.255 Mask:255.255.255.0 inet6 addr: fe80::207:e9ff:fe0c:4580/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:814 errors:0 dropped:0 overruns:0 frame:0 TX packets:52 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:64265 (62.7 KiB) TX bytes:7601 (7.4 KiB) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:210 errors:0 dropped:0 overruns:0 frame:0 TX packets:210 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:19085 (18.6 KiB) TX bytes:19085 (18.6 KiB) |
#ifconfig eth0:1 10.0.35.23
|
#ping 10.0.35.1
PING 10.0.35.1 (10.0.35.1) 56(84) bytes of data. 64 bytes from 10.0.35.1: icmp_seq=1 ttl=64 time=2.25 ms ^C --- 10.0.35.1 ping statistics --- 1 packets transmitted, 1 received, 0% packet loss, time 0ms rtt min/avg/max/mdev = 2.254/2.254/2.254/0.000 ms |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 15 packets transmitted, 0 received, 100% packet loss, time 13999ms |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 2 packets transmitted, 0 received, 100% packet loss, time 1014ms |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 5 packets transmitted, 0 received, 100% packet loss, time 4013ms |
#ping 192.168.7.3
PING 192.168.7.3 (192.168.7.3) 56(84) bytes of data. 64 bytes from 192.168.7.3: icmp_seq=1 ttl=64 time=3.44 ms 64 bytes from 192.168.7.3: icmp_seq=2 ttl=64 time=0.194 ms ^C --- 192.168.7.3 ping statistics --- 2 packets transmitted, 2 received, 0% packet loss, time 1006ms rtt min/avg/max/mdev = 0.194/1.821/3.449/1.628 ms |
#ping 192.168.7.30
PING 192.168.7.30 (192.168.7.30) 56(84) bytes of data. 64 bytes from 192.168.7.30: icmp_seq=1 ttl=64 time=2.66 ms 64 bytes from 192.168.7.30: icmp_seq=2 ttl=64 time=0.229 ms 64 bytes from 192.168.7.30: icmp_seq=3 ttl=64 time=0.171 ms ^C --- 192.168.7.30 ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 2006ms rtt min/avg/max/mdev = 0.171/1.022/2.666/1.162 ms |
#ping 192.168.7.254
PING 192.168.7.254 (192.168.7.254) 56(84) bytes of data. ^C --- 192.168.7.254 ping statistics --- 2 packets transmitted, 0 received, 100% packet loss, time 1013ms |
Время первой команды журнала | 17:44:28 2009-11-28 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 10:57:49 2009-12- 5 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 20.79 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 0.00 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 1.77 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.95 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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