/l3/users/mikhail-2012/nt-voip/linux2.tech.inc/root :1 :2 :3 :4 |
|
#asterisk -r
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) linux2*CLI> man No such command 'man' (type 'core show help man' for other possible commands) ... 'concise' is specified, the format is abridged and in a more easily machine parsable format. If 'verbose' is specified, the output includes more and longer fields. If 'count' is specified only the channel and call count is output. The 'concise' option is deprecated and will be removed from future versions of Asterisk. linux2*CLI> sip show peers Name/username Host Dyn Nat ACL Port Status 0 sip peers [Monitored: 0 online, 0 offline Unmonitored: 0 online, 0 offline] linux2*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) linux2*CLI> man No such command 'man' (type 'core show help man' for other possible commands) ... 'concise' is specified, the format is abridged and in a more easily machine parsable format. If 'verbose' is specified, the output includes more and longer fields. If 'count' is specified only the channel and call count is output. The 'concise' option is deprecated and will be removed from future versions of Asterisk. linux2*CLI> sip show peers Name/username Host Dyn Nat ACL Port Status 0 sip peers [Monitored: 0 online, 0 offline Unmonitored: 0 online, 0 offline] linux2*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) linux2*CLI> man No such command 'man' (type 'core show help man' for other possible commands) ... 'concise' is specified, the format is abridged and in a more easily machine parsable format. If 'verbose' is specified, the output includes more and longer fields. If 'count' is specified only the channel and call count is output. The 'concise' option is deprecated and will be removed from future versions of Asterisk. linux2*CLI> sip show peers Name/username Host Dyn Nat ACL Port Status 0 sip peers [Monitored: 0 online, 0 offline Unmonitored: 0 online, 0 offline] linux2*CLI> exit |
#asterisk -rvvv
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) ... linux2*CLI> mv /etc/asterisk/sip.conf /etc/asterisk/sip.conf.BACKUP No such command 'mv /etc/asterisk/sip.conf /etc/asterisk/sip.conf.BACKUP' (type 'core show help mv /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> expand /etc/asterisk/sip.conf | grep -v '^ *;' | grep -xv '' | wc -l No such command 'expand /etc/asterisk/sip.conf | grep -v '^ *;' | grep -xv '' | wc -l' (type 'core show help expand /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> expand /etc/asterisk/sip.conf.BACKUP | grep -v '^ *;' | grep -xv '' | head -7 > /etc/asterisk/sip.conf No such command 'expand /etc/asterisk/sip.conf.BACKUP | grep -v '^ *;' | grep -xv '' | head -7 > /etc/asterisk/sip.conf' (type 'core show help expand /etc/asterisk/sip.conf.BACKUP' for other possible commands) linux2*CLI> cat /etc/asterisk/sip.conf No such command 'cat /etc/asterisk/sip.conf' (type 'core show help cat /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> exit Executing last minute cleanups |
#asterisk -rvvv
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) ... linux2*CLI> mv /etc/asterisk/sip.conf /etc/asterisk/sip.conf.BACKUP No such command 'mv /etc/asterisk/sip.conf /etc/asterisk/sip.conf.BACKUP' (type 'core show help mv /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> expand /etc/asterisk/sip.conf | grep -v '^ *;' | grep -xv '' | wc -l No such command 'expand /etc/asterisk/sip.conf | grep -v '^ *;' | grep -xv '' | wc -l' (type 'core show help expand /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> expand /etc/asterisk/sip.conf.BACKUP | grep -v '^ *;' | grep -xv '' | head -7 > /etc/asterisk/sip.conf No such command 'expand /etc/asterisk/sip.conf.BACKUP | grep -v '^ *;' | grep -xv '' | head -7 > /etc/asterisk/sip.conf' (type 'core show help expand /etc/asterisk/sip.conf.BACKUP' for other possible commands) linux2*CLI> cat /etc/asterisk/sip.conf No such command 'cat /etc/asterisk/sip.conf' (type 'core show help cat /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> exit Executing last minute cleanups |
#asterisk -rvvv
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) ... linux2*CLI> mv /etc/asterisk/sip.conf /etc/asterisk/sip.conf.BACKUP No such command 'mv /etc/asterisk/sip.conf /etc/asterisk/sip.conf.BACKUP' (type 'core show help mv /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> expand /etc/asterisk/sip.conf | grep -v '^ *;' | grep -xv '' | wc -l No such command 'expand /etc/asterisk/sip.conf | grep -v '^ *;' | grep -xv '' | wc -l' (type 'core show help expand /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> expand /etc/asterisk/sip.conf.BACKUP | grep -v '^ *;' | grep -xv '' | head -7 > /etc/asterisk/sip.conf No such command 'expand /etc/asterisk/sip.conf.BACKUP | grep -v '^ *;' | grep -xv '' | head -7 > /etc/asterisk/sip.conf' (type 'core show help expand /etc/asterisk/sip.conf.BACKUP' for other possible commands) linux2*CLI> cat /etc/asterisk/sip.conf No such command 'cat /etc/asterisk/sip.conf' (type 'core show help cat /etc/asterisk/sip.conf' for other possible commands) linux2*CLI> exit Executing last minute cleanups |
#cat /etc/asterisk/sip.conf
[general] context=default ; Default context for incoming calls allowoverlap=no ; Disable overlap dialing support. (Default is yes) udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds to all) tcpenable=no ; Enable server for incoming TCP connections (default is no) tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to all interfaces) srvlookup=yes ; Enable DNS SRV lookups on outbound calls |
#cat /etc/asterisk/sip.conf
[general] context=default ; Default context for incoming calls allowoverlap=no ; Disable overlap dialing support. (Default is yes) udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds to all) tcpenable=no ; Enable server for incoming TCP connections (default is no) tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to all interfaces) srvlookup=yes ; Enable DNS SRV lookups on outbound calls |
#cat /etc/asterisk/sip.conf
[general] context=default ; Default context for incoming calls allowoverlap=no ; Disable overlap dialing support. (Default is yes) udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds to all) tcpenable=no ; Enable server for incoming TCP connections (default is no) tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to all interfaces) srvlookup=yes ; Enable DNS SRV lookups on outbound calls |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) Verbosity is at least 3 linux2*CLI> sip show peers ... Name/username Host Dyn Nat ACL Port Status 1201 (Unspecified) N 5060 Unmonitored 1 sip peers [Monitored: 0 online, 0 offline Unmonitored: 1 online, 0 offline] linux2*CLI> sip reload Reloading SIP linux2*CLI> sip show peers Name/username Host Dyn Nat ACL Port Status 1201 (Unspecified) N 5060 Unmonitored 1 sip peers [Monitored: 0 online, 0 offline Unmonitored: 1 online, 0 offline] linux2*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) Verbosity is at least 3 linux2*CLI> sip show peers ... Name/username Host Dyn Nat ACL Port Status 1201 (Unspecified) N 5060 Unmonitored 1 sip peers [Monitored: 0 online, 0 offline Unmonitored: 1 online, 0 offline] linux2*CLI> sip reload Reloading SIP linux2*CLI> sip show peers Name/username Host Dyn Nat ACL Port Status 1201 (Unspecified) N 5060 Unmonitored 1 sip peers [Monitored: 0 online, 0 offline Unmonitored: 1 online, 0 offline] linux2*CLI> exit |
#asterisk -r
Asterisk 1.6.2.9-2+squeeze8, 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+squeeze8 currently running on linux2 (pid = 31398) Verbosity is at least 3 linux2*CLI> sip show peers ... Name/username Host Dyn Nat ACL Port Status 1201 (Unspecified) N 5060 Unmonitored 1 sip peers [Monitored: 0 online, 0 offline Unmonitored: 1 online, 0 offline] linux2*CLI> sip reload Reloading SIP linux2*CLI> sip show peers Name/username Host Dyn Nat ACL Port Status 1201 (Unspecified) N 5060 Unmonitored 1 sip peers [Monitored: 0 online, 0 offline Unmonitored: 1 online, 0 offline] linux2*CLI> exit |
#exit
exit |
#ping 192.168.15.253
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=64 time=4.84 ms 64 bytes from 192.168.15.253: icmp_req=2 ttl=64 time=0.855 ms 64 bytes from 192.168.15.253: icmp_req=3 ttl=64 time=0.861 ms 64 bytes from 192.168.15.253: icmp_req=4 ttl=64 time=0.868 ms 64 bytes from 192.168.15.253: icmp_req=5 ttl=64 time=0.856 ms 64 bytes from 192.168.15.253: icmp_req=6 ttl=64 time=1.21 ms 64 bytes from 192.168.15.253: icmp_req=7 ttl=64 time=0.879 ms 64 bytes from 192.168.15.253: icmp_req=8 ttl=64 time=0.881 ms 64 bytes from 192.168.15.253: icmp_req=9 ttl=64 time=0.878 ms ... 64 bytes from 192.168.15.253: icmp_req=14 ttl=64 time=0.867 ms 64 bytes from 192.168.15.253: icmp_req=15 ttl=64 time=0.877 ms 64 bytes from 192.168.15.253: icmp_req=16 ttl=64 time=0.862 ms 64 bytes from 192.168.15.253: icmp_req=17 ttl=64 time=0.876 ms 64 bytes from 192.168.15.253: icmp_req=18 ttl=64 time=0.869 ms 64 bytes from 192.168.15.253: icmp_req=19 ttl=64 time=0.866 ms 64 bytes from 192.168.15.253: icmp_req=20 ttl=64 time=0.878 ms ^X64 bytes from 192.168.15.253: icmp_req=21 ttl=64 time=0.853 ms ^Z [1]+ Stopped ping 192.168.15.253 |
#ifonfig
bash: ifonfig: команда не найдена |
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.15.2 Bcast:192.168.15.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:659723 errors:0 dropped:95 overruns:0 frame:0 TX packets:193544 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:620861860 (592.1 MiB) TX bytes:13900043 (13.2 MiB) Interrupt:20 Memory:fe400000-fe420000 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:12 errors:0 dropped:0 overruns:0 frame:0 TX packets:12 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:800 (800.0 B) TX bytes:800 (800.0 B) |
#grep -r 192.168.15.2
^C |
#grep -r 192.168.15.2 /etc
/etc/apt/sources.list:deb http://192.168.15.254:9999/debian/ squeeze main /etc/apt/sources.list:deb http://192.168.15.254:9999/debian/ squeeze-updates main contrib non-free /etc/resolv.conf:nameserver 192.168.15.254 /etc/network/interfaces: address 192.168.15.2 /etc/network/interfaces: broadcast 192.168.15.255 /etc/network/interfaces: gateway 192.168.15.254 /etc/network/interfaces: dns-nameservers 192.168.15.254 |
#grep -l 192.168.15.2 /etc
|
#grep -r -l 192.168.15.2 /etc
/etc/apt/sources.list /etc/resolv.conf /etc/network/interfaces |
#cat /etc/host/
cat: /etc/host/: Нет такого файла или каталога |
#cat /etc/host
cat: /etc/host: Нет такого файла или каталога |
#cat /etc/host
host.conf hostname hosts hosts.allow hosts.deny |
#cat /etc/hosts
127.0.0.1 localhost 127.0.1.1 linux2.tech.inc linux2 # The following lines are desirable for IPv6 capable hosts ::1 ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters |
#vi /etc/hosts
|
#grep -r -l 192.168.15.2 /etc
/etc/apt/sources.list /etc/resolv.conf /etc/network/interfaces |
#su -
l3-agent is already running: pid=28435; pidfile=/root/.lilalo/l3-agent.pid |
#rootpass
bash: rootpass: команда не найдена |
#nano /etc/network/interfaces
--- /tmp/l3-saved-32380.11087.29343 2012-10-22 18:40:43.000000000 +0400 +++ /etc/network/interfaces 2012-10-22 18:41:00.000000000 +0400 @@ -8,7 +8,7 @@ # The primary network interface allow-hotplug eth0 iface eth0 inet static - address 192.168.15.2 + address 192.168.20.1 netmask 255.255.255.0 network 192.168.15.0 broadcast 192.168.15.255 |
#nano /etc/network/interfaces/etc/resolv.conf
|
#127.0.0.1 localhost
bash: ifdown_eth0: команда не найдена |
#ifdown eth0
|
#ifup eth0
SIOCADDRT: No such process Failed to bring up eth0. |
#ifup eth0
SIOCADDRT: No such process Failed to bring up eth0. |
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.20.1 Bcast:192.168.15.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:690313 errors:0 dropped:95 overruns:0 frame:0 TX packets:194989 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:623327591 (594.4 MiB) TX bytes:14012526 (13.3 MiB) Interrupt:20 Memory:fe400000-fe420000 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:18 errors:0 dropped:0 overruns:0 frame:0 TX packets:18 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:1280 (1.2 KiB) TX bytes:1280 (1.2 KiB) |
#ping 192.168.10.1
connect: Network is unreachable |
#ping 192.168.15.254
connect: Network is unreachable |
#ping 192.168.30.1
connect: Network is unreachable |
#ifup eth0
SIOCADDRT: No such process Failed to bring up eth0. |
#ping 192.168.30.254
connect: Network is unreachable |
#ping 192.168.20.254
PING 192.168.20.254 (192.168.20.254) 56(84) bytes of data. From 192.168.20.1 icmp_seq=1 Destination Host Unreachable From 192.168.20.1 icmp_seq=2 Destination Host Unreachable From 192.168.20.1 icmp_seq=3 Destination Host Unreachable From 192.168.20.1 icmp_seq=4 Destination Host Unreachable From 192.168.20.1 icmp_seq=5 Destination Host Unreachable From 192.168.20.1 icmp_seq=6 Destination Host Unreachable From 192.168.20.1 icmp_seq=7 Destination Host Unreachable From 192.168.20.1 icmp_seq=8 Destination Host Unreachable From 192.168.20.1 icmp_seq=9 Destination Host Unreachable ^C --- 192.168.20.254 ping statistics --- 11 packets transmitted, 0 received, +9 errors, 100% packet loss, time 10055ms pipe 3 |
#ping 192.168.30.1
connect: Network is unreachable |
#ifup eth0
SIOCADDRT: No such process Failed to bring up eth0. |
#ifup eth0
SIOCADDRT: No such process Failed to bring up eth0. |
#ifdown eth0
ifdown: interface eth0 not configured |
#ifup eth0
SIOCADDRT: No such process Failed to bring up eth0. |
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.20.1 Bcast:192.168.15.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:693441 errors:0 dropped:95 overruns:0 frame:0 TX packets:195014 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:623561246 (594.6 MiB) TX bytes:14016581 (13.3 MiB) Interrupt:20 Memory:fe400000-fe420000 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:29 errors:0 dropped:0 overruns:0 frame:0 TX packets:29 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:2512 (2.4 KiB) TX bytes:2512 (2.4 KiB) |
#nano /etc/network/interfaces/etc/resolv.conf
|
#This file describes the network interfaces available on your system
|
#ping 192.168.30.1
PING 192.168.30.1 (192.168.30.1) 56(84) bytes of data. From 192.168.20.1 icmp_seq=3 Destination Host Unreachable ^C --- 192.168.30.1 ping statistics --- 4 packets transmitted, 0 received, +1 errors, 100% packet loss, time 3013ms |
#ping 192.168.30.1
PING 192.168.30.1 (192.168.30.1) 56(84) bytes of data. ^X^Z [5]+ Stopped ping 192.168.30.1 |
#route -n
Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 192.168.20.254 0.0.0.0 UG 0 0 0 eth0 192.168.20.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 |
#ping 192.168.30.1
PING 192.168.30.1 (192.168.30.1) 56(84) bytes of data. From 192.168.20.1 icmp_seq=1 Destination Host Unreachable From 192.168.20.1 icmp_seq=2 Destination Host Unreachable From 192.168.20.1 icmp_seq=5 Destination Host Unreachable From 192.168.20.1 icmp_seq=7 Destination Host Unreachable From 192.168.20.1 icmp_seq=8 Destination Host Unreachable From 192.168.20.1 icmp_seq=10 Destination Host Unreachable From 192.168.20.1 icmp_seq=11 Destination Host Unreachable From 192.168.20.1 icmp_seq=12 Destination Host Unreachable From 192.168.20.1 icmp_seq=13 Destination Host Unreachable ... From 192.168.20.1 icmp_seq=75 Destination Host Unreachable From 192.168.20.1 icmp_seq=76 Destination Host Unreachable From 192.168.20.1 icmp_seq=77 Destination Host Unreachable From 192.168.20.1 icmp_seq=79 Destination Host Unreachable From 192.168.20.1 icmp_seq=80 Destination Host Unreachable From 192.168.20.1 icmp_seq=81 Destination Host Unreachable From 192.168.20.1 icmp_seq=82 Destination Host Unreachable From 192.168.20.1 icmp_seq=83 Destination Host Unreachable ^Z [6]+ Stopped ping 192.168.30.1 |
#ping 192.168.10.1
PING 192.168.10.1 (192.168.10.1) 56(84) bytes of data. From 192.168.20.1 icmp_seq=1 Destination Host Unreachable From 192.168.20.1 icmp_seq=2 Destination Host Unreachable From 192.168.20.1 icmp_seq=3 Destination Host Unreachable From 192.168.20.1 icmp_seq=5 Destination Host Unreachable From 192.168.20.1 icmp_seq=6 Destination Host Unreachable From 192.168.20.1 icmp_seq=7 Destination Host Unreachable From 192.168.20.1 icmp_seq=8 Destination Host Unreachable From 192.168.20.1 icmp_seq=9 Destination Host Unreachable From 192.168.20.1 icmp_seq=10 Destination Host Unreachable ... From 192.168.20.1 icmp_seq=15 Destination Host Unreachable From 192.168.20.1 icmp_seq=16 Destination Host Unreachable From 192.168.20.1 icmp_seq=17 Destination Host Unreachable From 192.168.20.1 icmp_seq=18 Destination Host Unreachable From 192.168.20.1 icmp_seq=20 Destination Host Unreachable From 192.168.20.1 icmp_seq=21 Destination Host Unreachable ^C --- 192.168.10.1 ping statistics --- 24 packets transmitted, 0 received, +19 errors, 100% packet loss, time 23126ms pipe 3 |
#ping 192.168.30.1
PING 192.168.30.1 (192.168.30.1) 56(84) bytes of data. From 192.168.20.1 icmp_seq=1 Destination Host Unreachable From 192.168.20.1 icmp_seq=2 Destination Host Unreachable From 192.168.20.1 icmp_seq=3 Destination Host Unreachable From 192.168.20.1 icmp_seq=5 Destination Host Unreachable From 192.168.20.1 icmp_seq=6 Destination Host Unreachable From 192.168.20.1 icmp_seq=7 Destination Host Unreachable From 192.168.20.1 icmp_seq=8 Destination Host Unreachable From 192.168.20.1 icmp_seq=9 Destination Host Unreachable ^C --- 192.168.30.1 ping statistics --- 11 packets transmitted, 0 received, +8 errors, 100% packet loss, time 10056ms pipe 3 |
#nano /etc/network/interfaces
--- /tmp/l3-saved-32380.14509.27812 2012-10-22 18:54:22.000000000 +0400 +++ /etc/network/interfaces 2012-10-22 18:54:35.000000000 +0400 @@ -11,7 +11,7 @@ address 192.168.20.1 netmask 255.255.255.0 network 192.168.20.0 - broadcast 192.168.15.255 + broadcast 192.168.20.255 gateway 192.168.20.254 # dns-* options are implemented by the resolvconf package, if installed dns-nameservers 192.168.20.254 |
#ifup eth0
|
#nano /etc/network/interface/etc/apt/sources.list
|
#nano /etc/network/interfaces/etc/resolv.conf/etc/resolv.conf
|
#nameserver 192.168.20.254
|
#ifup eth0
|
#ping 192.168.30.1
PING 192.168.30.1 (192.168.30.1) 56(84) bytes of data. From 192.168.20.1 icmp_seq=1 Destination Host Unreachable From 192.168.20.1 icmp_seq=2 Destination Host Unreachable From 192.168.20.1 icmp_seq=5 Destination Host Unreachable From 192.168.20.1 icmp_seq=6 Destination Host Unreachable From 192.168.20.1 icmp_seq=7 Destination Host Unreachable From 192.168.20.1 icmp_seq=8 Destination Host Unreachable From 192.168.20.1 icmp_seq=10 Destination Host Unreachable From 192.168.20.1 icmp_seq=11 Destination Host Unreachable From 192.168.20.1 icmp_seq=14 Destination Host Unreachable ... From 192.168.20.1 icmp_seq=56 Destination Host Unreachable From 192.168.20.1 icmp_seq=59 Destination Host Unreachable From 192.168.20.1 icmp_seq=60 Destination Host Unreachable From 192.168.20.1 icmp_seq=61 Destination Host Unreachable From 192.168.20.1 icmp_seq=62 Destination Host Unreachable From 192.168.20.1 icmp_seq=65 Destination Host Unreachable ^C --- 192.168.30.1 ping statistics --- 66 packets transmitted, 0 received, +41 errors, 100% packet loss, time 65344ms pipe 3 |
#/etc/network/management stop
bash: /etc/network/management: Нет такого файла или каталога |
#/etc/init.d/network-manager stop
Stopping network connection manager: NetworkManager. |
#ifdown eth0
|
#ifup eth0
|
#ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. From 192.168.20.1 icmp_seq=1 Destination Host Unreachable From 192.168.20.1 icmp_seq=4 Destination Host Unreachable From 192.168.20.1 icmp_seq=5 Destination Host Unreachable From 192.168.20.1 icmp_seq=6 Destination Host Unreachable From 192.168.20.1 icmp_seq=7 Destination Host Unreachable From 192.168.20.1 icmp_seq=8 Destination Host Unreachable From 192.168.20.1 icmp_seq=11 Destination Host Unreachable ^C --- 8.8.8.8 ping statistics --- 11 packets transmitted, 0 received, +7 errors, 100% packet loss, time 10034ms pipe 3 |
#route -n
Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 192.168.20.254 0.0.0.0 UG 0 0 0 eth0 192.168.20.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 |
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.20.1 Bcast:192.168.20.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:717828 errors:0 dropped:95 overruns:0 frame:0 TX packets:195861 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:625386150 (596.4 MiB) TX bytes:14101814 (13.4 MiB) Interrupt:20 Memory:fe400000-fe420000 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:476 errors:0 dropped:0 overruns:0 frame:0 TX packets:476 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:45972 (44.8 KiB) TX bytes:45972 (44.8 KiB) |
#ifconfig eth0
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.20.1 Bcast:192.168.20.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:718182 errors:0 dropped:95 overruns:0 frame:0 TX packets:195877 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:625412470 (596.4 MiB) TX bytes:14103557 (13.4 MiB) Interrupt:20 Memory:fe400000-fe420000 |
#ifconfig eth0 help
help: Неизвестный хост ifconfig: `--help' gives usage information. |
#man ifconfih
|
#ssh user@192.168.15.253
ssh: connect to host 192.168.15.253 port 22: Connection refused |
#ifconfig eth0 192.168.15.2
ssh user@192.168.15.253 ssh: connect to host 192.168.15.253 port 22: No route to host |
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.20.1 Bcast:192.168.20.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:2865 errors:0 dropped:0 overruns:0 frame:0 TX packets:94 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:219373 (214.2 KiB) TX bytes:10030 (9.7 KiB) Interrupt:20 Memory:fe400000-fe420000 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:58 errors:0 dropped:0 overruns:0 frame:0 TX packets:58 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:4953 (4.8 KiB) TX bytes:4953 (4.8 KiB) |
#route -n
Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 192.168.20.254 0.0.0.0 UG 0 0 0 eth0 192.168.20.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 |
#ifconfig /?
/?: error fetching interface information: Device not found |
#ifconfig eth0
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:19:8f inet addr:192.168.20.1 Bcast:192.168.20.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:198f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:3779 errors:0 dropped:0 overruns:0 frame:0 TX packets:94 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:290712 (283.8 KiB) TX bytes:10030 (9.7 KiB) Interrupt:20 Memory:fe400000-fe420000 |
#ifconfig eth0 addr 192.168.15.2
addr: Неизвестный хост ifconfig: `--help' gives usage information. |
#ifconfig --help
Usage: ifconfig [-a] [-v] [-s] <interface> [[<AF>] <address>] [add <address>[/<prefixlen>]] [del <address>[/<prefixlen>]] [[-]broadcast [<address>]] [[-]pointopoint [<address>]] [netmask <address>] [dstaddr <address>] [tunnel <address>] [outfill <NN>] [keepalive <NN>] [hw <HW> <address>] [metric <NN>] [mtu <NN>] [[-]trailers] [[-]arp] [[-]allmulti] [multicast] [[-]promisc] ... arcnet (ARCnet) dlci (Frame Relay DLCI) frad (Frame Relay Access Device) sit (IPv6-in-IPv4) fddi (Fiber Distributed Data Interface) hippi (HIPPI) irda (IrLAP) ec (Econet) x25 (generic X.25) eui64 (Generic EUI-64) <AF>=Address family. Default: inet List of possible address families: unix (UNIX Domain) inet (DARPA Internet) inet6 (IPv6) ax25 (AMPR AX.25) netrom (AMPR NET/ROM) rose (AMPR ROSE) ipx (Novell IPX) ddp (Appletalk DDP) ec (Econet) ash (Ash) x25 (CCITT X.25) |
#ifconfig eth0 addr 192.168.15.2
addr: Неизвестный хост ifconfig: `--help' gives usage information. |
#ifconfig eth0 192.168.15.2
|
#ping 192.168.15.254
PING 192.168.15.254 (192.168.15.254) 56(84) bytes of data. 64 bytes from 192.168.15.254: icmp_req=1 ttl=64 time=0.692 ms 64 bytes from 192.168.15.254: icmp_req=2 ttl=64 time=0.259 ms 64 bytes from 192.168.15.254: icmp_req=3 ttl=64 time=0.258 ms 64 bytes from 192.168.15.254: icmp_req=4 ttl=64 time=0.215 ms 64 bytes from 192.168.15.254: icmp_req=5 ttl=64 time=0.261 ms 64 bytes from 192.168.15.254: icmp_req=6 ttl=64 time=0.259 ms 64 bytes from 192.168.15.254: icmp_req=7 ttl=64 time=0.235 ms 64 bytes from 192.168.15.254: icmp_req=8 ttl=64 time=0.237 ms 64 bytes from 192.168.15.254: icmp_req=9 ttl=64 time=0.259 ms 64 bytes from 192.168.15.254: icmp_req=10 ttl=64 time=0.477 ms 64 bytes from 192.168.15.254: icmp_req=11 ttl=64 time=0.491 ms 64 bytes from 192.168.15.254: icmp_req=12 ttl=64 time=0.490 ms 64 bytes from 192.168.15.254: icmp_req=13 ttl=64 time=0.258 ms 64 bytes from 192.168.15.254: icmp_req=14 ttl=64 time=0.226 ms 64 bytes from 192.168.15.254: icmp_req=15 ttl=64 time=0.483 ms ^C --- 192.168.15.254 ping statistics --- 15 packets transmitted, 15 received, 0% packet loss, time 14000ms rtt min/avg/max/mdev = 0.215/0.340/0.692/0.140 ms |
[general] context=default ; Default context for incoming calls allowoverlap=no ; Disable overlap dialing support. (Default is yes) udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds to all) tcpenable=no ; Enable server for incoming TCP connections (default is no) tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to all interfaces) srvlookup=yes ; Enable DNS SRV lookups on outbound calls
127.0.0.1 localhost 127.0.1.1 linux2.tech.inc linux2 # The following lines are desirable for IPv6 capable hosts ::1 ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters
Время первой команды журнала | 15:09:47 2012-10-22 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 08:47:16 2012-10-23 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 100 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 36.00 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 7.00 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 2.10 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.79 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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