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

Содержание

Журнал

Понедельник (12/07/09)

/dev/tty1
13:16:39
#apt-get install xfce4-session
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  aspell aspell-en dbus dbus-x11 defoma desktop-file-utils exo-utils
  fontconfig fontconfig-config fortune-mod fortunes-min gamin gconf2
  gconf2-common gtk2-engines-xfce hal hal-info hicolor-icon-theme libaspell15
  libatk1.0-0 libatk1.0-data libcairo2 libcroco3 libcups2 libdatrie0
  libdbus-1-3 libdbus-glib-1-2 libdirectfb-1.0-0 libdirectfb-extra libdrm2
  libenchant1c2a libexif12 libexo-0.3-0 libexpat1 libfontconfig1 libfontenc1
...
Setting up fortune-mod (1:1.99.1-3.1) ...
Setting up fortunes-min (1:1.99.1-3.1) ...
Setting up gamin (0.1.9-2) ...
Setting up libgamin0 (0.1.9-2) ...
Setting up libthunar-vfs-1-2 (0.9.0-10) ...
Setting up thunar (0.9.0-10) ...
Setting up xfce4-session (4.4.2-6) ...
Setting up xfdesktop4 (4.4.2-7) ...
Processing triggers for initramfs-tools ...
update-initramfs: Generating /boot/initrd.img-2.6.26-2-686
13:19:03
#passwd user
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
/dev/tty1
13:19:59
#chown -R user:user /home/user

/dev/tty1
13:20:30
#apt-get install xfce4
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  a2ps desktop-base ghostscript gs-common gsfonts libasound2 libcupsimage2
  libcupsys2 libgl1-mesa-dri libglu1-mesa libgs8 libpaper-utils libpaper1
  libvte-common libvte9 lpr orage psfontmgr psutils wdiff xfce4-mixer
  xfce4-mixer-alsa xfce4-terminal xfonts-100dpi xfonts-75dpi xfonts-base
  xfonts-scalable xfprint4 xkb-data xorg xorg-docs xserver-xorg
  xserver-xorg-core xserver-xorg-input-all xserver-xorg-input-evdev
...
Cleaning up category type1..
Updating category type1..
Updating category type3..
Updating category gsfontderivative..
Updating category truetype..
Updating category cid..
Updating category cmap..
Updating category psprint..
Processing triggers for initramfs-tools ...
update-initramfs: Generating /boot/initrd.img-2.6.26-2-686
/dev/pts/0
13:24:16
#apt-get install iceweasel
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  liblcms1 libmozjs1d libnspr4-0d libnss3-1d xulrunner-1.9
Suggested packages:
  xulrunner-1.9-gnome-support latex-xft-fonts xfonts-mathml ttf-mathematica4.1
  xprint mozplugger liblcms-utils
The following NEW packages will be installed:
  iceweasel liblcms1 libmozjs1d libnspr4-0d libnss3-1d xulrunner-1.9
...
Unpacking xulrunner-1.9 (from .../xulrunner-1.9_1.9.0.15-0lenny1_i386.deb) ...
Selecting previously deselected package iceweasel.
Unpacking iceweasel (from .../iceweasel_3.0.6-3_i386.deb) ...
Processing triggers for man-db ...
Setting up libnspr4-0d (4.7.1-5) ...
Setting up liblcms1 (1.17.dfsg-1+lenny2) ...
Setting up libmozjs1d (1.9.0.15-0lenny1) ...
Setting up libnss3-1d (3.12.3.1-0lenny1) ...
Setting up xulrunner-1.9 (1.9.0.15-0lenny1) ...
Setting up iceweasel (3.0.6-3) ...
13:24:54
#ifconfig
eth0      Link encap:Ethernet  HWaddr 00:07:e9:3c:2a:3d
          inet addr:192.168.7.3  Bcast:192.168.7.255  Mask:255.255.255.0
          inet6 addr: fe80::207:e9ff:fe3c:2a3d/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:94431 errors:0 dropped:0 overruns:0 frame:0
          TX packets:28478 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:141608125 (135.0 MiB)  TX bytes:2035025 (1.9 MiB)
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:8 errors:0 dropped:0 overruns:0 frame:0
          TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:560 (560.0 B)  TX bytes:560 (560.0 B)
13:27:07
#show arp
bash: show: command not found
13:27:11
#ping ukr.net
^C
13:31:07
#cd /etc/

13:32:07
#vi network/interfaces
--- /tmp/l3-saved-16164.30327.11832	2009-12-07 02:32:41.000000000 -1000
+++ network/interfaces	2009-12-07 02:33:31.000000000 -1000
@@ -8,11 +8,11 @@
 # The primary network interface
 allow-hotplug eth0
 iface eth0 inet static
-	address 192.168.7.3
+	address 192.168.101.3
 	netmask 255.255.255.0
-	network 192.168.7.0
-	broadcast 192.168.7.255
-	gateway 192.168.7.254
+	network 192.168.101.0
+	broadcast 192.168.101.255
+	gateway 192.168.101.254
 	# dns-* options are implemented by the resolvconf package, if installed
 	dns-nameservers 10.0.35.1
 	dns-search unix.nt
13:33:31
#vi network/interfaces
13:34:13
#~
SIOCDELRT: No such process
13:34:19
#ifup eth0

13:34:23
#ifconfig
eth0      Link encap:Ethernet  HWaddr 00:07:e9:3c:2a:3d
          inet addr:192.168.101.3  Bcast:192.168.101.255  Mask:255.255.255.0
          inet6 addr: fe80::207:e9ff:fe3c:2a3d/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:94463 errors:0 dropped:0 overruns:0 frame:0
          TX packets:28631 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:141613028 (135.0 MiB)  TX bytes:2045335 (1.9 MiB)
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:59 errors:0 dropped:0 overruns:0 frame:0
          TX packets:59 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:4912 (4.7 KiB)  TX bytes:4912 (4.7 KiB)
13:34:25
#ping 192.
ping: unknown host 192.
13:34:44
#ping 192.168.101.254
PING 192.168.101.254 (192.168.101.254) 56(84) bytes of data.
64 bytes from 192.168.101.254: icmp_seq=1 ttl=64 time=0.665 ms
64 bytes from 192.168.101.254: icmp_seq=2 ttl=64 time=0.663 ms
^C
--- 192.168.101.254 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1000ms
rtt min/avg/max/mdev = 0.663/0.664/0.665/0.001 ms
13:34:53
#ping 192.168.102.254
PING 192.168.102.254 (192.168.102.254) 56(84) bytes of data.
64 bytes from 192.168.102.254: icmp_seq=1 ttl=64 time=0.819 ms
^C
--- 192.168.102.254 ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.819/0.819/0.819/0.000 ms
13:35:01
#ping 192.168.102.1
PING 192.168.102.1 (192.168.102.1) 56(84) bytes of data.
64 bytes from 192.168.102.1: icmp_seq=1 ttl=63 time=0.289 ms
64 bytes from 192.168.102.1: icmp_seq=2 ttl=63 time=0.330 ms
^C
--- 192.168.102.1 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1000ms
rtt min/avg/max/mdev = 0.289/0.309/0.330/0.027 ms
13:35:04
#ping 192.168.102.1
PING 192.168.102.1 (192.168.102.1) 56(84) bytes of data.
64 bytes from 192.168.102.1: icmp_seq=1 ttl=63 time=0.352 ms
64 bytes from 192.168.102.1: icmp_seq=2 ttl=63 time=0.142 ms
64 bytes from 192.168.102.1: icmp_seq=3 ttl=63 time=0.189 ms
64 bytes from 192.168.102.1: icmp_seq=4 ttl=63 time=0.236 ms
64 bytes from 192.168.102.1: icmp_seq=5 ttl=63 time=0.293 ms
^C
--- 192.168.102.1 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 3996ms
rtt min/avg/max/mdev = 0.142/0.242/0.352/0.075 ms
13:35:15
#ping ukr.net
PING ukr.net (195.214.195.105) 56(84) bytes of data.
64 bytes from 195.214.195.105: icmp_seq=1 ttl=57 time=6.37 ms
^C
--- ukr.net ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 6.376/6.376/6.376/0.000 ms
13:35:38
#apt-cache dhcpsever
E: Invalid operation dhcpsever
13:42:42
#apt-cache search dhcp
autodns-dhcp - Automatic DNS updates for DHCP
avahi-autoipd - Avahi IPv4LL network address configuration daemon
backuppc - high-performance, enterprise-grade system for backing up PCs
bootp - server for the bootp protocol with DHCP support
dhcdbd - D-Bus interface to the ISC DHCP client
dhcp-client - DHCP client transitional package
dhcp-helper - A DHCP relay agent
dhcp3-client - DHCP client
dhcp3-common - common files used by all the dhcp3* packages
dhcp3-dev - API for accessing and modifying the DHCP server and client state
...
pxe - free PXE daemon
resolvconf - name server information handler
totd - Small DNS proxy that supports IPv6/IPv4 record translation
udhcpc - very small DHCP client
udhcpd - very small DHCP server
whereami - Automatically reconfigure your (laptop) system for a new location
wide-dhcpv6-client - DHCPv6 client for automatic IPv6 hosts configuration
wide-dhcpv6-relay - DHCPv6 relay for automatic IPv6 hosts configuration
wide-dhcpv6-server - DHCPv6 server for automatic IPv6 hosts configuration
yersinia - Network vulnerabilities check software
13:42:59
#apt-cache search dhcp server
avahi-autoipd - Avahi IPv4LL network address configuration daemon
bootp - server for the bootp protocol with DHCP support
dhcp-helper - A DHCP relay agent
dhcp3-dev - API for accessing and modifying the DHCP server and client state
dhcp3-relay - DHCP relay daemon
dhcp3-server - DHCP server for automatic IP address assignment
dhcp3-server-ldap - DHCP server able to use LDAP as backend
dhcpdump - Parse DHCP packets from tcpdump
dhcping - DHCP Daemon Ping Program
dhis-server - Dynamic Host Information System - server
...
network-manager - network management framework daemon
network-manager-gnome - network management framework (GNOME frontend)
network-manager-pptp - network management framework (PPTP plugin)
network-manager-pptp-gnome - network management framework (PPTP plugin)
pump - BOOTP and DHCP client for automatic IP configuration
pxe - free PXE daemon
resolvconf - name server information handler
totd - Small DNS proxy that supports IPv6/IPv4 record translation
udhcpd - very small DHCP server
wide-dhcpv6-server - DHCPv6 server for automatic IPv6 hosts configuration
13:43:09
#apt-cache search dhcp3 server
dhcp-helper - A DHCP relay agent
dhcp3-relay - DHCP relay daemon
dhcp3-server - DHCP server for automatic IP address assignment
dhcp3-server-ldap - DHCP server able to use LDAP as backend
udhcpd - very small DHCP server
13:43:14
#apt-get dhcp3-server
E: Invalid operation dhcp3-server
13:43:30
#apt-get install dhcp3-server
 │                                                                           │
 └───────────────────────────────────────────────────────────────────────────┘
Selecting previously deselected package dhcp3-server.
(Reading database ... 38178 files and directories currently installed.)
Unpacking dhcp3-server (from .../dhcp3-server_3.1.1-6+lenny3_i386.deb) ...
Processing triggers for man-db ...
Setting up dhcp3-server (3.1.1-6+lenny3) ...
Generating /etc/default/dhcp3-server...
Starting DHCP server: dhcpd3check syslog for diagnostics. failed!
 failed!
invoke-rc.d: initscript dhcp3-server, action "start" failed.
13:43:45
#cd etc
bash: cd: etc: No such file or directory
13:43:48
#cd /etc

13:43:50
#cd dhcp3/

13:43:59
#ls
dhclient.conf  dhclient-enter-hooks.d  dhclient-exit-hooks.d  dhcpd.conf
13:44:01
#vi dhcpd.conf
--- /tmp/l3-saved-16164.9617.7953	2009-12-07 02:44:13.000000000 -1000
+++ dhcpd.conf	2009-12-07 02:47:22.000000000 -1000
@@ -48,15 +48,15 @@
 #}
 
 # A slightly different configuration for an internal subnet.
-#subnet 10.5.5.0 netmask 255.255.255.224 {
-#  range 10.5.5.26 10.5.5.30;
-#  option domain-name-servers ns1.internal.example.org;
-#  option domain-name "internal.example.org";
-#  option routers 10.5.5.1;
-#  option broadcast-address 10.5.5.31;
-#  default-lease-time 600;
-#  max-lease-time 7200;
-#}
+subnet 192.168.101.0 netmask 255.255.255.0 {
+  range 192.168.101.100 192.168.101.200;
+  option domain-name-servers 10.0.35.1; 
+  option domain-name "unix.nt";
+  option routers 192.168.101.254;
+  option broadcast-address 192.168.101.255;
+  default-lease-time 600;
+  max-lease-time 7200;
+}
 
 # Hosts which require special configuration options can be listed in
 # host statements.   If no address is specified, the address will be
13:47:22
#vi dhcpd.conf
13:47:33
#dhcpd start
bash: dhcpd: command not found
13:47:42
#cd /etc/init.d

13:48:07
#./dhcp3-server start
Starting DHCP server: dhcpd3.
13:48:14
#ls /var/
backups/ lib/     lock/    mail/    run/     tmp/
cache/   local/   log/     opt/     spool/
13:48:14
#ls /var/lib/
apt/                 gconf/               tex-common/
aptitude/            hal/                 ucf/
aspell/              initramfs-tools/     urandom/
dbus/                initscripts/         usbutils/
defoma/              libuuid/             vim/
dhcp3/               logrotate/           x11/
dictionaries-common/ misc/                xkb/
dpkg/                mlocate/
exim4/               nfs/
13:48:14
#ls /var/lib/dhcp3/
dhclient.leases  dhcpd.leases  dhcpd.leases~
13:54:05
#cat /var/lib/dhcp3/dhcpd.leases
# The format of this file is documented in the dhcpd.leases(5) manual page.
# This lease file was written by isc-dhcp-V3.1.1
lease 192.168.101.100 {
  starts 1 2009/12/07 12:48:31;
  ends 1 2009/12/07 12:58:31;
  cltt 1 2009/12/07 12:48:31;
  binding state active;
  next binding state free;
  hardware ethernet 00:0e:a6:20:4c:29;
  uid "\001\000\016\246 L)";
...
lease 192.168.101.100 {
  starts 1 2009/12/07 12:53:30;
  ends 1 2009/12/07 13:03:30;
  cltt 1 2009/12/07 12:53:30;
  binding state active;
  next binding state free;
  hardware ethernet 00:0e:a6:20:4c:29;
  uid "\001\000\016\246 L)";
  client-hostname "pc01";
}
13:54:22
#apt-get install ssh
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  openssh-blacklist openssh-blacklist-extra openssh-server
Suggested packages:
  ssh-askpass rssh molly-guard
The following NEW packages will be installed:
  openssh-blacklist openssh-blacklist-extra openssh-server ssh
0 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
...
Selecting previously deselected package ssh.
Unpacking ssh (from .../ssh_1%3a5.1p1-5_all.deb) ...
Processing triggers for man-db ...
Setting up openssh-blacklist (0.4.1) ...
Setting up openssh-blacklist-extra (0.4.1) ...
Setting up openssh-server (1:5.1p1-5) ...
Creating SSH2 RSA key; this may take some time ...
Creating SSH2 DSA key; this may take some time ...
Restarting OpenBSD Secure Shell server: sshd.
Setting up ssh (1:5.1p1-5) ...
14:04:05
#ssh
usage: ssh [-1246AaCfgKkMNnqsTtVvXxY] [-b bind_address] [-c cipher_spec]
           [-D [bind_address:]port] [-e escape_char] [-F configfile]
           [-i identity_file] [-L [bind_address:]port:host:hostport]
           [-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p port]
           [-R [bind_address:]port:host:hostport] [-S ctl_path]
           [-w local_tun[:remote_tun]] [user@]hostname [command]
14:04:07
#apt-get install asterisk asterisk-sounds-extra
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  asterisk-config asterisk-sounds-main ca-certificates debhelper gettext
  html2text intltool-debian libc-client2007b libcompress-raw-zlib-perl
  libcompress-zlib-perl libcurl3 libdigest-hmac-perl libdigest-sha1-perl
  libfile-remove-perl libgsm1 libiksemel3 libio-compress-base-perl
  libio-compress-zlib-perl libio-stringy-perl libltdl3 libmail-box-perl
  libmail-sendmail-perl libmailtools-perl libmime-types-perl
...
Setting up libio-stringy-perl (2.110-4) ...
Setting up libmime-types-perl (1.24-1) ...
Setting up libmailtools-perl (2.03-1) ...
Setting up libobject-realize-later-perl (0.18-1) ...
Setting up libuser-identity-perl (0.92-2) ...
Setting up libmail-box-perl (2.082-2) ...
Setting up libsys-hostname-long-perl (1.4-2) ...
Setting up libmail-sendmail-perl (0.79-5) ...
Setting up module-assistant (0.10.11.0) ...
Setting up vpb-driver-source (4.2.38-1) ...
14:06:38
#apt-get install asterisk-sounds-extra-main
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Couldn't find package asterisk-sounds-extra-main
14:06:50
#apt-get install asterisk-sounds-main
Reading package lists... Done
Building dependency tree
Reading state information... Done
asterisk-sounds-main is already the newest version.
asterisk-sounds-main set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
14:07:15
#cd /etc/

14:07:34
#ls
a2ps.cfg                gamin             magic            rc0.d
a2ps-site.cfg           gconf             magic.mime       rc1.d
acpi                    gre.d             mailcap          rc2.d
adduser.conf            groff             mailcap.order    rc3.d
adjtime                 group             mailname         rc4.d
aliases                 group-            mail.rc          rc5.d
alternatives            gshadow           manpath.config   rc6.d
apt                     gshadow-          menu-methods     rc.local
asterisk                gssapi_mech.conf  mime.types       rcS.d
at.deny                 gtk-2.0           mke2fs.conf      reportbug.conf
...
dhcp3                   libpaper.d        passwd-          ucf.conf
dictionaries-common     lilalo            perl             udev
dpkg                    locale.alias      pm               updatedb.conf
emacs                   locale.gen        ppp              uswsusp.conf
email-addresses         localtime         printcap         vim
environment             logcheck          profile          w3m
exim4                   login.defs        protocols        wgetrc
fonts                   logrotate.conf    python           X11
fstab                   logrotate.d       python2.5        xdg
gai.conf                lsb-base          radiusclient-ng
14:07:36
#cd asterisk/

14:07:40
#ls -l
total 428
-rw-r----- 1 asterisk asterisk   140 2009-01-04 09:26 adsi.conf
-rw-r----- 1 asterisk asterisk   840 2009-01-04 09:26 adtranvofr.conf
-rw-r----- 1 asterisk asterisk  2724 2009-01-04 09:26 agents.conf
-rw-r----- 1 asterisk asterisk  2227 2009-01-04 09:26 alarmreceiver.conf
-rw-r----- 1 asterisk asterisk  2675 2009-01-04 09:26 alsa.conf
-rw-r----- 1 asterisk asterisk   767 2009-01-04 09:26 amd.conf
-rw-r----- 1 asterisk asterisk  3260 2009-01-04 09:26 asterisk.adsi
-rw-r----- 1 asterisk asterisk   247 2009-01-04 09:17 asterisk.conf
-rw-r----- 1 asterisk asterisk  7324 2009-01-04 09:26 cdr.conf
...
-rw-r----- 1 asterisk asterisk  4044 2009-01-04 09:26 skinny.conf
-rw-r----- 1 asterisk asterisk  6691 2009-01-04 09:26 sla.conf
-rw-r----- 1 asterisk asterisk  2665 2009-01-04 09:26 smdi.conf
-rw-r----- 1 asterisk asterisk  1384 2009-01-04 09:26 telcordia-1.adsi
-rw-r----- 1 asterisk asterisk   598 2009-01-04 09:26 udptl.conf
-rw-r----- 1 asterisk asterisk  1804 2009-01-04 09:26 users.conf
-rw-r----- 1 asterisk asterisk 11723 2009-01-04 09:26 voicemail.conf
-rw-r----- 1 asterisk asterisk  2772 2009-01-04 09:26 vpb.conf
-rw-r----- 1 asterisk asterisk   393 2009-01-04 09:26 watchdog.conf
-rw-r----- 1 asterisk asterisk 24193 2009-01-04 09:26 zapata.conf
14:07:42
#ld /etc/rc2.d
ld: /etc/rc2.d: No such file: File format not recognized
14:11:51
#ls /etc/rc2.d
README      S12acpid  S16ssh    S20lpd         S20openbsd-inetd  S24hal           S89atd   S99rc.local   S99stop-bootlogd
S10rsyslog  S12dbus   S20exim4  S20nfs-common  S21asterisk       S40dhcp3-server  S89cron  S99rmnologin
14:11:54
#ls -l /etc/rc2.d
total 4
-rw-r--r-- 1 root root 556 2008-08-12 04:09 README
lrwxrwxrwx 1 root root  17 2009-12-07 00:50 S10rsyslog -> ../init.d/rsyslog
lrwxrwxrwx 1 root root  15 2009-12-07 00:51 S12acpid -> ../init.d/acpid
lrwxrwxrwx 1 root root  14 2009-12-07 02:18 S12dbus -> ../init.d/dbus
lrwxrwxrwx 1 root root  13 2009-12-07 03:04 S16ssh -> ../init.d/ssh
lrwxrwxrwx 1 root root  15 2009-12-07 00:56 S20exim4 -> ../init.d/exim4
lrwxrwxrwx 1 root root  13 2009-12-07 02:21 S20lpd -> ../init.d/lpd
lrwxrwxrwx 1 root root  20 2009-12-07 00:56 S20nfs-common -> ../init.d/nfs-common
lrwxrwxrwx 1 root root  23 2009-12-07 00:56 S20openbsd-inetd -> ../init.d/openbsd-inetd
lrwxrwxrwx 1 root root  18 2009-12-07 03:06 S21asterisk -> ../init.d/asterisk
lrwxrwxrwx 1 root root  13 2009-12-07 02:18 S24hal -> ../init.d/hal
lrwxrwxrwx 1 root root  22 2009-12-07 02:43 S40dhcp3-server -> ../init.d/dhcp3-server
lrwxrwxrwx 1 root root  13 2009-12-07 00:56 S89atd -> ../init.d/atd
lrwxrwxrwx 1 root root  14 2009-12-07 00:50 S89cron -> ../init.d/cron
lrwxrwxrwx 1 root root  18 2009-12-07 00:50 S99rc.local -> ../init.d/rc.local
lrwxrwxrwx 1 root root  19 2009-12-07 00:50 S99rmnologin -> ../init.d/rmnologin
lrwxrwxrwx 1 root root  23 2009-12-07 00:50 S99stop-bootlogd -> ../init.d/stop-bootlogd
14:12:03
#who -r
         run-level 2  2009-12-07 01:41                   last=S
14:15:17
#ls -l
total 428
-rw-r----- 1 asterisk asterisk   140 2009-01-04 09:26 adsi.conf
-rw-r----- 1 asterisk asterisk   840 2009-01-04 09:26 adtranvofr.conf
-rw-r----- 1 asterisk asterisk  2724 2009-01-04 09:26 agents.conf
-rw-r----- 1 asterisk asterisk  2227 2009-01-04 09:26 alarmreceiver.conf
-rw-r----- 1 asterisk asterisk  2675 2009-01-04 09:26 alsa.conf
-rw-r----- 1 asterisk asterisk   767 2009-01-04 09:26 amd.conf
-rw-r----- 1 asterisk asterisk  3260 2009-01-04 09:26 asterisk.adsi
-rw-r----- 1 asterisk asterisk   247 2009-01-04 09:17 asterisk.conf
-rw-r----- 1 asterisk asterisk  7324 2009-01-04 09:26 cdr.conf
...
-rw-r----- 1 asterisk asterisk  4044 2009-01-04 09:26 skinny.conf
-rw-r----- 1 asterisk asterisk  6691 2009-01-04 09:26 sla.conf
-rw-r----- 1 asterisk asterisk  2665 2009-01-04 09:26 smdi.conf
-rw-r----- 1 asterisk asterisk  1384 2009-01-04 09:26 telcordia-1.adsi
-rw-r----- 1 asterisk asterisk   598 2009-01-04 09:26 udptl.conf
-rw-r----- 1 asterisk asterisk  1804 2009-01-04 09:26 users.conf
-rw-r----- 1 asterisk asterisk 11723 2009-01-04 09:26 voicemail.conf
-rw-r----- 1 asterisk asterisk  2772 2009-01-04 09:26 vpb.conf
-rw-r----- 1 asterisk asterisk   393 2009-01-04 09:26 watchdog.conf
-rw-r----- 1 asterisk asterisk 24193 2009-01-04 09:26 zapata.conf
14:15:51
#less sip
14:15:51
#less sip.conf
14:21:41
#less users.conf.conf
14:21:46
#less users.conf
прошло 26 минут
14:47:58
#mv /etc/asterisk/sip.conf{,.SAVED}

14:48:41
#mv /etc/asterisk/extensions.conf{,.SAVED}

14:48:56
#ls -l
total 428
-rw-r----- 1 asterisk asterisk   140 2009-01-04 09:26 adsi.conf
-rw-r----- 1 asterisk asterisk   840 2009-01-04 09:26 adtranvofr.conf
-rw-r----- 1 asterisk asterisk  2724 2009-01-04 09:26 agents.conf
-rw-r----- 1 asterisk asterisk  2227 2009-01-04 09:26 alarmreceiver.conf
-rw-r----- 1 asterisk asterisk  2675 2009-01-04 09:26 alsa.conf
-rw-r----- 1 asterisk asterisk   767 2009-01-04 09:26 amd.conf
-rw-r----- 1 asterisk asterisk  3260 2009-01-04 09:26 asterisk.adsi
-rw-r----- 1 asterisk asterisk   247 2009-01-04 09:17 asterisk.conf
-rw-r----- 1 asterisk asterisk  7324 2009-01-04 09:26 cdr.conf
...
-rw-r----- 1 asterisk asterisk  4044 2009-01-04 09:26 skinny.conf
-rw-r----- 1 asterisk asterisk  6691 2009-01-04 09:26 sla.conf
-rw-r----- 1 asterisk asterisk  2665 2009-01-04 09:26 smdi.conf
-rw-r----- 1 asterisk asterisk  1384 2009-01-04 09:26 telcordia-1.adsi
-rw-r----- 1 asterisk asterisk   598 2009-01-04 09:26 udptl.conf
-rw-r----- 1 asterisk asterisk  1804 2009-01-04 09:26 users.conf
-rw-r----- 1 asterisk asterisk 11723 2009-01-04 09:26 voicemail.conf
-rw-r----- 1 asterisk asterisk  2772 2009-01-04 09:26 vpb.conf
-rw-r----- 1 asterisk asterisk   393 2009-01-04 09:26 watchdog.conf
-rw-r----- 1 asterisk asterisk 24193 2009-01-04 09:26 zapata.conf
14:48:58
#vi sip.conf
--- /dev/null	2009-12-06 15:41:41.514327574 -1000
+++ sip.conf	2009-12-07 03:53:39.000000000 -1000
@@ -0,0 +1 @@
+context=default
14:53:39
#apt-get install vim
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  vim-runtime
Suggested packages:
  ctags vim-doc vim-scripts
The following NEW packages will be installed:
  vim vim-runtime
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
...
(Reading database ... 42675 files and directories currently installed.)
Unpacking vim-runtime (from .../vim-runtime_1%3a7.1.314-3+lenny2_all.deb) ...
Adding `diversion of /usr/share/vim/vim71/doc/help.txt to /usr/share/vim/vim71/doc/help.txt.vim-tiny by vim-runtime'
Adding `diversion of /usr/share/vim/vim71/doc/tags to /usr/share/vim/vim71/doc/tags.vim-tiny by vim-runtime'
Selecting previously deselected package vim.
Unpacking vim (from .../vim_1%3a7.1.314-3+lenny2_i386.deb) ...
Processing triggers for man-db ...
Setting up vim-runtime (1:7.1.314-3+lenny2) ...
Processing /usr/share/vim/addons/doc
Setting up vim (1:7.1.314-3+lenny2) ...
14:54:07
#vim sip.conf
--- /tmp/l3-saved-16164.1809.4307	2009-12-07 03:54:14.000000000 -1000
+++ sip.conf	2009-12-07 03:55:10.000000000 -1000
@@ -1 +1,6 @@
 context=default
+[101]
+type=frend
+host=dynamic
+secret=123
+
14:55:10
#cd /etc/in
inetd.conf       init.d/          initramfs-tools/ inittab          inputrc
14:55:10
#cd /etc/init.d

14:55:21
#asterisk -rv
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 debian3 (pid = 21014)
Verbosity was 0 and is now 1
debian3*CLI> mo
module  moh
debian3*CLI> mo
module  moh
debian3*CLI> module sip
No such command 'module sip' (type 'help module sip' for other possible commands)
debian3*CLI> exit
Executing last minute cleanups
14:57:30
#cd /etc/asterisk/

14:57:48
#vi sip.conf
--- /tmp/l3-saved-16164.6799.23599	2009-12-07 03:57:54.000000000 -1000
+++ sip.conf	2009-12-07 03:58:18.000000000 -1000
@@ -1,3 +1,4 @@
+[general]
 context=default
 [101]
 type=frend
14:58:18
#cd /etc/init/d
bash: cd: /etc/init/d: No such file or directory
14:58:27
#cd /etc/init.d

14:58:31
#asterisk -rv
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 debian3 (pid = 21014)
Verbosity is at least 1
debian3*CLI> exit
Executing last minute cleanups
14:58:54
#cd /etc/asterisk/

14:59:12
#vi sip.conf
--- /tmp/l3-saved-16164.8484.23677	2009-12-07 03:59:16.000000000 -1000
+++ sip.conf	2009-12-07 03:59:23.000000000 -1000
@@ -1,7 +1,7 @@
 [general]
 context=default
 [101]
-type=frend
+type=friend
 host=dynamic
 secret=123
 
14:59:23
#less sip.conf
15:00:34
#cat sip.conf
[general]
context=default
[101]
type=friend
host=dynamic
secret=123
15:00:46
#asterisk -rv
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
=========================================================================
...
  Def. Username:
  SIP Options  : (none)
  Codecs       : 0x8000e (gsm|ulaw|alaw|h263)
  Codec Order  : (none)
  Auto-Framing:  No
  Status       : Unmonitored
  Useragent    :
  Reg. Contact :
debian3*CLI> exit
Executing last minute cleanups
15:05:43
#vim sip.conf
--- /tmp/l3-saved-16164.4062.11508	2009-12-07 04:05:49.000000000 -1000
+++ sip.conf	2009-12-07 04:06:38.000000000 -1000
@@ -1,6 +1,7 @@
 [general]
 context=default
 [101]
+username=phone
 type=friend
 host=dynamic
 secret=123
15:06:38
#asterisk -rv
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 debian3 (pid = 21014)
Verbosity is at least 1
debian3*CLI> sip
debug    history  no       notify   prune    reload   set      show
debian3*CLI> sip
debug    history  no       notify   prune    reload   set      show
debian3*CLI> sip reload
 Reloading SIP
debian3*CLI>
15:07:07
#vim sip.conf
--- /tmp/l3-saved-16164.17096.12651	2009-12-07 04:07:08.000000000 -1000
+++ sip.conf	2009-12-07 04:07:33.000000000 -1000
@@ -1,8 +1,9 @@
 [general]
 context=default
+
 [101]
 username=phone
 type=friend
 host=dynamic
 secret=123
-
+callerid="gib"
15:07:33
#vim extensions.conf
--- /dev/null	2009-12-06 15:41:41.514327574 -1000
+++ extensions.conf	2009-12-07 04:09:58.000000000 -1000
@@ -0,0 +1,5 @@
+[default]
+
+exten => 101,1,Answer
+exten => 101,n,Wait(2)
+
15:10:03
#vim extensions.conf
--- /tmp/l3-saved-16164.22454.3986	2009-12-07 04:11:01.000000000 -1000
+++ extensions.conf	2009-12-07 04:14:10.000000000 -1000
@@ -1,5 +1,7 @@
 [default]
 
 exten => 101,1,Answer
-exten => 101,n,Wait(2)
+exten => 101,n,Wait(1)
+exten => 101,n,Playback(demo-congrats)
+
 
15:14:10
#vim extensions.conf
--- /tmp/l3-saved-16164.17709.14303	2009-12-07 04:14:19.000000000 -1000
+++ extensions.conf	2009-12-07 04:18:40.000000000 -1000
@@ -1,7 +1,7 @@
 [default]
 
-exten => 101,1,Answer
-exten => 101,n,Wait(1)
-exten => 101,n,Playback(demo-congrats)
-
+exten => 102,1,Answer
+exten => 102,n,Wait(1)
+exten => 102,n,Playback(demo-congrats)
+exten => 102,n,Hangup
 
15:18:40
#asterisk -rv
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 debian3 (pid = 21014)
Verbosity is at least 1
debian3*CLI> di
dialplan  dial
debian3*CLI> exit
Executing last minute cleanups
15:19:06
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk.
Starting Asterisk PBX: asterisk.
15:19:21
#asterisk -rv
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
=========================================================================
...
-= 27 extensions (67 priorities) in 21 contexts. =-
debian3*CLI> show dialplan default
[ Context 'default' created by 'pbx_config' ]
  '102' =>          1. Answer()                                   [pbx_config]
                    2. Wait(1)                                    [pbx_config]
                    3. Playback(demo-congrats)                    [pbx_config]
                    4. Hangup()                                   [pbx_config]
-= 1 extension (4 priorities) in 1 context. =-
The 'show dialplan' command is deprecated and will be removed in a future release. Please use 'dialplan show' instead.
debian3*CLI>
15:22:04
#asterisk -rx 'show dialplan default'
[ Context 'default' created by 'pbx_config' ]
  '102' =>          1. Answer()                                   [pbx_config]
                    2. Wait(1)                                    [pbx_config]
                    3. Playback(demo-congrats)                    [pbx_config]
                    4. Hangup()                                   [pbx_config]
-= 1 extension (4 priorities) in 1 context. =-
15:22:28
#cd /root/

15:31:56
#ls
Rondo
15:31:58
#cd Rondo/

15:32:08
#ls -l
total 92272
-rwxr-xr-x 1 root root 5910183 2009-12-07 04:31 rondo_veneziano_-_alba_sul_mare.mp3
-rwxr-xr-x 1 root root 3031153 2009-12-07 04:31 rondo_veneziano_-_bettina.mp3
-rwxr-xr-x 1 root root 3794251 2009-12-07 04:31 rondo_veneziano_-_casanova.mp3
-rwxr-xr-x 1 root root 6431397 2009-12-07 04:31 rondo_veneziano_-_cattedrali.mp3
-rwxr-xr-x 1 root root 3921728 2009-12-07 04:32 rondo_veneziano_-_cecilia.mp3
-rwxr-xr-x 1 root root 7317184 2009-12-07 04:32 rondo_veneziano_-_danza_mediterranea.mp3
-rwxr-xr-x 1 root root 4849604 2009-12-07 04:31 rondo_veneziano_-_desiree.mp3
-rwxr-xr-x 1 root root 5126114 2009-12-07 04:31 rondo_veneziano_-_donna_lucrezia.mp3
-rwxr-xr-x 1 root root 3541421 2009-12-07 04:31 rondo_veneziano_-_fantasia_veneziana.mp3
-rwxr-xr-x 1 root root 8809243 2009-12-07 04:31 rondo_veneziano_-_gioco_italiano.mp3
-rwxr-xr-x 1 root root 3523652 2009-12-07 04:31 rondo_veneziano_-_incontro.mp3
-rwxr-xr-x 1 root root 4494335 2009-12-07 04:31 rondo_veneziano_-_interludio.mp3
-rwxr-xr-x 1 root root 3333605 2009-12-07 04:31 rondo_veneziano_-_la_serenissima.mp3
-rwxr-xr-x 1 root root 4457764 2009-12-07 04:31 rondo_veneziano_-_lorientale.mp3
-rwxr-xr-x 1 root root 4973729 2009-12-07 04:31 rondo_veneziano_-_magica.mp3
-rwxr-xr-x 1 root root 2376632 2009-12-07 04:31 rondo_veneziano_-_nostalgia_di_venezia.mp3
-rwxr-xr-x 1 root root 5210026 2009-12-07 04:31 rondo_veneziano_-_re_sole.mp3
-rwxr-xr-x 1 root root 4373699 2009-12-07 04:31 rondo_veneziano_-_torcello.mp3
-rwxr-xr-x 1 root root 8787300 2009-12-07 04:31 rondo_veneziano_-_viaggio_italiano.mp3
15:32:09
#cp rondo_veneziano_-_la_serenissima.mp3 /usr/share/asterisk/sounds/rondo.mp3

15:33:05
#vi extensions.conf
--- /tmp/l3-saved-16164.9185.8188	2009-12-07 04:33:14.000000000 -1000
+++ extensions.conf	2009-12-07 04:33:29.000000000 -1000
@@ -2,6 +2,6 @@
 
 exten => 102,1,Answer
 exten => 102,n,Wait(1)
-exten => 102,n,Playback(demo-congrats)
+exten => 102,n,Playback(rondo)
 exten => 102,n,Hangup
 
15:33:29
#asterisk -rv
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 debian3 (pid = 21718)
Verbosity is at least 1
debian3*CLI> di
dialplan  dial
debian3*CLI> dialplan reload
Dialplan reloaded.
debian3*CLI> exit
Executing last minute cleanups
15:33:47
#apt-get install sox libsox-fmt-gsm -libsox-fmt-mp3
E: Command line option 'l' [from -libsox-fmt-mp3] is not known.
15:35:50
#apt-get install sox libsox-fmt-gsm libsox-fmt-mp3
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libid3tag0 libmad0 libsamplerate0 libsox-fmt-alsa libsox-fmt-base libsox0
Suggested packages:
  libsox-fmt-all
The following NEW packages will be installed:
  libid3tag0 libmad0 libsamplerate0 libsox-fmt-alsa libsox-fmt-base libsox-fmt-gsm libsox-fmt-mp3 libsox0 sox
0 upgraded, 9 newly installed, 0 to remove and 0 not upgraded.
...
Processing triggers for man-db ...
Setting up libid3tag0 (0.15.1b-10) ...
Setting up libmad0 (0.15.1b-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 libsox-fmt-gsm (14.0.1-2+b1) ...
Setting up libsox-fmt-mp3 (14.0.1-2+b1) ...
Setting up sox (14.0.1-2+b1) ...
15:36:11
#man sox
15:38:35
#ls
adsi.conf           cdr_manager.conf  extensions.ael         iax.conf          modules.conf      res_snmp.conf    telcordia-1.adsi
adtranvofr.conf     cdr_odbc.conf     extensions.conf        iaxprov.conf      musiconhold.conf  rpt.conf         udptl.conf
agents.conf         cdr_pgsql.conf    extensions.conf.SAVED  indications.conf  muted.conf        rtp.conf         users.conf
alarmreceiver.conf  cdr_tds.conf      features.conf          jabber.conf       osp.conf          say.conf         voicemail.conf
alsa.conf           codecs.conf       festival.conf          logger.conf       oss.conf          sip.conf         vpb.conf
amd.conf            dnsmgr.conf       followme.conf          manager.conf      phone.conf        sip.conf.SAVED   watchdog.conf
asterisk.adsi       dundi.conf        func_odbc.conf         manager.d         privacy.conf      sip_notify.conf  zapata.conf
asterisk.conf       enum.conf         gtalk.conf             meetme.conf       queues.conf       skinny.conf
cdr.conf            esel.conf         h323.conf              mgcp.conf         res_odbc.conf     sla.conf
cdr_custom.conf     extconfig.conf    http.conf              misdn.conf        res_pgsql.conf    smdi.conf
15:38:50
#cd /usr/share/asterisk/sounds/

15:39:04
#ls -l
total 10460
-rw-r--r-- 1 root root    5676 2007-12-05 08:58 1-for-am-2-for-pm.gsm
-rw-r--r-- 1 root root    4224 2007-12-05 08:58 1-yes-2-no.gsm
-rw-r--r-- 1 root root    5082 2007-12-05 08:59 abandon-all-hope.gsm
-rw-r--r-- 1 root root    1584 2007-12-05 08:59 abandons.gsm
-rw-r--r-- 1 root root    2244 2007-12-05 08:59 academic-support.gsm
-rw-r--r-- 1 root root    1980 2007-12-05 08:59 access-code.gsm
-rw-r--r-- 1 root root    3366 2007-12-05 08:59 accessible-through-system.gsm
-rw-r--r-- 1 root root    2838 2007-12-05 08:59 account-balance-is.gsm
-rw-r--r-- 1 root root    1386 2007-12-05 08:59 accounting.gsm
...
-rw-r--r-- 1 root root    2442 2007-12-05 09:00 you-must-first-dial.gsm
-rw-r--r-- 1 root root    2046 2007-12-05 09:00 your-account.gsm
-rw-r--r-- 1 root root     990 2007-12-05 09:00 your.gsm
-rw-r--r-- 1 root root    3102 2007-12-05 09:00 your-msg-has-been-saved.gsm
-rw-r--r-- 1 root root    2904 2007-12-05 09:00 your-msg-is-too-short.gsm
-rw-r--r-- 1 root root    2574 2007-12-05 09:00 your-temp-greeting.gsm
-rw-r--r-- 1 root root    2508 2007-12-05 09:00 you-seem-impatient.gsm
-rw-r--r-- 1 root root    2508 2007-12-05 09:00 you-sound-cute.gsm
-rw-r--r-- 1 root root    1782 2007-12-05 09:00 you-wish-to-join.gsm
-rw-r--r-- 1 root root    1452 2007-12-05 09:00 zip-code.gsm
15:39:08
#sox rondo.mp3 rondo.gsm

Файлы

  • /var/lib/dhcp3/dhcpd.leases
  • sip.conf
  • /var/lib/dhcp3/dhcpd.leases
    >
    # The format of this file is documented in the dhcpd.leases(5) manual page.
    # This lease file was written by isc-dhcp-V3.1.1
    lease 192.168.101.100 {
      starts 1 2009/12/07 12:48:31;
      ends 1 2009/12/07 12:58:31;
      cltt 1 2009/12/07 12:48:31;
      binding state active;
      next binding state free;
      hardware ethernet 00:0e:a6:20:4c:29;
      uid "\001\000\016\246 L)";
      client-hostname "pc01";
    }
    lease 192.168.101.101 {
      starts 1 2009/12/07 12:52:27;
      ends 1 2009/12/07 13:02:27;
      cltt 1 2009/12/07 12:52:27;
      binding state active;
      next binding state free;
      hardware ethernet 00:04:13:25:67:21;
      uid "\001\000\004\023%g!";
    }
    lease 192.168.101.100 {
      starts 1 2009/12/07 12:53:30;
      ends 1 2009/12/07 13:03:30;
      cltt 1 2009/12/07 12:53:30;
      binding state active;
      next binding state free;
      hardware ethernet 00:0e:a6:20:4c:29;
      uid "\001\000\016\246 L)";
      client-hostname "pc01";
    }
    
    sip.conf
    >
    [general]
    context=default
    [101]
    type=friend
    host=dynamic
    secret=123
    

    Статистика

    Время первой команды журнала13:16:39 2009-12- 7
    Время последней команды журнала15:39:08 2009-12- 7
    Количество командных строк в журнале100
    Процент команд с ненулевым кодом завершения, %12.00
    Процент синтаксически неверно набранных команд, % 2.00
    Суммарное время работы с терминалом *, час 2.37
    Количество командных строк в единицу времени, команда/мин 0.70
    Частота использования команд
    cd16|================| 16.00%
    ls14|==============| 14.00%
    apt-get12|============| 12.00%
    asterisk8|========| 8.00%
    vi8|========| 8.00%
    ping7|=======| 7.00%
    vim6|======| 6.00%
    less5|=====| 5.00%
    apt-cache4|====| 4.00%
    ifconfig2|==| 2.00%
    cat2|==| 2.00%
    mv2|==| 2.00%
    sox1|=| 1.00%
    ld1|=| 1.00%
    dhcpd1|=| 1.00%
    man1|=| 1.00%
    passwd1|=| 1.00%
    chown1|=| 1.00%
    ifup1|=| 1.00%
    /etc/init.d/asterisk1|=| 1.00%
    cp1|=| 1.00%
    show1|=| 1.00%
    who1|=| 1.00%
    ~1|=| 1.00%
    dhcp3-server1|=| 1.00%
    ssh1|=| 1.00%
    ____
    *) Интервалы неактивности длительностью 30 минут и более не учитываются

    Справка

    Для того чтобы использовать LiLaLo, не нужно знать ничего особенного: всё происходит само собой. Однако, чтобы ведение и последующее использование журналов было как можно более эффективным, желательно иметь в виду следующее:
    1. В журнал автоматически попадают все команды, данные в любом терминале системы.

    2. Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду w. В поле WHAT, соответствующем текущему терминалу, должна быть указана программа script.

    3. Команды, при наборе которых были допущены синтаксические ошибки, выводятся перечёркнутым текстом:
      $ l s-l
      bash: l: command not found
      

    4. Если код завершения команды равен нулю, команда была выполнена без ошибок. Команды, код завершения которых отличен от нуля, выделяются цветом.
      $ test 5 -lt 4
      Обратите внимание на то, что код завершения команды может быть отличен от нуля не только в тех случаях, когда команда была выполнена с ошибкой. Многие команды используют код завершения, например, для того чтобы показать результаты проверки

    5. Команды, ход выполнения которых был прерван пользователем, выделяются цветом.
      $ 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
      

    6. Команды, выполненные с привилегиями суперпользователя, выделяются слева красной чертой.
      # id
      uid=0(root) gid=0(root) Gruppen=0(root)
      

    7. Изменения, внесённые в текстовый файл с помощью редактора, запоминаются и показываются в журнале в формате ed. Строки, начинающиеся символом "<", удалены, а строки, начинающиеся символом ">" -- добавлены.
      $ vi ~/.bashrc
      2a3,5
      >    if [ -f /usr/local/etc/bash_completion ]; then
      >         . /usr/local/etc/bash_completion
      >        fi
      

    8. Для того чтобы изменить файл в соответствии с показанными в диффшоте изменениями, можно воспользоваться командой patch. Нужно скопировать изменения, запустить программу patch, указав в качестве её аргумента файл, к которому применяются изменения, и всавить скопированный текст:
      $ patch ~/.bashrc
      В данном случае изменения применяются к файлу ~/.bashrc

    9. Для того чтобы получить краткую справочную информацию о команде, нужно подвести к ней мышь. Во всплывающей подсказке появится краткое описание команды.

      Если справочная информация о команде есть, команда выделяется голубым фоном, например: vi. Если справочная информация отсутствует, команда выделяется розовым фоном, например: notepad.exe. Справочная информация может отсутствовать в том случае, если (1) команда введена неверно; (2) если распознавание команды LiLaLo выполнено неверно; (3) если информация о команде неизвестна LiLaLo. Последнее возможно для редких команд.

    10. Большие, в особенности многострочные, всплывающие подсказки лучше всего показываются браузерами KDE Konqueror, Apple Safari и Microsoft Internet Explorer. В браузерах Mozilla и Firefox они отображаются не полностью, а вместо перевода строки выводится специальный символ.

    11. Время ввода команды, показанное в журнале, соответствует времени начала ввода командной строки, которое равно тому моменту, когда на терминале появилось приглашение интерпретатора

    12. Имя терминала, на котором была введена команда, показано в специальном блоке. Этот блок показывается только в том случае, если терминал текущей команды отличается от терминала предыдущей.

    13. Вывод не интересующих вас в настоящий момент элементов журнала, таких как время, имя терминала и других, можно отключить. Для этого нужно воспользоваться формой управления журналом вверху страницы.

    14. Небольшие комментарии к командам можно вставлять прямо из командной строки. Комментарий вводится прямо в командную строку, после символов #^ или #v. Символы ^ и v показывают направление выбора команды, к которой относится комментарий: ^ - к предыдущей, v - к следующей. Например, если в командной строке было введено:

      $ whoami
      
      user
      
      $ #^ Интересно, кто я?
      
      в журнале это будет выглядеть так:
      $ whoami
      
      user
      
      Интересно, кто я?

    15. Если комментарий содержит несколько строк, его можно вставить в журнал следующим образом:

      $ whoami
      
      user
      
      $ cat > /dev/null #^ Интересно, кто я?
      
      Программа whoami выводит имя пользователя, под которым 
      мы зарегистрировались в системе.
      -
      Она не может ответить на вопрос о нашем назначении 
      в этом мире.
      
      В журнале это будет выглядеть так:
      $ whoami
      user
      
      Интересно, кто я?
      Программа whoami выводит имя пользователя, под которым
      мы зарегистрировались в системе.

      Она не может ответить на вопрос о нашем назначении
      в этом мире.
      Для разделения нескольких абзацев между собой используйте символ "-", один в строке.

    16. Комментарии, не относящиеся непосредственно ни к какой из команд, добавляются точно таким же способом, только вместо симолов #^ или #v нужно использовать символы #=

    17. Содержимое файла может быть показано в журнале. Для этого его нужно вывести с помощью программы cat. Если вывод команды отметить симоволами #!, содержимое файла будет показано в журнале в специально отведённой для этого секции.
    18. Для того чтобы вставить скриншот интересующего вас окна в журнал, нужно воспользоваться командой l3shot. После того как команда вызвана, нужно с помощью мыши выбрать окно, которое должно быть в журнале.
    19. Команды в журнале расположены в хронологическом порядке. Если две команды давались одна за другой, но на разных терминалах, в журнале они будут рядом, даже если они не имеют друг к другу никакого отношения.
      1
          2
      3   
          4
      
      Группы команд, выполненных на разных терминалах, разделяются специальной линией. Под этой линией в правом углу показано имя терминала, на котором выполнялись команды. Для того чтобы посмотреть команды только одного сенса, нужно щёкнуть по этому названию.

    О программе

    LiLaLo (L3) расшифровывается как Live Lab Log.
    Программа разработана для повышения эффективности обучения Unix/Linux-системам.
    (c) Игорь Чубин, 2004-2008

    $Id$