/l3/users/07-09-2009/nt-ladm/debian1.net.nt/user :1 :2 :3 :4 :5 :6 :7 :8 :9 :10 :11 :12 :13 :14 :15 :16 :17 |
|
$cat /tmp/squid.conf
# NOTE: Also requires icp_port option enabled to send/receive # requests via this method. # # options: proxy-only # weight=n # ttl=n # no-query # default # round-robin # carp # multicast-responder |
$cat /tmp/squid.conf | egrep "^ *$|^#
# acl normal_service_net src 10.0.0.0/24 # acl good_service_net src 10.0.1.0/24 10.0.2.0/24 # tcp_outgoing_address 10.1.0.1 normal_service_net # tcp_outgoing_address 10.1.0.2 good_service_net # tcp_outgoing_address 10.1.0.3 # # Processing proceeds in the order specified, and stops at first fully # matching line. # # Note: The use of this directive using client dependent ACLs is ... # use 'ttl=n' to specify a IP multicast TTL to use # when sending an ICP queries to this address. # Only useful when sending to a multicast group. # Because we don't accept ICP replies from random # hosts, you must configure other group members as # peers with the 'multicast-responder' option below. # # use 'no-query' to NOT send ICP queries to this # neighbor. # |
$cat /tmp/squid.conf | egrep "^
# Example where requests from 10.0.0.0/24 will be forwarded # with source address 10.1.0.1, 10.0.2.0/24 forwarded with # source address 10.1.0.2 and the rest will be forwarded with # source address 10.1.0.3. # # acl normal_service_net src 10.0.0.0/24 # acl good_service_net src 10.0.1.0/24 10.0.2.0/24 # tcp_outgoing_address 10.1.0.1 normal_service_net # tcp_outgoing_address 10.1.0.2 good_service_net # tcp_outgoing_address 10.1.0.3 ... # Because we don't accept ICP replies from random # hosts, you must configure other group members as # peers with the 'multicast-responder' option below. # # use 'no-query' to NOT send ICP queries to this # neighbor. # # use 'default' if this is a parent cache which can # be used as a "last-resort" if a peer cannot be located # by any of the peer-selection mechanisms. |
$cat /tmp/squid.conf | egrep -v
cache_mgr scherepenin@techexpert.ua error_directory /usr/share/squid/errors/Ukrainian-utf8 hosts_file /etc/hosts coredump_dir /var/spool/squid |
$cat /tmp/squid.conf | egrep -v "^ *
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/passwd auth_param basic children 5 auth_param basic realm Welcome To TechExpert Isa Server auth_param basic credentialsttl 2 hours auth_param basic casesensitive off acl all src all acl manager proto cache_object acl localhost src 127.0.0.1/32 acl to_localhost dst 127.0.0.0/8 acl localnet src 10.0.0.0/8 # RFC1918 possible internal network ... refresh_pattern -i (/cgi-bin/|\?) 0 0% 0 refresh_pattern . 0 20% 4320 acl apache rep_header Server ^Apache broken_vary_encoding allow apache extension_methods REPORT MERGE MKACTIVITY CHECKOUT shutdown_lifetime 2 seconds cache_mgr scherepenin@techexpert.ua error_directory /usr/share/squid/errors/Ukrainian-utf8 hosts_file /etc/hosts coredump_dir /var/spool/squid |
$#
|
$alias
alias ls='ls --color=auto' |
$alias egrep-my='egrep -v "^ *$|^#"'
|
$alias
alias egrep-my='egrep -v "^ *$|^#"' alias ls='ls --color=auto' |
$egrep-my /tmp/squid.conf
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/passwd auth_param basic children 5 auth_param basic realm Welcome To TechExpert Isa Server auth_param basic credentialsttl 2 hours auth_param basic casesensitive off acl all src all acl manager proto cache_object acl localhost src 127.0.0.1/32 acl to_localhost dst 127.0.0.0/8 acl localnet src 10.0.0.0/8 # RFC1918 possible internal network ... refresh_pattern -i (/cgi-bin/|\?) 0 0% 0 refresh_pattern . 0 20% 4320 acl apache rep_header Server ^Apache broken_vary_encoding allow apache extension_methods REPORT MERGE MKACTIVITY CHECKOUT shutdown_lifetime 2 seconds cache_mgr scherepenin@techexpert.ua error_directory /usr/share/squid/errors/Ukrainian-utf8 hosts_file /etc/hosts coredump_dir /var/spool/squid |
$alias
alias egrep-my='egrep -v "^ *$|^#"' alias ls='ls --color=auto' |
$who
user ttyp0 2009-09-07 15:51 (host239.net.nt) user ttyp2 2009-09-09 11:00 (192.168.16.3) user ttyp6 2009-09-09 11:02 (192.168.16.2) user ttyp8 2009-09-09 11:03 (192.168.16.25) user ttyp3 2009-09-09 11:44 (192.168.16.25) user :0 2009-09-08 14:37 user ttyp9 2009-09-08 14:37 (:0.0) user ttypc 2009-09-09 11:44 (:ttyp5:S.0) |
$ls -l
итого 2683 drwxr-xr-x 2 user user 72 2009-09-07 15:54 123 -rwxr-xr-x 1 root root 13 2008-03-11 12:42 hello -rwxr-xr-x 1 user user 225 2009-09-09 10:29 script -rwxr-xr-x 1 user user 1568611 2009-09-08 15:22 ug-ladm.pdf -rwxr-xr-x 1 user user 1166385 2009-09-08 15:22 ug-lnet.pdf |
$ls -l | sed '/^.{1}/ d'
итого 2683 drwxr-xr-x 2 user user 72 2009-09-07 15:54 123 -rwxr-xr-x 1 root root 13 2008-03-11 12:42 hello -rwxr-xr-x 1 user user 225 2009-09-09 10:29 script -rwxr-xr-x 1 user user 1568611 2009-09-08 15:22 ug-ladm.pdf -rwxr-xr-x 1 user user 1166385 2009-09-08 15:22 ug-lnet.pdf |
$ls -l | sed '/^.
|
$ls -l | sed '/^.{1
итого 2683 drwxr-xr-x 2 user user 72 2009-09-07 15:54 123 -rwxr-xr-x 1 root root 13 2008-03-11 12:42 hello -rwxr-xr-x 1 user user 225 2009-09-09 10:29 script -rwxr-xr-x 1 user user 1568611 2009-09-08 15:22 ug-ladm.pdf -rwxr-xr-x 1 user user 1166385 2009-09-08 15:22 ug-lnet.pdf |
$ls -l | sed '/^.\{1\
|
$ls -l | sed 's/^.//'
[user@debian1:~]$ того 2683 rwxr-xr-x 2 user user 72 2009-09-07 15:54 123 rwxr-xr-x 1 root root 13 2008-03-11 12:42 hello rwxr-xr-x 1 user user 225 2009-09-09 10:29 script rwxr-xr-x 1 user user 1568611 2009-09-08 15:22 ug-ladm.pdf rwxr-xr-x 1 user user 1166385 2009-09-08 15:22 ug-lnet.pdf |
$ls -l | sed 's/^./chmod\
chmod того 2683 chmod rwxr-xr-x 2 user user 72 2009-09-07 15:54 123 chmod rwxr-xr-x 1 root root 13 2008-03-11 12:42 hello chmod rwxr-xr-x 1 user user 225 2009-09-09 10:29 script chmod rwxr-xr-x 1 user user 1568611 2009-09-08 15:22 ug-ladm.pdf chmod rwxr-xr-x 1 user user 1166385 2009-09-08 15:22 ug-lnet.pdf |
$ls -l | sed 's/^./chmod\ u=
chmod u=того 2683 chmod u=rwxr-xr-x 2 user user 72 2009-09-07 15:54 123 chmod u=rwxr-xr-x 1 root root 13 2008-03-11 12:42 hello chmod u=rwxr-xr-x 1 user user 225 2009-09-09 10:29 script chmod u=rwxr-xr-x 1 user user 1568611 2009-09-08 15:22 ug-ladm.pdf chmod u=rwxr-xr-x 1 user user 1166385 2009-09-08 15:22 ug-lnet.pdf |
$ls -l | sed '1d' |
chmod -v u=rwx,g=rx,o=rx 123 chmod -v u=rwx,g=rx,o=rx hello chmod -v u=rwx,g=rx,o=rx script chmod -v u=rwx,g=rx,o=rx ug-ladm.pdf chmod -v u=rwx,g=rx,o=rx ug-lnet.pdf |
$find . -ls
![]() chmod -v u=45418 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/2D062EC0d01 chmod -v u=45408 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/4BAC0008d01 chmod -v u=45393 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/ECEB3ADCd01 chmod -v u=45394 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/FE3CDD1Ad01 chmod -v u=45409 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/2F20A81Cd01 chmod -v u=45447 Фев 18 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/866568F1d01 chmod -v u=45399 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/CA3E8801d01 chmod -v u=45392 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/51C2AF62d01 chmod -v u=45403 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/F30BE45Bd01 chmod -v u=45404 Фев 17 2008 ./.mozilla/firefox/okyhhoxh.default/Cache/B698F4DFd01 ... chmod -v u=52980 Сен 8 19:30 ./.lilalo/9169226011486531189-1252424225.script chmod -v u=53035 Сен 9 11:42 ./.lilalo/10668146982321225773-1252485710.script chmod -v u=46550 Май 24 13:21 ./.lilalo/1653016833171326170-1243160493_1243160511_home_user_.bash__profile.diff chmod -v u=52795 Сен 8 14:37 ./.lilalo/27021238671232831523-1252409836.script chmod -v u=52460 Сен 9 09:37 ./.lilalo/25984240513059826809-1252308484.info chmod -v u=53034 Сен 9 11:43 ./.lilalo/3090292573121014765-1252485683.info chmod -v u=52468 Сен 7 16:52 ./.lilalo/2153686148271534-1252308787.info chmod -v u=52997 Сен 9 11:02 ./.lilalo/10583301712898325778-1252478763.script chmod -v u=53024 Сен 9 10:29 ./.lilalo/157672521297417380-1252480897_1252481193_home_user_script.diff chmod -v u=52999 Сен 9 10:05 ./.lilalo/102752944227415917-1252479853.script |
$ls -l | sed '1d' | sed 's/^./chmod\ u=/' | while read var1
(.\{5\}\)\(...\)\(...\)/\1,g=\2,o=\3/' | tr -d -` $var9" ; done $var2 | sed 's/\( chmod -v u=rwx,g=rx,o=rx 123 chmod -v u=rwx,g=rx,o=rx hello chmod -v u=rwx,g=rx,o=rx script chmod -v u=rwx,g=rx,o=rx ug-ladm.pdf chmod -v u=rwx,g=rx,o=rx ug-lnet.pdf |
$ls -l | sed '1d' | sed 's/^./chmod\ u=/' | while read var1
![]() |
$ls -l | sed 's/^./chmod\ u=/'
![]() |
$ls -l | sed 's/^./chmod\ u=/'
![]() |
$find . -ls | sed '1d' | sed 's/^./chmod\ u=/' | while read
![]() |
$screen
|
$screen -x 26318
|
$d
![]() bash: d: command not found ~ ~ ~ ~ ~ ~ ~ ~ [user@debian1:~]$ [user@debian1:~]$ [user@debian1:~]$ [user@debian1:~]$ exit exit [screen is terminating] [user@debian1:~]$ screen -x |
$ps waux | grep screen
user 27838 0.0 0.1 5564 1000 ttyp5 S+ 12:26 0:00 screen user 28077 0.0 0.1 5568 1020 ttypa S+ 12:29 0:00 screen -x user 28178 0.0 0.1 4620 744 ttyp1 R+ 12:30 0:00 grep screen |
$kill -9 27838
|
$kill -9 28077
[user@debian1:~]$ ps waux | grep screen user 28077 0.0 0.1 5568 1024 ttypa S+ 12:29 0:00 screen -x user 28201 0.0 0.1 4620 740 ttyp1 R+ 12:30 0:00 grep screen |
$ps waux | grep scr
![]() user 5874 0.0 0.0 4508 508 ttyp0 Ss+ Sep07 0:00 script -f -q /home/user/.lilalo//2901732167207096636-1252327917.script user 5928 0.0 0.0 4636 428 ttyp0 S+ Sep07 0:02 script -f -q /home/user/.lilalo//2901732167207096636-1252327917.script user 20313 0.0 0.1 4716 680 ttyp9 Ss+ Sep08 0:00 script -f -q /home/user/.lilalo//27021238671232831523-1252409836.script user 20361 0.0 0.0 4844 472 ttyp9 S+ Sep08 0:00 script -f -q /home/user/.lilalo//27021238671232831523-1252409836.script user 24695 0.0 0.1 4716 684 ttyp2 Ss+ 11:00 0:00 script -f -q /home/user/.lilalo//72051514275509463-1252483236.script user 24748 0.0 0.0 4844 476 ttyp2 S+ 11:00 0:00 script -f -q /home/user/.lilalo//72051514275509463-1252483236.script user 24790 0.0 0.1 4716 680 ttyp6 Ss+ 11:02 0:00 script -f -q /home/user/.lilalo//8423102781779219356-1252483324.script user 24843 0.0 0.0 4844 472 ttyp6 S+ 11:02 0:00 script -f -q /home/user/.lilalo//8423102781779219356-1252483324.script user 27747 0.0 0.1 4716 684 ttyp3 Ss+ 12:26 0:00 script -f -q /home/user/.lilalo//2609922839901329913-1252488377.script user 27800 0.3 0.0 4844 476 ttyp3 S+ 12:26 0:00 script -f -q /home/user/.lilalo//2609922839901329913-1252488377.script user 27841 2.8 0.1 4712 680 ttyp8 Ss+ 12:26 0:07 script -f -q /home/user/.lilalo//6902261132183819312-1252488384.script user 27888 0.3 0.0 4840 472 ttyp8 S+ 12:26 0:00 script -f -q /home/user/.lilalo//6902261132183819312-1252488384.script user 28288 0.0 0.1 4624 744 ttyp1 R+ 12:30 0:00 grep scr |
$ps aux | grep screen
user 28330 0.0 0.1 4620 744 ttyp7 R+ 12:30 0:00 grep screen |
$ps waux | grep screen
user 28297 0.0 0.1 4620 740 ttyp1 R+ 12:30 0:00 grep screen |
$screen -x
![]() |
$ps aux | grep screen
user 28353 0.0 0.1 4624 744 ttyp7 R+ 12:30 0:00 grep screen |
$ps aux | grep screen
user 28483 0.0 0.1 5564 1000 ttypc S+ 12:31 0:00 screen user 28484 0.0 0.0 0 0 ? Zs 12:31 0:00 [screen] <defunct> user 28597 0.0 0.1 4620 740 ttyp7 R+ 12:31 0:00 grep screen |
$find . -ls | sed '1d' | sed 's/^./chmod\ u=/' | while read
![]() |
$vim /tmp/file
![]() |
$screen
|
$kill -9 27839
|
$screen -wipe
![]() |
$screen -x
![]() |
$ps aux | grep screen
[user@debian1:~]$ ps aux | grep screen user 28483 0.0 0.1 5564 1000 ttypc S+ 12:31 0:00 screen user 28484 0.0 0.0 0 0 ? Zs 12:31 0:00 [screen] <defunct> user 28699 0.0 0.1 4620 744 ttyp7 R+ 12:32 0:00 grep screen user 28483 0.0 0.1 5564 1000 ttypc S+ 12:31 0:00 screen user 28484 0.0 0.0 0 0 ? Zs 12:31 0:00 [screen] <defunct> user 28708 0.0 0.1 4624 744 ttyp7 R+ 12:32 0:00 grep screen |
$screen -x
![]() |
$ps aux | grep screen
![]() user 28483 0.0 0.1 5564 1000 ttypc S+ 12:31 0:00 screen user 28484 0.0 0.0 0 0 ? Zs 12:31 0:00 [screen] <defunct> user 28733 0.0 0.1 4620 744 ttyp7 R+ 12:32 0:00 grep screen |
$ps aux | grep screen
user 28770 0.0 0.1 4620 744 ttyp7 R+ 12:32 0:00 grep screen |
$ps aux | grep screen
user 28798 0.0 0.1 4624 744 ttyp7 R+ 12:32 0:00 grep screen |
$ps aux | grep screen
[user@debian1:~]$ ps aux | grep screen user 28807 0.0 0.1 4624 744 ttyp7 R+ 12:32 0:00 grep screen user 28816 0.0 0.1 4620 740 ttyp7 R+ 12:32 0:00 grep screen |
$ps aux | grep screen
user 28930 0.0 0.1 5568 996 ttyp5 S+ 12:32 0:00 screen user 29032 0.0 0.1 4620 740 ttyp7 R+ 12:32 0:00 grep screen |
$screen -x
|
$screen -x
|
$vim /tmp/file
![]() --- /dev/null 2009-09-07 08:26:30.044750476 +0300 +++ /tmp/file 2009-09-09 12:34:18.000000000 +0300 @@ -0,0 +1 @@ +Sergey |
$LANG=c
perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = (unset), LC_ALL = (unset), LANG = "c" are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). |
$screen -x 29134
|
$sed -i 's/Sergey/Andrey/' /tmp/file
[user@debian1:~]$ sed -i 's/Sergey/Andrey/' sed: no input files |
$grep -r ^LINUX$ /tmp
![]() [user@debian1:~]$ cat /tmp/file Andrey /tmp/day2/file:LINUX |
$grep -rl ^LINUX$ /tmp
![]() [user@debian1:~]$ grep -rh ^LINUX$ /tmp LINUX /tmp/day2/file |
$vim
![]() |
$touch 1\ 2
|
$ls -l
[user@debian1:~]$ ls 1 2 123 hello script ug-ladm.pdf ug-lnet.pdf total 2683 -rw-r--r-- 1 user user 0 Sep 9 12:56 1 2 drwxr-xr-x 2 user user 72 Sep 7 15:54 123 -rwxr-xr-x 1 root root 13 Mar 11 2008 hello -rwxr-xr-x 1 user user 225 Sep 9 10:29 script -rwxr-xr-x 1 user user 1568611 Sep 8 15:22 ug-ladm.pdf -rwxr-xr-x 1 user user 1166385 Sep 8 15:22 ug-lnet.pdf |
$echo *\ *
1 2 |
$echo 1\ 2 | sed 's/\ /_/g'
[user@debian1:~]$ echo 1\ 2 1 2 1_2 |
$touch 3\ 4
[user@debian1:~]$ for i in *\ * > do echo $i > done 1 2 |
$for i in *\ * ; do mv -v "$i" "`echo "$i" | sed 's/ /_/g`" ;
![]() [user@debian1:~]$ for i in *\ * ; do echo "Iteration $i" ; done Iteration 1 2 Iteration 3 4 one bash: command substitution: line 1: unexpected EOF while looking for matching `'' bash: command substitution: line 2: syntax error: unexpected end of file mv: target `' is not a directory: No such file or directory bash: command substitution: line 1: unexpected EOF while looking for matching `'' bash: command substitution: line 2: syntax error: unexpected end of file mv: target `' is not a directory: No such file or directory |
$for i in *\ * ; do mv -v "$i" "`echo "$i" | sed 's/ /_/g'
`1 2' -> `1_2' `3 4' -> `3_4' |
$#
![]() |
$for i in 1 2 3 4 5 ; do echo *\ * $i ; done
[user@debian1:tmp]$ for i in 1 2 3 4 5 ; do echo var $i ; done var 1 var 2 var 3 var 4 var 5 * * 1 * * 2 * * 3 * * 4 * * 5 |
$touch 5\ 6
[user@debian1:tmp]$ echo *\ * * * |
$echo *\ *
5 6 |
$for i in 1 2 3 4 5 ; do echo 5 6 $i ; done
[user@debian1:tmp]$ for i in 1 2 3 4 5 ; do echo *\ * $i ; done 5 6 1 5 6 2 5 6 3 5 6 4 5 6 5 5 6 1 5 6 2 5 6 3 5 6 4 5 6 5 |