/l3/users/oleg22/nt-voip/linux2.unix.nt/root :1 :2 :3 :4 :5 |
|
#apt-get install sendmail sendmail-bin sensible-mda
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: mysql-common libmysqlclient16 Use 'apt-get autoremove' to remove them. The following extra packages will be installed: libmysqlclient16 mysql-common sendmail-base sendmail-cf Suggested packages: sendmail-doc rmail logcheck resolvconf sasl2-bin ... Unpacking libmysqlclient16 (from .../libmysqlclient16_5.1.49-3_i386.deb) ... Selecting previously deselected package sensible-mda. Unpacking sensible-mda (from .../sensible-mda_8.14.3-9.4_i386.deb) ... Selecting previously deselected package sendmail. Unpacking sendmail (from .../sendmail_8.14.3-9.4_all.deb) ... Processing triggers for man-db ... Setting up mysql-common (5.1.49-3) ... Setting up libmysqlclient16 (5.1.49-3) ... Setting up sensible-mda (8.14.3-9.4) ... Setting up sendmail (8.14.3-9.4) ... |
#mc
|
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:1a:50 inet addr:192.168.20.1 Bcast:192.168.20.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:1a50/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:62105 errors:0 dropped:0 overruns:0 frame:0 TX packets:55286 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:32554256 (31.0 MiB) TX bytes:15744601 (15.0 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:15 errors:0 dropped:0 overruns:0 frame:0 TX packets:15 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:979 (979.0 B) TX bytes:979 (979.0 B) |
#aptitude
aptitude 0.6.3 Will free 4,452 kB of disk spa --- Installed Packages (1259) --- Not Installed Packages (26974) --- Obsolete and Locally Created Packages (1) --- Virtual Packages (3582) --- Tasks (727) These packages are currently installed on your computer. ▒ ▒ This group contains 1259 packages. ▒ ▒ ▒ ▒ ▒ ▒ ▒ ▒ |
#ifconfig
eth0 Link encap:Ethernet HWaddr 2c:27:d7:46:1a:50 inet addr:192.168.20.1 Bcast:192.168.20.255 Mask:255.255.255.0 inet6 addr: fe80::2e27:d7ff:fe46:1a50/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:62166 errors:0 dropped:0 overruns:0 frame:0 TX packets:55345 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:32562858 (31.0 MiB) TX bytes:15749728 (15.0 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:15 errors:0 dropped:0 overruns:0 frame:0 TX packets:15 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:979 (979.0 B) TX bytes:979 (979.0 B) |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.102.1 linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 linux2.unix.nt has address 192.168.102.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 |
#host linux2
linux2.unix.nt has address 192.168.20.1 |
#mc
|
#/etc/init.d/sendmail restart
Restarting Mail Transport Agent (MTA): sendmail. |
#netstat lnp | grep :25
|
#netstat -lnp | grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: |
#netstat -lnp | grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: |
#netstat -lnp
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 127.0.0.1:5038 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 769/portmap tcp 0 0 0.0.0.0:2000 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1798/sshd tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 0.0.0.0:54270 0.0.0.0:* LISTEN 781/rpc.statd tcp6 0 0 :::22 :::* LISTEN 1798/sshd ... unix 2 [ ACC ] STREAM LISTENING 2431 1112/gdm-simple-sla @/tmp/gdm-greeter-mpmkoyLv unix 2 [ ACC ] STREAM LISTENING 86349 3106/gedit /tmp/orbit-user/linc-c22-0-2ca3093194f7d unix 2 [ ACC ] STREAM LISTENING 5910 1957/dbus-daemon @/tmp/dbus-vIeoyzugF7 unix 2 [ ACC ] STREAM LISTENING 10615 1249/asterisk /var/run/asterisk/asterisk.ctl unix 2 [ ACC ] STREAM LISTENING 102056 6189/11 /tmp/ssh-ZNLfGW6189/agent.6189 unix 2 [ ACC ] STREAM LISTENING 83845 3106/gedit /tmp/gedit.user.398343797 unix 2 [ ACC ] STREAM LISTENING 100124 5972/sendmail: MTA: /var/run/sendmail/mta/smcontrol unix 2 [ ACC ] STREAM LISTENING 9954 1125/Xorg /tmp/.X11-unix/X0 unix 2 [ ACC ] STREAM LISTENING 9959 1149/avahi-daemon: /var/run/avahi-daemon/socket unix 2 [ ACC ] STREAM LISTENING 11126 1917/x-session-mana @/tmp/.ICE-unix/1917 |
#netstat -lnp
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 127.0.0.1:5038 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 769/portmap tcp 0 0 0.0.0.0:2000 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1798/sshd tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 0.0.0.0:54270 0.0.0.0:* LISTEN 781/rpc.statd tcp6 0 0 :::22 :::* LISTEN 1798/sshd ... unix 2 [ ACC ] STREAM LISTENING 2431 1112/gdm-simple-sla @/tmp/gdm-greeter-mpmkoyLv unix 2 [ ACC ] STREAM LISTENING 86349 3106/gedit /tmp/orbit-user/linc-c22-0-2ca3093194f7d unix 2 [ ACC ] STREAM LISTENING 5910 1957/dbus-daemon @/tmp/dbus-vIeoyzugF7 unix 2 [ ACC ] STREAM LISTENING 10615 1249/asterisk /var/run/asterisk/asterisk.ctl unix 2 [ ACC ] STREAM LISTENING 102056 6189/11 /tmp/ssh-ZNLfGW6189/agent.6189 unix 2 [ ACC ] STREAM LISTENING 83845 3106/gedit /tmp/gedit.user.398343797 unix 2 [ ACC ] STREAM LISTENING 100124 5972/sendmail: MTA: /var/run/sendmail/mta/smcontrol unix 2 [ ACC ] STREAM LISTENING 9954 1125/Xorg /tmp/.X11-unix/X0 unix 2 [ ACC ] STREAM LISTENING 9959 1149/avahi-daemon: /var/run/avahi-daemon/socket unix 2 [ ACC ] STREAM LISTENING 11126 1917/x-session-mana @/tmp/.ICE-unix/1917 |
#netstat -lnp
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 127.0.0.1:5038 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 769/portmap tcp 0 0 0.0.0.0:2000 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1798/sshd tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 0.0.0.0:54270 0.0.0.0:* LISTEN 781/rpc.statd tcp6 0 0 :::22 :::* LISTEN 1798/sshd ... unix 2 [ ACC ] STREAM LISTENING 2431 1112/gdm-simple-sla @/tmp/gdm-greeter-mpmkoyLv unix 2 [ ACC ] STREAM LISTENING 86349 3106/gedit /tmp/orbit-user/linc-c22-0-2ca3093194f7d unix 2 [ ACC ] STREAM LISTENING 5910 1957/dbus-daemon @/tmp/dbus-vIeoyzugF7 unix 2 [ ACC ] STREAM LISTENING 10615 1249/asterisk /var/run/asterisk/asterisk.ctl unix 2 [ ACC ] STREAM LISTENING 102056 6189/11 /tmp/ssh-ZNLfGW6189/agent.6189 unix 2 [ ACC ] STREAM LISTENING 83845 3106/gedit /tmp/gedit.user.398343797 unix 2 [ ACC ] STREAM LISTENING 100124 5972/sendmail: MTA: /var/run/sendmail/mta/smcontrol unix 2 [ ACC ] STREAM LISTENING 9954 1125/Xorg /tmp/.X11-unix/X0 unix 2 [ ACC ] STREAM LISTENING 9959 1149/avahi-daemon: /var/run/avahi-daemon/socket unix 2 [ ACC ] STREAM LISTENING 11126 1917/x-session-mana @/tmp/.ICE-unix/1917 |
#netstat -lnp | grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: |
#w
14:40:55 up 5:19, 7 users, load average: 0.29, 0.15, 0.12 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT user tty7 :0 09:27 5:19m 4:18 0.09s x-session-manager user pts/2 :0.0 09:37 33:50 0.44s 0.33s script -f -c bash -q /home/user/.lilalo//1994228441 root pts/1 :0.0 09:53 26:36 0.30s 0.16s script -f -c bash -q /root/.lilalo//680122539170111 root pts/6 :0.0 09:53 29:15 0.09s 0.07s script -f -c bash -q /root/.lilalo//228103021697581 root pts/9 :0.0 09:55 12:59 0.15s 0.06s script -f -c bash -q /root/.lilalo//313952695055542 root pts/12 :0.0 10:09 0.00s 0.13s 0.09s script -f -c bash -q /root/.lilalo//115116699327351 root pts/15 :0.0 14:26 14:36 0.00s 0.00s script -f -c bash -q /root/.lilalo//125512701425331 |
#mc
|
#apt-get install qpoppe
Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package qpoppe |
#apt-get install qpopper
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: mysql-common libmysqlclient16 Use 'apt-get autoremove' to remove them. The following extra packages will be installed: openbsd-inetd The following NEW packages will be installed: openbsd-inetd qpopper ... Selecting previously deselected package openbsd-inetd. (Reading database ... 115737 files and directories currently installed.) Unpacking openbsd-inetd (from .../openbsd-inetd_0.20080125-6_i386.deb) ... Selecting previously deselected package qpopper. Unpacking qpopper (from .../qpopper_4.0.9.dfsg-1.2_i386.deb) ... Processing triggers for man-db ... Setting up openbsd-inetd (0.20080125-6) ... Stopping internet superserver: inetd. Not starting internet superserver: no services enabled. Setting up qpopper (4.0.9.dfsg-1.2) ... |
#netstat -lnp
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN 6957/inetd tcp 0 0 127.0.0.1:5038 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 769/portmap tcp 0 0 0.0.0.0:2000 0.0.0.0:* LISTEN 1249/asterisk tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1798/sshd tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 0.0.0.0:54270 0.0.0.0:* LISTEN 781/rpc.statd ... unix 2 [ ACC ] STREAM LISTENING 2431 1112/gdm-simple-sla @/tmp/gdm-greeter-mpmkoyLv unix 2 [ ACC ] STREAM LISTENING 102179 6468/firefox-bin /tmp/orbit-user/linc-1944-0-2dd7bbc05451e unix 2 [ ACC ] STREAM LISTENING 86349 3106/gedit /tmp/orbit-user/linc-c22-0-2ca3093194f7d unix 2 [ ACC ] STREAM LISTENING 5910 1957/dbus-daemon @/tmp/dbus-vIeoyzugF7 unix 2 [ ACC ] STREAM LISTENING 10615 1249/asterisk /var/run/asterisk/asterisk.ctl unix 2 [ ACC ] STREAM LISTENING 83845 3106/gedit /tmp/gedit.user.398343797 unix 2 [ ACC ] STREAM LISTENING 100124 5972/sendmail: MTA: /var/run/sendmail/mta/smcontrol unix 2 [ ACC ] STREAM LISTENING 9954 1125/Xorg /tmp/.X11-unix/X0 unix 2 [ ACC ] STREAM LISTENING 9959 1149/avahi-daemon: /var/run/avahi-daemon/socket unix 2 [ ACC ] STREAM LISTENING 11126 1917/x-session-mana @/tmp/.ICE-unix/1917 |
#netstat -lnp | grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: |
#netstat -lnp | grep qp
|
#netstat -lnp | grep :110
tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN 6957/inetd |
#route
Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface default gw2.unix.nt 0.0.0.0 UG 0 0 0 eth0 192.168.20.0 * 255.255.255.0 U 0 0 0 eth0 |
#user^C
|
#^V^C
|
#/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. |
#aptitude install iptraf
The following NEW packages will be installed: iptraf 0 packages upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 165 kB of archives. After unpacking 741 kB will be used. Get:1 http://10.0.35.1/debian/ squeeze/main iptraf i386 3.0.0-7 [165 kB] Fetched 165 kB in 0s (1,374 kB/s) Selecting previously deselected package iptraf. (Reading database ... 115760 files and directories currently installed.) Unpacking iptraf (from .../iptraf_3.0.0-7_i386.deb) ... Processing triggers for man-db ... Processing triggers for menu ... Setting up iptraf (3.0.0-7) ... Processing triggers for menu ... |
#netstat -untap
Active Internet connections (servers and established) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 127.0.0.1:5038 0.0.0.0:* LISTEN 7343/asterisk tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN 6957/inetd tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 769/portmap tcp 0 0 0.0.0.0:2000 0.0.0.0:* LISTEN 7343/asterisk tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1798/sshd tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 5972/sendmail: MTA: tcp 0 0 0.0.0.0:54270 0.0.0.0:* LISTEN 781/rpc.statd ... udp 0 0 0.0.0.0:5060 0.0.0.0:* 7343/asterisk udp 0 0 0.0.0.0:4569 0.0.0.0:* 7343/asterisk udp 0 0 0.0.0.0:67 0.0.0.0:* 1661/dhcpd udp 0 0 0.0.0.0:111 0.0.0.0:* 769/portmap udp 0 0 0.0.0.0:54915 0.0.0.0:* 781/rpc.statd udp 0 0 0.0.0.0:2727 0.0.0.0:* 7343/asterisk udp 0 0 0.0.0.0:5353 0.0.0.0:* 1149/avahi-daemon: udp 0 0 0.0.0.0:47362 0.0.0.0:* 1149/avahi-daemon: udp6 0 0 :::44927 :::* 1149/avahi-daemon: udp6 0 0 :::5353 :::* 1149/avahi-daemon: |
#whowatch
bash: whowatch: command not found |
#fping
bash: fping: command not found |
#apt-get install fping
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: fping 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 31.1 kB of archives. After this operation, 123 kB of additional disk space will be used. Get:1 http://10.0.35.1/debian/ squeeze/main fping i386 2.4b2-to-ipv6-16.1 [31.1 kB] Fetched 31.1 kB in 0s (281 kB/s) Selecting previously deselected package fping. (Reading database ... 115834 files and directories currently installed.) Unpacking fping (from .../fping_2.4b2-to-ipv6-16.1_i386.deb) ... Processing triggers for man-db ... Setting up fping (2.4b2-to-ipv6-16.1) ... |
#fping -c1 -gs 192.168.20.0/24 | egrep -v "ICMP|xmt"
ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.2 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.3 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.4 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.5 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.6 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.7 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.8 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.9 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.10 ICMP Host Unreachable from 192.168.20.1 for ICMP Echo sent to 192.168.20.11 ... 254 unreachable 0 unknown addresses 0 timeouts (waiting for response) 254 ICMP Echos sent 4 ICMP Echo Replies received 250 other ICMP received 0.03 ms (min round trip time) 16.1 ms (avg round trip time) 63.2 ms (max round trip time) 10.641 sec (elapsed real time) |
#nmap -sP 192.168.20.1
Starting Nmap 5.00 ( http://nmap.org ) at 2011-10-18 15:49 FET Host linux2.unix.nt (192.168.20.1) is up. Nmap done: 1 IP address (1 host up) scanned in 0.00 seconds |
#nmap -sS 192.168.20.1
Starting Nmap 5.00 ( http://nmap.org ) at 2011-10-18 15:49 FET Interesting ports on linux2.unix.nt (192.168.20.1): Not shown: 995 closed ports PORT STATE SERVICE 22/tcp open ssh 25/tcp open smtp 110/tcp open pop3 111/tcp open rpcbind 2000/tcp open callbook Nmap done: 1 IP address (1 host up) scanned in 0.07 seconds |
#nmap -O 192.168.20.1
Starting Nmap 5.00 ( http://nmap.org ) at 2011-10-18 15:50 FET |
#nmap -O 192.168.20.1/32
Starting Nmap 5.00 ( http://nmap.org ) at 2011-10-18 15:50 FET Interesting ports on linux2.unix.nt (192.168.20.1): Not shown: 995 closed ports PORT STATE SERVICE 22/tcp open ssh 25/tcp open smtp 110/tcp open pop3 111/tcp open rpcbind 2000/tcp open callbook No exact OS matches for host (If you know what OS is running on it, see http://nmap.org/submit/ ). ... OS:0%W3=8000%W4=8000%W5=8000%W6=8000)ECN(R=Y%DF=Y%T=40%W=8018%O=M400CNNSNW6 OS:%CC=Y%Q=)T1(R=Y%DF=Y%T=40%S=O%A=S+%F=AS%RD=0%Q=)T2(R=N)T3(R=Y%DF=Y%T=40% OS:W=8000%S=O%A=S+%F=AS%O=M400CST11NW6%RD=0%Q=)T4(R=Y%DF=Y%T=40%W=0%S=A%A=Z OS:%F=R%O=%RD=0%Q=)T5(R=Y%DF=Y%T=40%W=0%S=Z%A=S+%F=AR%O=%RD=0%Q=)T6(R=Y%DF= OS:Y%T=40%W=0%S=A%A=Z%F=R%O=%RD=0%Q=)T7(R=Y%DF=Y%T=40%W=0%S=Z%A=S+%F=AR%O=% OS:RD=0%Q=)U1(R=Y%DF=N%T=40%IPL=164%UN=0%RIPL=G%RID=G%RIPCK=G%RUCK=G%RUD=G) OS:IE(R=Y%DFI=N%T=40%CD=S) Network Distance: 0 hops OS detection performed. Please report any incorrect results at http://nmap.org/submit/ . Nmap done: 1 IP address (1 host up) scanned in 11.50 seconds |
#nmap -O 192.168.20.201/32
Starting Nmap 5.00 ( http://nmap.org ) at 2011-10-18 15:51 FET Interesting ports on 192.168.20.201: Not shown: 999 closed ports PORT STATE SERVICE 80/tcp open http MAC Address: 00:19:E7:42:72:B5 (Cisco Systems) Device type: VoIP phone Running: Cisco embedded OS details: Cisco Unified IP Phone 7905G or 7960 Network Distance: 1 hop OS detection performed. Please report any incorrect results at http://nmap.org/submit/ . Nmap done: 1 IP address (1 host up) scanned in 2.25 seconds |
#nmap -O 192.168.20.200/32
Starting Nmap 5.00 ( http://nmap.org ) at 2011-10-18 15:51 FET Interesting ports on 192.168.20.200: Not shown: 993 closed ports PORT STATE SERVICE 135/tcp open msrpc 139/tcp open netbios-ssn 427/tcp open svrloc 445/tcp open microsoft-ds 1110/tcp open nfsd-status 3389/tcp open ms-term-serv 19780/tcp open unknown MAC Address: 00:24:54:D2:69:09 (Samsung Electronics Co.) Device type: general purpose Running: Microsoft Windows XP OS details: Microsoft Windows XP SP2 or SP3, or Windows Server 2003 Network Distance: 1 hop OS detection performed. Please report any incorrect results at http://nmap.org/submit/ . Nmap done: 1 IP address (1 host up) scanned in 274.24 seconds |
#ls
Desktop Documents Downloads Music Pictures Public Templates Videos |
#cd /inst
|
#ls
Asterisk_RU_OReilly_DRAFT.pdf install asterisk-sounds-ru-alaw-2010-04-28.tar.gz voip asterisk-sounds-ru-gsm-2010-04-28.tar.gz voip.txt asterisk-sounds-ru-wav-2010-04-28.tar.gz |
#tar xf 11 asterisk-sounds-ru-gsm-2010-04-28.tar.gz
tar: 11: Cannot open: No such file or directory tar: Error is not recoverable: exiting now |
#ls
Asterisk_RU_OReilly_DRAFT.pdf digits.txt ru asterisk-sounds-ru-alaw-2010-04-28.tar.gz followme.txt ru.txt asterisk-sounds-ru-gsm-2010-04-28.tar.gz install voip asterisk-sounds-ru-wav-2010-04-28.tar.gz letters.txt voip.txt convert.py pbdirectory.txt dictate.txt phonetic.txt |
#ls -l
total 32 drwxr-xr-x 2 user user 4096 Oct 18 09:41 Desktop drwxr-xr-x 2 user user 4096 Oct 17 12:18 Documents drwxr-xr-x 2 user user 4096 Oct 18 09:41 Downloads drwxr-xr-x 2 user user 4096 Oct 17 12:18 Music drwxr-xr-x 2 user user 4096 Oct 17 12:18 Pictures drwxr-xr-x 2 user user 4096 Oct 17 12:18 Public drwxr-xr-x 2 user user 4096 Oct 17 12:18 Templates drwxr-xr-x 2 user user 4096 Oct 17 12:18 Videos |
#cd /usr/share/asterisk/sounds/
|
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#setxkbmap -layout "us,ru"
No protocol specified Cannot open display ":0.0" |
#setxkbmap -option "grp:ctrl_shift_toggle,grp_led:scroll"
No protocol specified Cannot open display ":0.0" |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#setxkbmap -layout "us,ru"
No protocol specified Cannot open display ":0.0" |
#/etc/init.d/asterisk restart
Stopping Asterisk PBX: asterisk. Starting Asterisk PBX: asterisk. |
#asterisk -rvvvvv
Asterisk 1.6.2.9-2+squeeze3, 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+squeeze3 currently running on linux2 (pid = 1316) ... -- Added extension '700' priority 1 to parkedcalls (0xb705f630) -- Registered extension context 'demo' (0x9f99200) in local table 0xa231818; registrar: pbx_lua -- merging incls/swits/igpats from old(demo) to new(demo) context, registrar = pbx_config -- Including switch 'Lua/' in context 'demo' -- Time to scan old dialplan and merge leftovers back into the new: 0.000618 sec -- Time to restore hints and swap in new dialplan: 0.000000 sec -- Time to delete the old dialplan: 0.000074 sec -- Total time merge_contexts_delete: 0.000692 sec linux2*CLI> exit Executing last minute cleanups |
#apt-get install tcpdump
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: tcpdump 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 376 kB of archives. After this operation, 901 kB of additional disk space will be used. Get:1 http://10.0.35.1/debian/ squeeze/main tcpdump i386 4.1.1-1 [376 kB] Fetched 376 kB in 0s (8,860 kB/s) Selecting previously deselected package tcpdump. (Reading database ... 117097 files and directories currently installed.) Unpacking tcpdump (from .../tcpdump_4.1.1-1_i386.deb) ... Processing triggers for man-db ... Setting up tcpdump (4.1.1-1) ... |
#apt-get install netdiag
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: netdiag 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 290 kB of archives. After this operation, 1,004 kB of additional disk space will be used. Get:1 http://10.0.35.1/debian/ squeeze/main netdiag i386 1.0-13 [290 kB] Fetched 290 kB in 0s (9,567 kB/s) Preconfiguring packages ... Selecting previously deselected package netdiag. (Reading database ... 117109 files and directories currently installed.) Unpacking netdiag (from .../netdiag_1.0-13_i386.deb) ... Processing triggers for man-db ... Processing triggers for menu ... Setting up netdiag (1.0-13) ... Processing triggers for menu ... |
#trafshow
|
#apt-get install hping3
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: hping3 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 103 kB of archives. After this operation, 315 kB of additional disk space will be used. Get:1 http://10.0.35.1/debian/ squeeze/main hping3 i386 3.a2.ds2-6 [103 kB] Fetched 103 kB in 0s (7,833 kB/s) Selecting previously deselected package hping3. (Reading database ... 117143 files and directories currently installed.) Unpacking hping3 (from .../hping3_3.a2.ds2-6_i386.deb) ... Processing triggers for man-db ... Setting up hping3 (3.a2.ds2-6) ... |
#hping3 192.168.20.200
HPING 192.168.20.200 (eth0 192.168.20.200): NO FLAGS are set, 40 headers + 0 data bytes len=46 ip=192.168.20.200 ttl=128 id=1142 sport=0 flags=RA seq=0 win=0 rtt=1.0 ms len=46 ip=192.168.20.200 ttl=128 id=1143 sport=0 flags=RA seq=1 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1144 sport=0 flags=RA seq=2 win=0 rtt=1.0 ms len=46 ip=192.168.20.200 ttl=128 id=1145 sport=0 flags=RA seq=3 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1146 sport=0 flags=RA seq=4 win=0 rtt=1.0 ms len=46 ip=192.168.20.200 ttl=128 id=1147 sport=0 flags=RA seq=5 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1148 sport=0 flags=RA seq=6 win=0 rtt=1.0 ms len=46 ip=192.168.20.200 ttl=128 id=1149 sport=0 flags=RA seq=7 win=0 rtt=0.8 ms len=46 ip=192.168.20.200 ttl=128 id=1150 sport=0 flags=RA seq=8 win=0 rtt=0.9 ms ... len=46 ip=192.168.20.200 ttl=128 id=1179 sport=0 flags=RA seq=27 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1180 sport=0 flags=RA seq=28 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1181 sport=0 flags=RA seq=29 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1182 sport=0 flags=RA seq=30 win=0 rtt=0.8 ms len=46 ip=192.168.20.200 ttl=128 id=1183 sport=0 flags=RA seq=31 win=0 rtt=0.9 ms len=46 ip=192.168.20.200 ttl=128 id=1184 sport=0 flags=RA seq=32 win=0 rtt=0.9 ms ^C --- 192.168.20.200 hping statistic --- 33 packets transmitted, 33 packets received, 0% packet loss round-trip min/avg/max = 0.8/0.9/1.1 ms |
#hping3 -S -p 80 www.microsoft.com
HPING www.microsoft.com (eth0 65.55.12.249): S set, 40 headers + 0 data bytes len=46 ip=65.55.12.249 ttl=240 id=54364 sport=80 flags=SA seq=0 win=8190 rtt=186.2 ms len=46 ip=65.55.12.249 ttl=240 id=2480 sport=80 flags=SA seq=1 win=8190 rtt=186.4 ms len=46 ip=65.55.12.249 ttl=240 id=51965 sport=80 flags=SA seq=2 win=8190 rtt=186.2 ms len=46 ip=65.55.12.249 ttl=240 id=22858 sport=80 flags=SA seq=3 win=8190 rtt=186.1 ms len=46 ip=65.55.12.249 ttl=240 id=42445 sport=80 flags=SA seq=4 win=8190 rtt=186.1 ms len=46 ip=65.55.12.249 ttl=240 id=61745 sport=80 flags=SA seq=5 win=8190 rtt=186.1 ms len=46 ip=65.55.12.249 ttl=240 id=56215 sport=80 flags=SA seq=6 win=8190 rtt=186.3 ms ^C --- www.microsoft.com hping statistic --- 7 packets transmitted, 7 packets received, 0% packet loss round-trip min/avg/max = 186.1/186.2/186.4 ms |
#apt-get install iperf
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: iperf 0 upgraded, 1 newly installed, 0 to remove and 1 not upgraded. Need to get 52.5 kB of archives. After this operation, 143 kB of additional disk space will be used. Get:1 http://10.0.35.1/debian/ squeeze/main iperf i386 2.0.4-5 [52.5 kB] Fetched 52.5 kB in 0s (0 B/s) Selecting previously deselected package iperf. (Reading database ... 117174 files and directories currently installed.) Unpacking iperf (from .../iperf_2.0.4-5_i386.deb) ... Processing triggers for man-db ... Setting up iperf (2.0.4-5) ... |
#iperf
Usage: iperf [-s|-c host] [options] Try `iperf --help' for more information. |
#iperf -c 192.168.90.1
------------------------------------------------------------ Client connecting to 192.168.90.1, TCP port 5001 TCP window size: 16.0 KByte (default) ------------------------------------------------------------ [ 3] local 192.168.20.1 port 39096 connected with 192.168.90.1 port 5001 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 967 MBytes 810 Mbits/sec |
#^C
|
#apt-get install sox
Reading package lists... Done Building dependency tree Reading state information... Done sox is already the newest version. sox set to manually installed. 0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded. |
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
#ls /var/spool/asterisk/monitor/
|
Время первой команды журнала | 09:09:39 2011-10-18 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 09:23:28 2011-10-19 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 9.90 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 1.98 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 2.74 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.62 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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