/l3/users/kronas/nt-voip/linux5.unix.nt/root :1 :2 :3 :4 :5 :6 :7 :8 :9 :10 |
|
#w
15:29:31 up 2:00, 4 users, load average: 0.03, 0.14, 0.12 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT root tty1 16:29 1:28m 0.24s 0.20s -bash user tty7 :0 14:01 ? 11.87s 0.07s x-session-manag user pts/7 :0.0 14:46 0.00s 0.43s 4.88s gnome-terminal user pts/10 :0.0 14:59 3:48 0.24s 4.88s gnome-terminal |
#w
15:29:31 up 2:00, 4 users, load average: 0.03, 0.14, 0.12 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT root tty1 16:29 1:28m 0.24s 0.20s -bash user tty7 :0 14:01 ? 11.87s 0.07s x-session-manag user pts/7 :0.0 14:46 0.00s 0.43s 4.88s gnome-terminal user pts/10 :0.0 14:59 3:48 0.24s 4.88s gnome-terminal |
#l3shot
Choose window to be shoot ...Screenshot is written to /root/.lilalo//2614960581845131996-1365421619_1365424285.xwd bash: curl: command not found |
#l3shot
Choose window to be shoot ...Screenshot is written to /root/.lilalo//2614960581845131996-1365421619_1365424285.xwd bash: curl: command not found |
#w
15:32:12 up 2:02, 4 users, load average: 0.01, 0.09, 0.11 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT root tty1 16:29 1:31m 0.24s 0.20s -bash user tty7 :0 14:01 ? 12.64s 0.08s x-session-manag user pts/0 :0.0 15:32 0.00s 0.36s 5.04s gnome-terminal user pts/10 :0.0 14:59 6:29 0.24s 5.04s gnome-terminal |
#w
15:32:12 up 2:02, 4 users, load average: 0.01, 0.09, 0.11 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT root tty1 16:29 1:31m 0.24s 0.20s -bash user tty7 :0 14:01 ? 12.64s 0.08s x-session-manag user pts/0 :0.0 15:32 0.00s 0.36s 5.04s gnome-terminal user pts/10 :0.0 14:59 6:29 0.24s 5.04s gnome-terminal |
#cat /etc/default/isc-dhcp-server
# Defaults for dhcp initscript # sourced by /etc/init.d/dhcp # installed at /etc/default/isc-dhcp-server by the maintainer scripts # # This is a POSIX shell fragment # # On what interfaces should the DHCP server (dhcpd) serve DHCP requests? # Separate multiple interfaces with spaces, e.g. "eth0 eth1". INTERFACES="" |
#cat /etc/default/isc-dhcp-server
# Defaults for dhcp initscript # sourced by /etc/init.d/dhcp # installed at /etc/default/isc-dhcp-server by the maintainer scripts # # This is a POSIX shell fragment # # On what interfaces should the DHCP server (dhcpd) serve DHCP requests? # Separate multiple interfaces with spaces, e.g. "eth0 eth1". INTERFACES="" |
#vim ~/.vimrc
--- /tmp/l3-saved-1789.9303.21545 2013-04-08 15:36:42.000000000 +0300 +++ /root/.vimrc 2013-04-08 15:37:00.000000000 +0300 @@ -1,3 +1,2 @@ syn on -colorscheme elfrord colorscheme elflord |
#/etc/init.d/isc-dhcp-server restart
Stopping ISC DHCP server: dhcpd. Starting ISC DHCP server: dhcpd. |
#/etc/init.d/isc-dhcp-server restart
Stopping ISC DHCP server: dhcpd. Starting ISC DHCP server: dhcpd. |
#ps aux | grep dhcp
root 1936 0.0 0.0 4220 2476 ? Ss 15:37 0:00 /usr/sbin/dhcpd -q eth0 root 1984 0.0 0.0 3352 744 pts/2 S+ 15:44 0:00 grep dhcp |
#ps aux | grep dhcp
root 1936 0.0 0.0 4220 2476 ? Ss 15:37 0:00 /usr/sbin/dhcpd -q eth0 root 1984 0.0 0.0 3352 744 pts/2 S+ 15:44 0:00 grep dhcp |
#ps aux | grep dhcp
root 1936 0.0 0.0 4220 2476 ? Ss 15:37 0:00 /usr/sbin/dhcpd -q eth0 root 1993 0.0 0.0 3352 748 pts/2 S+ 15:44 0:00 grep dhcp |
#ps aux | grep dhcp
root 1936 0.0 0.0 4220 2476 ? Ss 15:37 0:00 /usr/sbin/dhcpd -q eth0 root 1993 0.0 0.0 3352 748 pts/2 S+ 15:44 0:00 grep dhcp |
#apt-cache search asterisk
asterisk-mobile - bluetooth mobile devices support for Asterisk asterisk-mp3 - MP3 format support (format_mp3) for the Asterisk PBX asterisk-mysql - MySQL support for the Asterisk PBX (cdr mainly) asterisk-ooh323c - H.323 protocol support for Asterisk (ooh323c stack) asterisk-chan-capi - Common ISDN API 2.0 implementation for Asterisk asterisk-core-sounds-en-g722 - asterisk PBX sound files - English/g722 asterisk-core-sounds-en-gsm - asterisk PBX sound files - English/gsm asterisk-core-sounds-en-wav - asterisk PBX sound files - English/wav asterisk-core-sounds-es-g722 - asterisk PBX sound files - Spanish/g722 asterisk-core-sounds-es-gsm - asterisk PBX sound files - Spanish/gsm ... asterisk - Open Source Private Branch Exchange (PBX) dahdi-linux - DAHDI telephony interface - Linux userspace parts dahdi-source - DAHDI telephony interface - source code for kernel driver dahdi - utilities for using the DAHDI kernel modules iaxmodem - software modem with IAX2 connectivity libasterisk-agi-perl - Collections of Perl modules to be used with Asterisk PBX AGI libnetsds-perl - Service Delivery Suite framework op-panel - switchboard type application for the Asterisk PBX libopenr2-3 - MFC/R2 (telephony) call setup library python-asterisk - Asterisk Manager API interface module for Python |
#apt-cache search asterisk
asterisk-mobile - bluetooth mobile devices support for Asterisk asterisk-mp3 - MP3 format support (format_mp3) for the Asterisk PBX asterisk-mysql - MySQL support for the Asterisk PBX (cdr mainly) asterisk-ooh323c - H.323 protocol support for Asterisk (ooh323c stack) asterisk-chan-capi - Common ISDN API 2.0 implementation for Asterisk asterisk-core-sounds-en-g722 - asterisk PBX sound files - English/g722 asterisk-core-sounds-en-gsm - asterisk PBX sound files - English/gsm asterisk-core-sounds-en-wav - asterisk PBX sound files - English/wav asterisk-core-sounds-es-g722 - asterisk PBX sound files - Spanish/g722 asterisk-core-sounds-es-gsm - asterisk PBX sound files - Spanish/gsm ... asterisk - Open Source Private Branch Exchange (PBX) dahdi-linux - DAHDI telephony interface - Linux userspace parts dahdi-source - DAHDI telephony interface - source code for kernel driver dahdi - utilities for using the DAHDI kernel modules iaxmodem - software modem with IAX2 connectivity libasterisk-agi-perl - Collections of Perl modules to be used with Asterisk PBX AGI libnetsds-perl - Service Delivery Suite framework op-panel - switchboard type application for the Asterisk PBX libopenr2-3 - MFC/R2 (telephony) call setup library python-asterisk - Asterisk Manager API interface module for Python |
#apt-get install asterisk asterisk-config asterisk-sounds-main asterisk-sounds-extra
Package configuration âââââââââââââââââââââââââââââââââââââââââââââââââââââ⤠Configuring libvpb0 ââââââââââââââââââââââââââââââââââââââââââââââââââââââ â This is the numeric code for the region your phone system will be operating in (eg. 61 for Australia or 33 for France). It â â is used to configure the default regional standards that Voicetronix telephony hardware should comply with. â â â â ITU-T telephone code: â â â â3801___________________________________________________________________________________________________________________________ â â â â <Ok> â ... Setting up unixodbc (2.2.14p2-1) ... Setting up asterisk (1:1.6.2.9-2+squeeze10) ... Adding system user for Asterisk Adding user `asterisk' to group `dialout' ... Adding user asterisk to group dialout Done. Adding user `asterisk' to group `audio' ... Adding user asterisk to group audio Done. Starting Asterisk PBX: asterisk. |
#apt-get install asterisk asterisk-config asterisk-sounds-main asterisk-sounds-extra
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: autopoint dahdi dahdi-linux debhelper fancontrol freetds-common fxload gettext git html2text intltool-debian libc-client2007e Package configuration âââââââââââââââââââââââââââââââââââââââââââââââââââââ⤠Configuring libvpb0 ââââââââââââââââââââââââââââââââââââââââââââââââââââââ â This is the numeric code for the region your phone system will be operating in (eg. 61 for Australia or 33 for France). It â â is used to configure the default regional standards that Voicetronix telephony hardware should comply with. â â â ... Setting up unixodbc (2.2.14p2-1) ... Setting up asterisk (1:1.6.2.9-2+squeeze10) ... Adding system user for Asterisk Adding user `asterisk' to group `dialout' ... Adding user asterisk to group dialout Done. Adding user `asterisk' to group `audio' ... Adding user asterisk to group audio Done. Starting Asterisk PBX: asterisk. |
#dpkg -L asterisk
/. /etc /etc/asterisk /etc/init.d /etc/init.d/asterisk /etc/default /etc/default/asterisk /etc/logrotate.d /etc/logrotate.d/asterisk /var ... /usr/share/asterisk/conf/udptl.conf.sample /usr/share/asterisk/conf/logger.conf.sample /usr/share/asterisk/sounds /usr/share/asterisk/firmware /usr/share/asterisk/firmware/iax /usr/share/asterisk/agi-bin /usr/sbin/rasterisk /usr/share/man/man8/rasterisk.8.gz /usr/share/asterisk/sounds/recordings /usr/share/asterisk/sounds/custom |
#dpkg -L asterisk
/. /etc /etc/asterisk /etc/init.d /etc/init.d/asterisk /etc/default /etc/default/asterisk /etc/logrotate.d /etc/logrotate.d/asterisk /var ... /usr/share/asterisk/conf/udptl.conf.sample /usr/share/asterisk/conf/logger.conf.sample /usr/share/asterisk/sounds /usr/share/asterisk/firmware /usr/share/asterisk/firmware/iax /usr/share/asterisk/agi-bin /usr/sbin/rasterisk /usr/share/man/man8/rasterisk.8.gz /usr/share/asterisk/sounds/recordings /usr/share/asterisk/sounds/custom |
#cat /etc/default/asterisk
# This file allows you to alter the configuration of the Asterisk # init.d script. Normally you should leave the file as-is. # # RUNASTERISK: If set to anything other that 'yes', the asterisk init.d script # will not run. The default is 'yes'. #RUNASTERISK=no # # # AST_REALTIME: if set to anything other than "no", asterisk will run in # real-time priority (pass '-p' to asterisk). un-rem the ... # However if you just enable generation of core files and run # asterisk as a daemon it will fail to write core files. # # Alternatively you can set this independently elsewhere. # See http://lxr.linux.no/source/Documentation/sysctl/kernel.txt # Here is what Asterisk's ast_grab_core # script would expect: #CORE_PATTERN='core.%p' # But you might prefer something like: #CORE_PATTERN='core.%e.%t' |
#cat /etc/default/asterisk
# This file allows you to alter the configuration of the Asterisk # init.d script. Normally you should leave the file as-is. # # RUNASTERISK: If set to anything other that 'yes', the asterisk init.d script # will not run. The default is 'yes'. #RUNASTERISK=no # # # AST_REALTIME: if set to anything other than "no", asterisk will run in # real-time priority (pass '-p' to asterisk). un-rem the ... # However if you just enable generation of core files and run # asterisk as a daemon it will fail to write core files. # # Alternatively you can set this independently elsewhere. # See http://lxr.linux.no/source/Documentation/sysctl/kernel.txt # Here is what Asterisk's ast_grab_core # script would expect: #CORE_PATTERN='core.%p' # But you might prefer something like: #CORE_PATTERN='core.%e.%t' |
#/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. |
#ps aux | grep asterisk
asterisk 4524 1.2 0.2 48032 18152 ? Ssl 16:32 0:00 /usr/sbin/asterisk -p -U asterisk asterisk 4525 0.0 0.0 2940 568 ? S 16:32 0:00 astcanary /var/run/asterisk/alt.asterisk.canary.tweet.tweet.tweet 4524 root 4570 0.0 0.0 3352 748 pts/2 S+ 16:32 0:00 grep asterisk |
#ps aux | grep asterisk
asterisk 4524 1.2 0.2 48032 18152 ? Ssl 16:32 0:00 /usr/sbin/asterisk -p -U asterisk asterisk 4525 0.0 0.0 2940 568 ? S 16:32 0:00 astcanary /var/run/asterisk/alt.asterisk.canary.tweet.tweet.tweet 4524 root 4570 0.0 0.0 3352 748 pts/2 S+ 16:32 0:00 grep asterisk |
#mv extensions.conf extensions.conf.ORIG
|
#touch extensions.conf
|
#ls -l /etc/asterisk/extensions.conf
-rw-r--r-- 1 asterisk asterisk 0 Apr 8 16:35 /etc/asterisk/extensions.conf |
#ls -l /etc/asterisk/extensions.conf
-rw-r--r-- 1 asterisk asterisk 0 Apr 8 16:35 /etc/asterisk/extensions.conf |
#vim /etc/asterisk/sip.conf
--- /tmp/l3-saved-1789.31406.24411 2013-04-08 16:37:19.000000000 +0300 +++ /etc/asterisk/sip.conf 2013-04-08 16:41:06.000000000 +0300 @@ -0,0 +1,9 @@ +; "sip.conf" file + +context=default + +; SIP-peer +[2101] +type=friend +secret=4321 +host=dynamic |
#ls -l /etc/asterisk/sip.conf
-rw------- 1 asterisk asterisk 91 Apr 8 16:41 /etc/asterisk/sip.conf |
#ls -l /etc/asterisk/sip.conf
-rw------- 1 asterisk asterisk 91 Apr 8 16:41 /etc/asterisk/sip.conf |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) linux5*CLI> quit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) linux5*CLI> quit |
#vim /etc/asterisk/sip.conf
--- /tmp/l3-saved-1789.26615.5696 2013-04-08 16:46:56.000000000 +0300 +++ /etc/asterisk/sip.conf 2013-04-08 16:47:32.000000000 +0300 @@ -7,3 +7,8 @@ type=friend secret=4321 host=dynamic + +[2110] +type=friend +secret=4321 +host=dynamic |
#vim /etc/asterisk/sip.conf
--- /tmp/l3-saved-1789.21527.22655 2013-04-08 16:47:40.000000000 +0300 +++ /etc/asterisk/sip.conf 2013-04-08 16:47:56.000000000 +0300 @@ -1,5 +1,6 @@ ; "sip.conf" file +[general] context=default ; SIP-peer |
#asterisk -rvvv
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) ... [Apr 8 16:58:51] NOTICE[4546]: chan_sip.c:21643 handle_request_subscribe: Received SIP subscribe for peer without mailbox: 2110 -- Unregistered SIP '2110' -- Registered SIP '2110' at 192.168.50.100 port 57454 [Apr 8 16:59:19] NOTICE[4546]: chan_sip.c:21643 handle_request_subscribe: Received SIP subscribe for peer without mailbox: 2110 == Using SIP RTP CoS mark 5 [Apr 8 16:59:37] NOTICE[4546]: chan_sip.c:20325 handle_request_invite: Call from '2101' to extension '2110' rejected because extension not found in context 'default'. == Using SIP RTP CoS mark 5 [Apr 8 16:59:54] NOTICE[4546]: chan_sip.c:20325 handle_request_invite: Call from '2101' to extension '192*168*50*100' rejected because extension not found in context 'default'. linux5*CLI> quit Executing last minute cleanups |
#vim extensions.conf
--- /tmp/l3-saved-1789.7281.22442 2013-04-08 17:10:45.000000000 +0300 +++ extensions.conf 2013-04-08 17:14:09.000000000 +0300 @@ -0,0 +1,4 @@ +; extension.conf + +[default] +exten => 8000,1,Playback(welcome) |
#[default]
broadcast 192.168.15.255 gateway 192.168.15.253 # dns-* options are implemented by the resolvconf package, if installed dns-nameservers 192.168.15.253 dns-search unix.nt [ Read 18 lines ] [root@linux5:~]# |
#[default]
broadcast 192.168.15.255 gateway 192.168.15.253 # dns-* options are implemented by the resolvconf package, if installed dns-nameservers 192.168.15.253 dns-search unix.nt [ Read 18 lines ] [root@linux5:~]# |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) Verbosity is at least 3 linux5*CLI> dialplan reload ... -- merging incls/swits/igpats from old(app_dial_gosub_virtual_context) to new(app_dial_gosub_virtual_context) context, registrar = pbx_config -- Added extension 's' priority 1 to app_dial_gosub_virtual_context (0xb52a71f0) -- Registered extension context 'parkedcalls' (0x8c6d2b0) in local table 0x8c69420; registrar: features -- merging incls/swits/igpats from old(parkedcalls) to new(parkedcalls) context, registrar = pbx_config -- Added extension '700' priority 1 to parkedcalls (0x8c6d2b0) -- Time to scan old dialplan and merge leftovers back into the new: 0.000628 sec -- Time to restore hints and swap in new dialplan: 0.000001 sec -- Time to delete the old dialplan: 0.000089 sec -- Total time merge_contexts_delete: 0.000718 sec linux5*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) Verbosity is at least 3 linux5*CLI> dialplan reload ... -- merging incls/swits/igpats from old(app_dial_gosub_virtual_context) to new(app_dial_gosub_virtual_context) context, registrar = pbx_config -- Added extension 's' priority 1 to app_dial_gosub_virtual_context (0xb52a71f0) -- Registered extension context 'parkedcalls' (0x8c6d2b0) in local table 0x8c69420; registrar: features -- merging incls/swits/igpats from old(parkedcalls) to new(parkedcalls) context, registrar = pbx_config -- Added extension '700' priority 1 to parkedcalls (0x8c6d2b0) -- Time to scan old dialplan and merge leftovers back into the new: 0.000628 sec -- Time to restore hints and swap in new dialplan: 0.000001 sec -- Time to delete the old dialplan: 0.000089 sec -- Total time merge_contexts_delete: 0.000718 sec linux5*CLI> exit |
#[default]
PING 192.168.15.253 (192.168.15.253) 56(84) bytes of data. 64 bytes from 192.168.15.253: icmp_req=1 ttl=63 time=0.233 ms ^C --- 192.168.15.253 ping statistics --- 1 packets transmitted, 1 received, 0% packet loss, time 0ms rtt min/avg/max/mdev = 0.233/0.233/0.233/0.000 ms |
#[default]
PING 192.168.15.253 (192.168.15.253) 56(84) bytes of data. 64 bytes from 192.168.15.253: icmp_req=1 ttl=63 time=0.233 ms ^C --- 192.168.15.253 ping statistics --- 1 packets transmitted, 1 received, 0% packet loss, time 0ms rtt min/avg/max/mdev = 0.233/0.233/0.233/0.000 ms |
#vim extensions.conf
--- /tmp/l3-saved-5151.24129.7802 2013-04-08 17:16:45.000000000 +0300 +++ extensions.conf 2013-04-08 17:17:26.000000000 +0300 @@ -2,3 +2,4 @@ [default] exten => 8000,1,Playback(welcome) +exten => 21XX,1,Dial(SIP\${EXTEN},30) |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) Verbosity is at least 3 linux5*CLI> dialplan reload ... -- Executing [8000@default:1] Playback("SIP/2110-00000001", "welcome") in new stack -- <SIP/2110-00000001> Playing 'welcome.gsm' (language 'en') [Apr 8 17:17:52] NOTICE[5235]: channel.c:3068 __ast_read: Dropping incompatible voice frame on SIP/2110-00000001 of format ulaw since our native format has changed to 0x80002 (gsm|h263) -- Auto fallthrough, channel 'SIP/2110-00000001' status is 'UNKNOWN' == Using SIP RTP CoS mark 5 -- Executing [8000@default:1] Playback("SIP/2110-00000002", "welcome") in new stack -- <SIP/2110-00000002> Playing 'welcome.gsm' (language 'en') [Apr 8 17:18:00] NOTICE[5236]: channel.c:3068 __ast_read: Dropping incompatible voice frame on SIP/2110-00000002 of format ulaw since our native format has changed to 0x80002 (gsm|h263) -- Auto fallthrough, channel 'SIP/2110-00000002' status is 'UNKNOWN' linux5*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) Verbosity is at least 3 linux5*CLI> dialplan reload ... -- Executing [8000@default:1] Playback("SIP/2110-00000001", "welcome") in new stack -- <SIP/2110-00000001> Playing 'welcome.gsm' (language 'en') [Apr 8 17:17:52] NOTICE[5235]: channel.c:3068 __ast_read: Dropping incompatible voice frame on SIP/2110-00000001 of format ulaw since our native format has changed to 0x80002 (gsm|h263) -- Auto fallthrough, channel 'SIP/2110-00000001' status is 'UNKNOWN' == Using SIP RTP CoS mark 5 -- Executing [8000@default:1] Playback("SIP/2110-00000002", "welcome") in new stack -- <SIP/2110-00000002> Playing 'welcome.gsm' (language 'en') [Apr 8 17:18:00] NOTICE[5236]: channel.c:3068 __ast_read: Dropping incompatible voice frame on SIP/2110-00000002 of format ulaw since our native format has changed to 0x80002 (gsm|h263) -- Auto fallthrough, channel 'SIP/2110-00000002' status is 'UNKNOWN' linux5*CLI> exit |
#vim extensions.conf
--- /tmp/l3-saved-5151.32622.16741 2013-04-08 17:18:07.000000000 +0300 +++ extensions.conf 2013-04-08 17:18:18.000000000 +0300 @@ -2,4 +2,4 @@ [default] exten => 8000,1,Playback(welcome) -exten => 21XX,1,Dial(SIP\${EXTEN},30) +exten => _21XX,1,Dial(SIP\${EXTEN},30) |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) Verbosity is at least 3 linux5*CLI> dialplan reload ... -- Added extension '700' priority 1 to parkedcalls (0x8c6a1e8) -- Time to scan old dialplan and merge leftovers back into the new: 0.000588 sec -- Time to restore hints and swap in new dialplan: 0.000001 sec -- Time to delete the old dialplan: 0.000038 sec -- Total time merge_contexts_delete: 0.000627 sec == Using SIP RTP CoS mark 5 -- Executing [2110@default:1] Dial("SIP/2101-00000003", "SIP\2110,30") in new stack [Apr 8 17:18:32] WARNING[5262]: app_dial.c:1663 dial_exec_full: Dial argument takes format (technology/[device:]number1) == Spawn extension (default, 2110, 1) exited non-zero on 'SIP/2101-00000003' linux5*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze10, Copyright (C) 1999 - 2010 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.6.2.9-2+squeeze10 currently running on linux5 (pid = 4524) Verbosity is at least 3 linux5*CLI> dialplan reload ... -- Added extension '700' priority 1 to parkedcalls (0x8c6a1e8) -- Time to scan old dialplan and merge leftovers back into the new: 0.000588 sec -- Time to restore hints and swap in new dialplan: 0.000001 sec -- Time to delete the old dialplan: 0.000038 sec -- Total time merge_contexts_delete: 0.000627 sec == Using SIP RTP CoS mark 5 -- Executing [2110@default:1] Dial("SIP/2101-00000003", "SIP\2110,30") in new stack [Apr 8 17:18:32] WARNING[5262]: app_dial.c:1663 dial_exec_full: Dial argument takes format (technology/[device:]number1) == Spawn extension (default, 2110, 1) exited non-zero on 'SIP/2101-00000003' linux5*CLI> exit |
#vim extensions.conf
--- /tmp/l3-saved-5151.19986.13909 2013-04-08 17:18:45.000000000 +0300 +++ extensions.conf 2013-04-08 17:19:01.000000000 +0300 @@ -2,4 +2,4 @@ [default] exten => 8000,1,Playback(welcome) -exten => _21XX,1,Dial(SIP\${EXTEN},30) +exten => _21XX,1,Dial(SIP/${EXTEN},30) |
#vim extensions.conf
--- /tmp/l3-saved-5151.16762.15387 2013-04-08 17:19:05.000000000 +0300 +++ extensions.conf 2013-04-08 17:20:50.000000000 +0300 @@ -1,5 +1,9 @@ ; extension.conf [default] -exten => 8000,1,Playback(welcome) +exten => 8000,1,Answer +exten => 8000,n,Wait(2) +exten => 8000,n,Playback(welcome) +exten => 8000,n,Playback(congrats) + exten => _21XX,1,Dial(SIP/${EXTEN},30) |
# This file allows you to alter the configuration of the Asterisk # init.d script. Normally you should leave the file as-is. # # RUNASTERISK: If set to anything other that 'yes', the asterisk init.d script # will not run. The default is 'yes'. #RUNASTERISK=no # # # AST_REALTIME: if set to anything other than "no", asterisk will run in # real-time priority (pass '-p' to asterisk). un-rem the # following line to disable asterisk from running in real-time # priority. The default is 'yes'. #AST_REALTIME=no # # PARAMS: extra parameters to pass to asterisk: generate cores in # case of crash, and be more verbose. -F guarantees that Asterisk # will still run daemonized. # # Instead of adding switches here, consider editing # /etc/asterisk/asterisk.conf #PARAMS="-F -g -vvv" # # # RUNASTSAFE: run safe_asterisk rather than asterisk (will auto-restart upon # crash). This is generally less tested and has some known issues # with properly starting and stopping Asterisk. #RUNASTSAFE=yes # # ASTSAFE_CONSOLE: whether you want safe_asterisk to spawn a console for Asterisk. #ASTSAFE_CONSOLE=yes # # ASTSAFE_TTY: tty for Asterisk to run on (only for safe_asterisk) #ASTSAFE_TTY=9 # # MAXFILES: Set this to the number of open file handles the Asterisk # process can have. Useful if you get "Too many open files" error. #MAXFILES=8192 # # AST_DUMPCORE: if set to anything other than "no", asterisk will be run with # the option -g (to tell it to dump core on crash) and its # working directory will be set to /var/spool/asterisk, as that # directory is writable and hence core files can be written there. # See /etc/init.d/asterisk for some other relevant variables. # # It is recommended that you install asterisk-dbg to be able # to produce meaningful backtraces from the core file. # # By default core files will be written to /tmp (can be # changed by setting AST_DUMPCORE_DIR). Alternatively, see # CORE_PATTERN below. #AST_DUMPCORE=yes # # AST_DUMPCORE_DIR: By default asterisk runs in the directory '/' like any # daemon. Setting this allows you to tell it to tell the # Asterisk daemon to run in a different directory if # AST_DUMPCORE is enabled. The default is # /var/spool/asterisk. That is a good choice because it # is writable (thus enabling the actual writing of the # core file) but relatively immune to symlink attacks # (because not world-writable like /tmp/). # Note, however, that if CORE_PATTERN is an absolute # path, it will override AST_DUMPCORE_DIR. # # CORE_PATTERN: If you use AST_DUMPCORE above, this is optionally set to a # pattern of the core file. The default is not to touch the # core_pattern settings, which is generally a good idea as # it affects every core file generated on your system. # # However if you just enable generation of core files and run # asterisk as a daemon it will fail to write core files. # # Alternatively you can set this independently elsewhere. # See http://lxr.linux.no/source/Documentation/sysctl/kernel.txt # Here is what Asterisk's ast_grab_core # script would expect: #CORE_PATTERN='core.%p' # But you might prefer something like: #CORE_PATTERN='core.%e.%t'
# Defaults for dhcp initscript # sourced by /etc/init.d/dhcp # installed at /etc/default/isc-dhcp-server by the maintainer scripts # # This is a POSIX shell fragment # # On what interfaces should the DHCP server (dhcpd) serve DHCP requests? # Separate multiple interfaces with spaces, e.g. "eth0 eth1". INTERFACES=""
Время первой команды журнала | 14:26:55 2013- 4- 8 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 16:19:01 2013- 4- 8 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 3.96 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 3.96 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 1.87 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.90 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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