/l3/users/2014-11-nt-voip/nt-voip/debian1/root :1 :2 :3 :4 |
|
#apt-get install asterisk-mysql
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: asterisk-mysql 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 658 kB of archives. After this operation, 783 kB of additional disk space will be used. Get:1 http://192.168.12.254/debian/ wheezy/main asterisk-mysql amd64 1:1.8.13.1~dfsg1-3+deb7u3 [658 kB] Fetched 658 kB in 0s (9,743 kB/s) Selecting previously unselected package asterisk-mysql. (Reading database ... 145253 files and directories currently installed.) Unpacking asterisk-mysql (from .../asterisk-mysql_1%3a1.8.13.1~dfsg1-3+deb7u3_amd64.deb) ... Setting up asterisk-mysql (1:1.8.13.1~dfsg1-3+deb7u3) ... |
#dpkg -L asterisk-mysql
/. /usr /usr/lib /usr/lib/asterisk /usr/lib/asterisk/modules /usr/lib/asterisk/modules/cdr_mysql.so /usr/lib/asterisk/modules/app_mysql.so /usr/lib/asterisk/modules/res_config_mysql.so /usr/share /usr/share/doc /usr/share/doc/asterisk-mysql /usr/share/doc/asterisk-mysql/NEWS.Debian.gz /usr/share/doc/asterisk-mysql/changelog.gz /usr/share/doc/asterisk-mysql/changelog.Debian.gz /usr/share/doc/asterisk-mysql/copyright |
#dpkg -L asterisk-mysql
/. /usr /usr/lib /usr/lib/asterisk /usr/lib/asterisk/modules /usr/lib/asterisk/modules/cdr_mysql.so /usr/lib/asterisk/modules/app_mysql.so /usr/lib/asterisk/modules/res_config_mysql.so /usr/share /usr/share/doc /usr/share/doc/asterisk-mysql /usr/share/doc/asterisk-mysql/NEWS.Debian.gz /usr/share/doc/asterisk-mysql/changelog.gz /usr/share/doc/asterisk-mysql/changelog.Debian.gz /usr/share/doc/asterisk-mysql/copyright |
#mysql -u root -p < /tmp/1.sql
Enter password: ERROR 1008 (HY000) at line 2: Can't drop database 'asterisk'; database doesn't exist |
#mysql -u root -p < /tmp/1.sql
Enter password: ERROR 1008 (HY000) at line 2: Can't drop database 'asterisk'; database doesn't exist |
# ALTER TABLE cdr ADD INDEX ( uniqueid );
drop database if exists asterisk; create database asterisk; use asterisk; CREATE TABLE cdr ( calldate datetime NOT NULL default '0000-00-00 00:00:00', clid varchar(80) NOT NULL default '', src varchar(80) NOT NULL default '', dst varchar(80) NOT NULL default '', dcontext varchar(80) NOT NULL default '', channel varchar(80) NOT NULL default '', ... billsec int(11) NOT NULL default '0', disposition varchar(45) NOT NULL default '', amaflags int(11) NOT NULL default '0', accountcode varchar(20) NOT NULL default '', userfield varchar(255) NOT NULL default '', uniqueid varchar(32) NOT NULL default '' ); ALTER TABLE cdr ADD INDEX ( calldate ); ALTER TABLE cdr ADD INDEX ( dst ); ALTER TABLE cdr ADD INDEX ( uniqueid ); |
# ALTER TABLE cdr ADD INDEX ( uniqueid );
drop database if exists asterisk; create database asterisk; use asterisk; CREATE TABLE cdr ( calldate datetime NOT NULL default '0000-00-00 00:00:00', clid varchar(80) NOT NULL default '', src varchar(80) NOT NULL default '', dst varchar(80) NOT NULL default '', dcontext varchar(80) NOT NULL default '', channel varchar(80) NOT NULL default '', ... billsec int(11) NOT NULL default '0', disposition varchar(45) NOT NULL default '', amaflags int(11) NOT NULL default '0', accountcode varchar(20) NOT NULL default '', userfield varchar(255) NOT NULL default '', uniqueid varchar(32) NOT NULL default '' ); ALTER TABLE cdr ADD INDEX ( calldate ); ALTER TABLE cdr ADD INDEX ( dst ); ALTER TABLE cdr ADD INDEX ( uniqueid ); |
#mysql -u root -p
Enter password: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO) |
#mysql -u root -p
Enter password: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO) |
#mysql -u root -p
Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 46 Server version: 5.5.40-0+wheezy1 (Debian) Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use asterisk; ... -> to 'asterisk'@'localhost'; Query OK, 0 rows affected (0.00 sec) mysql> SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); Query OK, 0 rows affected (0.00 sec) mysql> #SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); mysql> Bye -> BYE -> -> ^CCtrl-C -- exit! Aborted |
#mysql -u root -p
Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 46 Server version: 5.5.40-0+wheezy1 (Debian) Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use asterisk; ... -> to 'asterisk'@'localhost'; Query OK, 0 rows affected (0.00 sec) mysql> SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); Query OK, 0 rows affected (0.00 sec) mysql> #SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); mysql> Bye -> BYE -> -> ^CCtrl-C -- exit! Aborted |
#mysql -u asterisk -p
Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 49 Server version: 5.5.40-0+wheezy1 (Debian) Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use asterisk; ... -> #SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); -> SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'Bye SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password')' at line 1 mysql> SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); Query OK, 0 rows affected (0.00 sec) mysql> #SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); mysql> Bye -> ^CCtrl-C -- exit! Aborted |
#mysql -u asterisk -p
Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 49 Server version: 5.5.40-0+wheezy1 (Debian) Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use asterisk; ... -> #SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); -> SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'Bye SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password')' at line 1 mysql> SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); Query OK, 0 rows affected (0.00 sec) mysql> #SET PASSWORD FOR 'asterisk'@'localhost' = PASSWORD('password'); mysql> Bye -> ^CCtrl-C -- exit! Aborted |
#ls -l /etc/asterisk/cdr_mysql.conf
-rw-r----- 1 asterisk asterisk 2231 Jan 4 2014 /etc/asterisk/cdr_mysql.conf |
#ls -l /etc/asterisk/cdr_mysql.conf
-rw-r----- 1 asterisk asterisk 2231 Jan 4 2014 /etc/asterisk/cdr_mysql.conf |
#vim /etc/asterisk/cdr_mysql.conf
--- /tmp/l3-saved-3627.24368.26881 2014-11-28 15:19:43.343328551 +0200 +++ /etc/asterisk/cdr_mysql.conf 2014-11-28 15:21:34.003329853 +0200 @@ -12,10 +12,10 @@ ; ;[global] ;hostname=database.host.name -;dbname=asteriskcdrdb +;dbname=asterisk ;table=cdr ;password=password -;user=asteriskcdruser +;user=asterisk ;port=3306 ;sock=/tmp/mysql.sock ;timezone=UTC ; Previously called usegmtime |
#mysql -u asterisk -p
Enter password: ERROR 1045 (28000): Access denied for user 'asterisk'@'localhost' (using password: YES) |
#mysql -u asterisk -p
Enter password: ERROR 1045 (28000): Access denied for user 'asterisk'@'localhost' (using password: YES) |
#mysql -u asterisk -p
Enter password: ERROR 1045 (28000): Access denied for user 'asterisk'@'localhost' (using password: YES) |
#mysql -u asterisk -p
Enter password: ERROR 1045 (28000): Access denied for user 'asterisk'@'localhost' (using password: YES) |
#mysql -u asterisk -p
Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 56 Server version: 5.5.40-0+wheezy1 (Debian) Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use asterisk Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed mysql> exit Bye |
#mysql -u asterisk -p
Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 56 Server version: 5.5.40-0+wheezy1 (Debian) Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use asterisk Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed mysql> exit Bye |
#[global]
; Asterisk Call Detail Record engine configuration ; ; CDR is Call Detail Record, which provides logging services via a variety of ; pluggable backend modules. Detailed call information can be recorded to [ ] [ databa]es, files, etc. Useful for billing, fraud prevention, compliance with ; Sarbanes-Oxley aka The Enron Act, QOS evaluations, and more. enable=yes ; s",neral] ... ; redundant, but cannot be helped. ve an A ; Define whether or not to log unanswered calls. Setting this to "yes" will illarty. Calls which get offered to an outgoing line, but are unanswered, are stt ; report every attempt to ring a phone in dialing attempts, when it was not Rs being, and that is the intended behaviour. (It also results in some B side CDD ; answered. For example, if you try to dial 3 extensions, and this option is "yee ationput, as they have the B side channel as their source channel, and no destinn ; channel.) "/etc/asterisk/cdr.conf" 165L, 8380C written |
#[global]
; Asterisk Call Detail Record engine configuration ; ; CDR is Call Detail Record, which provides logging services via a variety of ; pluggable backend modules. Detailed call information can be recorded to [ ] [ databa]es, files, etc. Useful for billing, fraud prevention, compliance with ; Sarbanes-Oxley aka The Enron Act, QOS evaluations, and more. enable=yes ; s",neral] ... ; redundant, but cannot be helped. ve an A ; Define whether or not to log unanswered calls. Setting this to "yes" will illarty. Calls which get offered to an outgoing line, but are unanswered, are stt ; report every attempt to ring a phone in dialing attempts, when it was not Rs being, and that is the intended behaviour. (It also results in some B side CDD ; answered. For example, if you try to dial 3 extensions, and this option is "yee ationput, as they have the B side channel as their source channel, and no destinn ; channel.) "/etc/asterisk/cdr.conf" 165L, 8380C written |
#/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. |
#less /var/log/asterisk/messages
|
#[Nov 28 15:40:42] NOTICE[10611] res_smdi.c: No SMDI interfaces are available to listen on, not starting SMDI list
; ; Note - if the database server is hosted on the same machine as the ; asterisk server, you can achieve a local Unix socket connection by ; setting hostname=localhost ; ; port and sock are both optional parameters. If hostname is specified ; and is not "localhost" (you can use address 127.0.0.1 instead), then ; cdr_mysql will attempt to connect to the port specified or use the ; default port. If hostname is not specified or if hostname is ; "localhost", then cdr_mysql will attempt to connect to the socket file ... ;alias dstchannel => <a_field_not_named_dstchannel> ;alias lastapp => <a_field_not_named_lastapp> ;alias lastdata => <a_field_not_named_lastdata> ;alias duration => <a_field_not_named_duration> ;alias billsec => <a_field_not_named_billsec> ;alias disposition => <a_field_not_named_disposition> ;alias amaflags => <a_field_not_named_amaflags> ;alias accountcode => <a_field_not_named_accountcode> ;alias userfield => <a_field_not_named_userfield> ;alias uniqueid => <a_field_not_named_uniqueid> |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#vim /etc/asterisk/cdr_mysql.conf
|
#[global]
; is "yes". ;safeshutdown=yes ; ; ; CHOOSING A CDR "BACKEND" (what kind of output to generate) ; ; To choose a backend, you have to make sure either the right category is ; defined in this file, or that the appropriate config file exists, and has the ; proper definitions in it. If there are any problems, usually, the entry will ; silently ignored, and you get no output. ... ; find this information horribly useless. Others find it very valuable. Note, in "yes" ; mode, you will see one CDR, with one of the call targets on one side, and the originating ; channel on the other, and then one CDR for each channel attempted. This may seem ; redundant, but cannot be helped. ; ; In brief, this option controls the reporting of unanswered calls which only have an A ; party. Calls which get offered to an outgoing line, but are unanswered, are still ; logged, and that is the intended behaviour. (It also results in some B side CDRs being ; output, as they have the B side channel as their source channel, and no destination ; channel.) |
#;unanswered = no
|
#asterisk -v
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core show warranty' for details. This is free software, with components licensed under the GNU General Public License version 2 and other licenses; you are welcome to redistribute it under certain conditions. Type 'core show license' for details. ========================================================================= Privilege escalation protection disabled! See https://wiki.asterisk.org/wiki/x/1gKfAQ for more details. Asterisk already running on /var/run/asterisk/asterisk.ctl. Use 'asterisk -r' to connect. |
#asterisk -v
Asterisk 1.8.13.1~dfsg1-3+deb7u3, Copyright (C) 1999 - 2012 Digium, Inc. and others. Created by Mark Spencer <markster@digium.com> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core show warranty' for details. This is free software, with components licensed under the GNU General Public License version 2 and other licenses; you are welcome to redistribute it under certain conditions. Type 'core show license' for details. ========================================================================= Privilege escalation protection disabled! See https://wiki.asterisk.org/wiki/x/1gKfAQ for more details. Asterisk already running on /var/run/asterisk/asterisk.ctl. Use 'asterisk -r' to connect. |
#cp /usr/share/nginx/www/asterisk-13-current.tar.gz
cp: missing destination file operand after `/usr/share/nginx/www/asterisk-13-current.tar.gz' Try `cp --help' for more information. |
#cp /usr/share/nginx/www/asterisk-13-current.tar.gz
cp: missing destination file operand after `/usr/share/nginx/www/asterisk-13-current.tar.gz' Try `cp --help' for more information. |
#cp /usr/share/nginx/www/asterisk-13-current.tar.gz .
cp: cannot stat `/usr/share/nginx/www/asterisk-13-current.tar.gz': No such file or directory |
#cp /usr/share/nginx/www/asterisk-13-current.tar.gz .
cp: cannot stat `/usr/share/nginx/www/asterisk-13-current.tar.gz': No such file or directory |
#apt-get install libncurses5-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libtinfo-dev Suggested packages: ncurses-doc The following NEW packages will be installed: libncurses5-dev libtinfo-dev 0 upgraded, 2 newly installed, 0 to remove and 5 not upgraded. ... Get:1 http://192.168.12.254/debian/ wheezy/main libtinfo-dev amd64 5.9-10 [105 kB] Get:2 http://192.168.12.254/debian/ wheezy/main libncurses5-dev amd64 5.9-10 [223 kB] Fetched 328 kB in 0s (7,555 kB/s) Selecting previously unselected package libtinfo-dev:amd64. (Reading database ... 145261 files and directories currently installed.) Unpacking libtinfo-dev:amd64 (from .../libtinfo-dev_5.9-10_amd64.deb) ... Selecting previously unselected package libncurses5-dev. Unpacking libncurses5-dev (from .../libncurses5-dev_5.9-10_amd64.deb) ... Setting up libtinfo-dev:amd64 (5.9-10) ... Setting up libncurses5-dev (5.9-10) ... |
#apt-get install libncurses5-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libtinfo-dev Suggested packages: ncurses-doc The following NEW packages will be installed: libncurses5-dev libtinfo-dev 0 upgraded, 2 newly installed, 0 to remove and 5 not upgraded. ... Get:1 http://192.168.12.254/debian/ wheezy/main libtinfo-dev amd64 5.9-10 [105 kB] Get:2 http://192.168.12.254/debian/ wheezy/main libncurses5-dev amd64 5.9-10 [223 kB] Fetched 328 kB in 0s (7,555 kB/s) Selecting previously unselected package libtinfo-dev:amd64. (Reading database ... 145261 files and directories currently installed.) Unpacking libtinfo-dev:amd64 (from .../libtinfo-dev_5.9-10_amd64.deb) ... Selecting previously unselected package libncurses5-dev. Unpacking libncurses5-dev (from .../libncurses5-dev_5.9-10_amd64.deb) ... Setting up libtinfo-dev:amd64 (5.9-10) ... Setting up libncurses5-dev (5.9-10) ... |
#apt-get install libuuid
Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package libuuid |
#apt-get install libuuid
Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package libuuid |
#apt-cache search libuuid
libdata-uuid-libuuid-perl - uuid.h based UUID generation module libuuid-perl - Perl extension for using UUID interfaces as defined in e2fsprogs libuuid-tiny-perl - pure Perl module to generate v1, v3, v4, and v5 UUIDs libuuidtools-ruby - Transitional package for ruby-uuidtools libuuidtools-ruby-doc - Transitional package for ruby-uuidtools libuuidtools-ruby1.8 - Transitional package for ruby-uuidtools libuuidtools-ruby1.9.1 - Transitional package for ruby-uuidtools ruby-uuidtools - UUIDs generation library for Ruby ruby-uuidtools-doc - UUIDs generation library for Ruby - documentation libuuid1 - Universally Unique ID library uuid-dev - universally unique id library - headers and static libraries uuid-runtime - runtime components for the Universally Unique ID library libuuidm-ocaml-dev - Universally unique identifiers for OCaml |
#apt-cache search libuuid
libdata-uuid-libuuid-perl - uuid.h based UUID generation module libuuid-perl - Perl extension for using UUID interfaces as defined in e2fsprogs libuuid-tiny-perl - pure Perl module to generate v1, v3, v4, and v5 UUIDs libuuidtools-ruby - Transitional package for ruby-uuidtools libuuidtools-ruby-doc - Transitional package for ruby-uuidtools libuuidtools-ruby1.8 - Transitional package for ruby-uuidtools libuuidtools-ruby1.9.1 - Transitional package for ruby-uuidtools ruby-uuidtools - UUIDs generation library for Ruby ruby-uuidtools-doc - UUIDs generation library for Ruby - documentation libuuid1 - Universally Unique ID library uuid-dev - universally unique id library - headers and static libraries uuid-runtime - runtime components for the Universally Unique ID library libuuidm-ocaml-dev - Universally unique identifiers for OCaml |
#apt-get install uuid-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: uuid-dev 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 72.4 kB of archives. After this operation, 98.3 kB of additional disk space will be used. Get:1 http://192.168.12.254/debian/ wheezy/main uuid-dev amd64 2.20.1-5.3 [72.4 kB] Fetched 72.4 kB in 0s (4,615 kB/s) Selecting previously unselected package uuid-dev. (Reading database ... 145309 files and directories currently installed.) Unpacking uuid-dev (from .../uuid-dev_2.20.1-5.3_amd64.deb) ... Processing triggers for man-db ... Setting up uuid-dev (2.20.1-5.3) ... |
#apt-get install uuid-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: uuid-dev 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 72.4 kB of archives. After this operation, 98.3 kB of additional disk space will be used. Get:1 http://192.168.12.254/debian/ wheezy/main uuid-dev amd64 2.20.1-5.3 [72.4 kB] Fetched 72.4 kB in 0s (4,615 kB/s) Selecting previously unselected package uuid-dev. (Reading database ... 145309 files and directories currently installed.) Unpacking uuid-dev (from .../uuid-dev_2.20.1-5.3_amd64.deb) ... Processing triggers for man-db ... Setting up uuid-dev (2.20.1-5.3) ... |
#apt-cache search libjansson
libjansson-dbg - C library for encoding, decoding and manipulating JSON data (debug) libjansson-dev - C library for encoding, decoding and manipulating JSON data (dev) libjansson-doc - C library for encoding, decoding and manipulating JSON data (doc) libjansson4 - C library for encoding, decoding and manipulating JSON data |
#apt-cache search libjansson
libjansson-dbg - C library for encoding, decoding and manipulating JSON data (debug) libjansson-dev - C library for encoding, decoding and manipulating JSON data (dev) libjansson-doc - C library for encoding, decoding and manipulating JSON data (doc) libjansson4 - C library for encoding, decoding and manipulating JSON data |
#apt-get install libjansson-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libjansson4 The following NEW packages will be installed: libjansson-dev libjansson4 0 upgraded, 2 newly installed, 0 to remove and 5 not upgraded. Need to get 66.2 kB of archives. After this operation, 233 kB of additional disk space will be used. Do you want to continue [Y/n]? y Get:1 http://192.168.12.254/debian/ wheezy/main libjansson4 amd64 2.3.1-2 [31.6 kB] Get:2 http://192.168.12.254/debian/ wheezy/main libjansson-dev amd64 2.3.1-2 [34.6 kB] Fetched 66.2 kB in 0s (2,901 kB/s) Selecting previously unselected package libjansson4:amd64. (Reading database ... 145331 files and directories currently installed.) Unpacking libjansson4:amd64 (from .../libjansson4_2.3.1-2_amd64.deb) ... Selecting previously unselected package libjansson-dev:amd64. Unpacking libjansson-dev:amd64 (from .../libjansson-dev_2.3.1-2_amd64.deb) ... Setting up libjansson4:amd64 (2.3.1-2) ... Setting up libjansson-dev:amd64 (2.3.1-2) ... |
#apt-get install libjansson-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libjansson4 The following NEW packages will be installed: libjansson-dev libjansson4 0 upgraded, 2 newly installed, 0 to remove and 5 not upgraded. Need to get 66.2 kB of archives. After this operation, 233 kB of additional disk space will be used. Do you want to continue [Y/n]? y Get:1 http://192.168.12.254/debian/ wheezy/main libjansson4 amd64 2.3.1-2 [31.6 kB] Get:2 http://192.168.12.254/debian/ wheezy/main libjansson-dev amd64 2.3.1-2 [34.6 kB] Fetched 66.2 kB in 0s (2,901 kB/s) Selecting previously unselected package libjansson4:amd64. (Reading database ... 145331 files and directories currently installed.) Unpacking libjansson4:amd64 (from .../libjansson4_2.3.1-2_amd64.deb) ... Selecting previously unselected package libjansson-dev:amd64. Unpacking libjansson-dev:amd64 (from .../libjansson-dev_2.3.1-2_amd64.deb) ... Setting up libjansson4:amd64 (2.3.1-2) ... Setting up libjansson-dev:amd64 (2.3.1-2) ... |
#apt-get install libxml2-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: libxml2-dev 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 901 kB of archives. After this operation, 2,798 kB of additional disk space will be used. Get:1 http://security.debian.org/ wheezy/updates/main libxml2-dev amd64 2.8.0+dfsg1-7+wheezy2 [901 kB] Fetched 901 kB in 0s (1,375 kB/s) Selecting previously unselected package libxml2-dev:amd64. (Reading database ... 145349 files and directories currently installed.) Unpacking libxml2-dev:amd64 (from .../libxml2-dev_2.8.0+dfsg1-7+wheezy2_amd64.deb) ... Processing triggers for man-db ... Setting up libxml2-dev:amd64 (2.8.0+dfsg1-7+wheezy2) ... |
#apt-get install libxml2-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: libxml2-dev 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 901 kB of archives. After this operation, 2,798 kB of additional disk space will be used. Get:1 http://security.debian.org/ wheezy/updates/main libxml2-dev amd64 2.8.0+dfsg1-7+wheezy2 [901 kB] Fetched 901 kB in 0s (1,375 kB/s) Selecting previously unselected package libxml2-dev:amd64. (Reading database ... 145349 files and directories currently installed.) Unpacking libxml2-dev:amd64 (from .../libxml2-dev_2.8.0+dfsg1-7+wheezy2_amd64.deb) ... Processing triggers for man-db ... Setting up libxml2-dev:amd64 (2.8.0+dfsg1-7+wheezy2) ... |
#apt-get install libxml2-dev libxml2
Reading package lists... Done Building dependency tree Reading state information... Done libxml2 is already the newest version. libxml2 set to manually installed. libxml2-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded. |
#apt-get install libxml2-dev libxml2
Reading package lists... Done Building dependency tree Reading state information... Done libxml2 is already the newest version. libxml2 set to manually installed. libxml2-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded. |
#apt-get install libsqlite3-dev
Reading package lists... Done Building dependency tree Reading state information... Done Suggested packages: sqlite3-doc The following NEW packages will be installed: libsqlite3-dev 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 578 kB of archives. After this operation, 1,382 kB of additional disk space will be used. Get:1 http://192.168.12.254/debian/ wheezy/main libsqlite3-dev amd64 3.7.13-1+deb7u1 [578 kB] Fetched 578 kB in 0s (9,227 kB/s) Selecting previously unselected package libsqlite3-dev. (Reading database ... 145413 files and directories currently installed.) Unpacking libsqlite3-dev (from .../libsqlite3-dev_3.7.13-1+deb7u1_amd64.deb) ... Setting up libsqlite3-dev (3.7.13-1+deb7u1) ... |
#apt-get install libsqlite3-dev
Reading package lists... Done Building dependency tree Reading state information... Done Suggested packages: sqlite3-doc The following NEW packages will be installed: libsqlite3-dev 0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded. Need to get 578 kB of archives. After this operation, 1,382 kB of additional disk space will be used. Get:1 http://192.168.12.254/debian/ wheezy/main libsqlite3-dev amd64 3.7.13-1+deb7u1 [578 kB] Fetched 578 kB in 0s (9,227 kB/s) Selecting previously unselected package libsqlite3-dev. (Reading database ... 145413 files and directories currently installed.) Unpacking libsqlite3-dev (from .../libsqlite3-dev_3.7.13-1+deb7u1_amd64.deb) ... Setting up libsqlite3-dev (3.7.13-1+deb7u1) ... |
#apt-get install libxml2-dev
Reading package lists... Done Building dependency tree Reading state information... Done libxml2-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded. |
#apt-get install libxml2-dev
Reading package lists... Done Building dependency tree Reading state information... Done libxml2-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded. |
#./configure
cd asterisk-13-current.tar.gz bash: cd: asterisk-13-current.tar.gz: Not a directory |
#./configure
cd asterisk-13-current.tar.gz bash: cd: asterisk-13-current.tar.gz: Not a directory |
#./configure
checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes ... $$$$$ $$$ $$$$7. $$ (TM) $$$$$$$. .7$$$$$$ $$ $$$$$$$$$$$$7$$$$$$$$$.$$$$$$ $$$$$$$$$$$$$$$$. configure: Package configured for: configure: OS type : linux-gnu configure: Host CPU : x86_64 configure: build-cpu:vendor:os: x86_64 : unknown : linux-gnu : configure: host-cpu:vendor:os: x86_64 : unknown : linux-gnu : |
#./configure
checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes ... $$$$$ $$$ $$$$7. $$ (TM) $$$$$$$. .7$$$$$$ $$ $$$$$$$$$$$$7$$$$$$$$$.$$$$$$ $$$$$$$$$$$$$$$$. configure: Package configured for: configure: OS type : linux-gnu configure: Host CPU : x86_64 configure: build-cpu:vendor:os: x86_64 : unknown : linux-gnu : configure: host-cpu:vendor:os: x86_64 : unknown : linux-gnu : |
#make menuconfig
************************************************** Asterisk Module and Build Option Selection ************************************************** Press 'h' for help. --- Core --- [*] res_adsi [*] res_agi [*] res_ari [*] res_ari_applications [*] res_ari_asterisk ... XXX res_calendar_exchange XXX res_calendar_icalendar [*] res_clialiases [*] res_clioriginate XXX res_config_curl ... More ... CLI Aliases Depends on: neon29(E) (E), ical(E) Support Level: core |
#make menuconfig
************************************************** Asterisk Module and Build Option Selection ************************************************** Press 'h' for help. --- Core --- [*] res_adsi [*] res_agi [*] res_ari [*] res_ari_applications [*] res_ari_asterisk ... XXX res_calendar_exchange XXX res_calendar_icalendar [*] res_clialiases [*] res_clioriginate XXX res_config_curl ... More ... CLI Aliases Depends on: neon29(E) (E), ical(E) Support Level: core |
#apt-get install libssl-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libssl-doc zlib1g-dev The following NEW packages will be installed: libssl-dev libssl-doc zlib1g-dev 0 upgraded, 3 newly installed, 0 to remove and 5 not upgraded. Need to get 3,168 kB of archives. After this operation, 8,364 kB of additional disk space will be used. ... (Reading database ... 145424 files and directories currently installed.) Unpacking zlib1g-dev:amd64 (from .../zlib1g-dev_1%3a1.2.7.dfsg-13_amd64.deb) ... Selecting previously unselected package libssl-dev. Unpacking libssl-dev (from .../libssl-dev_1.0.1e-2+deb7u13_amd64.deb) ... Selecting previously unselected package libssl-doc. Unpacking libssl-doc (from .../libssl-doc_1.0.1e-2+deb7u13_all.deb) ... Processing triggers for man-db ... Setting up zlib1g-dev:amd64 (1:1.2.7.dfsg-13) ... Setting up libssl-dev (1.0.1e-2+deb7u13) ... Setting up libssl-doc (1.0.1e-2+deb7u13) ... |
#apt-get install libssl-dev
Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libssl-doc zlib1g-dev The following NEW packages will be installed: libssl-dev libssl-doc zlib1g-dev 0 upgraded, 3 newly installed, 0 to remove and 5 not upgraded. Need to get 3,168 kB of archives. After this operation, 8,364 kB of additional disk space will be used. ... (Reading database ... 145424 files and directories currently installed.) Unpacking zlib1g-dev:amd64 (from .../zlib1g-dev_1%3a1.2.7.dfsg-13_amd64.deb) ... Selecting previously unselected package libssl-dev. Unpacking libssl-dev (from .../libssl-dev_1.0.1e-2+deb7u13_amd64.deb) ... Selecting previously unselected package libssl-doc. Unpacking libssl-doc (from .../libssl-doc_1.0.1e-2+deb7u13_all.deb) ... Processing triggers for man-db ... Setting up zlib1g-dev:amd64 (1:1.2.7.dfsg-13) ... Setting up libssl-dev (1.0.1e-2+deb7u13) ... Setting up libssl-doc (1.0.1e-2+deb7u13) ... |
Время первой команды журнала | 13:51:15 2014-11-28 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 16:05:28 2014-11-28 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 25.74 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 13.86 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 1.33 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 1.26 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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