/l3/users/eb/2009/linux3/root :1 :2 :3 :4 :5 :6 :7 :8 :9 :10 :11 :12 :13 :14 :15 :16 :17 :18 :19 :20 :21 :22 :23 :24 :25 :26 :27 :28 :29 :30 :31 :32 :33 :34 :35 :36 :37 :38 |
|
#apt-get install acl\
> Reading package lists... Done Building dependency tree Reading state information... Done acl is already the newest version. acl set to manually installed. The following packages were automatically installed and are no longer required: update-inetd portmap Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. |
#apt-get install acl\
> Reading package lists... Done Building dependency tree Reading state information... Done acl is already the newest version. acl set to manually installed. The following packages were automatically installed and are no longer required: update-inetd portmap Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. |
#getfacl ./user_list
# file: user_list # owner: root # group: root user::rw- group::r-- other::r-- |
#getfacl ./user_list
# file: user_list # owner: root # group: root user::rw- group::r-- other::r-- |
#setafcl
bash: setafcl: command not found |
#setfacl
Usage: setfacl [-bkndRLP] { -m|-M|-x|-X ... } file ... Try `setfacl --help' for more information. |
#setfacl
Usage: setfacl [-bkndRLP] { -m|-M|-x|-X ... } file ... Try `setfacl --help' for more information. |
#setfacl --help
setfacl 2.2.47 -- set file access control lists Usage: setfacl [-bkndRLP] { -m|-M|-x|-X ... } file ... -m, --modify=acl modify the current ACL(s) of file(s) -M, --modify-file=file read ACL entries to modify from file -x, --remove=acl remove entries from the ACL(s) of file(s) -X, --remove-file=file read ACL entries to remove from file -b, --remove-all remove all extended ACL entries -k, --remove-default remove the default ACL --set=acl set the ACL of file(s), replacing the current ACL --set-file=file read ACL entries to set from file --mask do recalculate the effective rights mask -n, --no-mask don't recalculate the effective rights mask -d, --default operations apply to the default ACL -R, --recursive recurse into subdirectories -L, --logical logical walk, follow symbolic links -P, --physical physical walk, do not follow symbolic links --restore=file restore ACLs (inverse of `getfacl -R') --test test mode (ACLs are not modified) --version print version and exit --help this help text |
#setfacl --help
setfacl 2.2.47 -- set file access control lists Usage: setfacl [-bkndRLP] { -m|-M|-x|-X ... } file ... -m, --modify=acl modify the current ACL(s) of file(s) -M, --modify-file=file read ACL entries to modify from file -x, --remove=acl remove entries from the ACL(s) of file(s) -X, --remove-file=file read ACL entries to remove from file -b, --remove-all remove all extended ACL entries -k, --remove-default remove the default ACL --set=acl set the ACL of file(s), replacing the current ACL --set-file=file read ACL entries to set from file --mask do recalculate the effective rights mask -n, --no-mask don't recalculate the effective rights mask -d, --default operations apply to the default ACL -R, --recursive recurse into subdirectories -L, --logical logical walk, follow symbolic links -P, --physical physical walk, do not follow symbolic links --restore=file restore ACLs (inverse of `getfacl -R') --test test mode (ACLs are not modified) --version print version and exit --help this help text |
#setfacl -Ñm u:user2:rw ./user_list
setfacl: Option -m: Invalid argument near character 3 |
#setfacl -Ñm u:user2:rw ./user_list
setfacl: Option -m: Invalid argument near character 3 |
#setfacl -m u:user2:rw ./user_list
setfacl: Option -m: Invalid argument near character 3 |
#setfacl -m u:user2:rw ./user_list
setfacl: Option -m: Invalid argument near character 3 |
#getfacl ./user_list
# file: user_list # owner: root # group: root user::rw- group::r-- other::r-- |
#getfacl ./user_list
# file: user_list # owner: root # group: root user::rw- group::r-- other::r-- |
#setfacl -m u:user2:rw ./user_list
setfacl: Option -m: Invalid argument near character 3 |
#setfacl -m u:user2:rw ./user_list
setfacl: Option -m: Invalid argument near character 3 |
#mount
tmpfs on /lib/init/rw type tmpfs (rw,nosuid,mode=0755) proc on /proc type proc (rw,noexec,nosuid,nodev) sysfs on /sys type sysfs (rw,noexec,nosuid,nodev) procbususb on /proc/bus/usb type usbfs (rw) udev on /dev type tmpfs (rw,mode=0755) tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev) devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=620) rootfs on / type rootfs (rw) |
#mount
tmpfs on /lib/init/rw type tmpfs (rw,nosuid,mode=0755) proc on /proc type proc (rw,noexec,nosuid,nodev) sysfs on /sys type sysfs (rw,noexec,nosuid,nodev) procbususb on /proc/bus/usb type usbfs (rw) udev on /dev type tmpfs (rw,mode=0755) tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev) devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=620) rootfs on / type rootfs (rw) |
#df -h
Filesystem Size Used Avail Use% Mounted on tmpfs 1006M 0 1006M 0% /lib/init/rw udev 10M 108K 9.9M 2% /dev tmpfs 1006M 4.0K 1006M 1% /dev/shm rootfs 19G 1.4G 17G 8% / |
#df -h
Filesystem Size Used Avail Use% Mounted on tmpfs 1006M 0 1006M 0% /lib/init/rw udev 10M 108K 9.9M 2% /dev tmpfs 1006M 4.0K 1006M 1% /dev/shm rootfs 19G 1.4G 17G 8% / |
#mount -o acl.remount /
mount: wrong fs type, bad option, bad superblock on rootfs, missing codepage or helper program, or other error (for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount.<type> helper program) In some cases useful info is found in syslog - try dmesg | tail or so |
#mount -o acl.remount /
mount: wrong fs type, bad option, bad superblock on rootfs, missing codepage or helper program, or other error (for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount.<type> helper program) In some cases useful info is found in syslog - try dmesg | tail or so |
#cat /etc/nsswitch.conf
# /etc/nsswitch.conf # # Example configuration of GNU Name Service Switch functionality. # If you have the `glibc-doc-reference' and `info' packages installed, try: # `info libc "Name Service Switch"' for information about this file. passwd: compat group: compat shadow: compat hosts: files dns networks: files protocols: db files services: db files ethers: db files rpc: db files netgroup: nis |
#cat /etc/nsswitch.conf
# /etc/nsswitch.conf # # Example configuration of GNU Name Service Switch functionality. # If you have the `glibc-doc-reference' and `info' packages installed, try: # `info libc "Name Service Switch"' for information about this file. passwd: compat group: compat shadow: compat hosts: files dns networks: files protocols: db files services: db files ethers: db files rpc: db files netgroup: nis |
#пуеgetent passwd
root:x:0:0:root:/root:/bin/bash daemon:x:1:1:daemon:/usr/sbin:/bin/sh bin:x:2:2:bin:/bin:/bin/sh sys:x:3:3:sys:/dev:/bin/sh sync:x:4:65534:sync:/bin:/bin/sync games:x:5:60:games:/usr/games:/bin/sh man:x:6:12:man:/var/cache/man:/bin/sh lp:x:7:7:lp:/var/spool/lpd:/bin/sh mail:x:8:8:mail:/var/mail:/bin/sh news:x:9:9:news:/var/spool/news:/bin/sh ... gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh nobody:x:65534:65534:nobody:/nonexistent:/bin/sh libuuid:x:100:101::/var/lib/libuuid:/bin/sh sshd:x:101:65534::/var/run/sshd:/usr/sbin/nologin messagebus:x:102:104::/var/run/dbus:/bin/false polkituser:x:103:105:PolicyKit,,,:/var/run/PolicyKit:/bin/false haldaemon:x:104:106:Hardware abstraction layer,,,:/var/run/hald:/bin/false gdm:x:105:107:Gnome Display Manager:/var/lib/gdm:/bin/false user:x:1000:1000::/home/user:/bin/bash Debian-exim:x:106:108::/var/spool/exim4:/bin/false |
#пуеgetent passwd
root:x:0:0:root:/root:/bin/bash daemon:x:1:1:daemon:/usr/sbin:/bin/sh bin:x:2:2:bin:/bin:/bin/sh sys:x:3:3:sys:/dev:/bin/sh sync:x:4:65534:sync:/bin:/bin/sync games:x:5:60:games:/usr/games:/bin/sh man:x:6:12:man:/var/cache/man:/bin/sh lp:x:7:7:lp:/var/spool/lpd:/bin/sh mail:x:8:8:mail:/var/mail:/bin/sh news:x:9:9:news:/var/spool/news:/bin/sh ... gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh nobody:x:65534:65534:nobody:/nonexistent:/bin/sh libuuid:x:100:101::/var/lib/libuuid:/bin/sh sshd:x:101:65534::/var/run/sshd:/usr/sbin/nologin messagebus:x:102:104::/var/run/dbus:/bin/false polkituser:x:103:105:PolicyKit,,,:/var/run/PolicyKit:/bin/false haldaemon:x:104:106:Hardware abstraction layer,,,:/var/run/hald:/bin/false gdm:x:105:107:Gnome Display Manager:/var/lib/gdm:/bin/false user:x:1000:1000::/home/user:/bin/bash Debian-exim:x:106:108::/var/spool/exim4:/bin/false |
#ls /etc/pam.d/
atd chpasswd common-account common-password cron gdm-autologin newusers passwd sshd sudo chfn chsh common-auth common-session gdm login other polkit su xscreensaver |
#ls /etc/pam.d/
atd chpasswd common-account common-password cron gdm-autologin newusers passwd sshd sudo chfn chsh common-auth common-session gdm login other polkit su xscreensaver |
#grep ^auth /etc/pam.d/common-auth
auth [success=1 default=ignore] pam_unix.so nullok_secure auth requisite pam_deny.so auth required pam_permit.so |
#grep ^auth /etc/pam.d/common-auth
auth [success=1 default=ignore] pam_unix.so nullok_secure auth requisite pam_deny.so auth required pam_permit.so |
#cat /etc/security/
access.conf limits.conf namespace.init pam_env.conf time.conf group.conf namespace.conf opasswd sepermit.conf |
#cat /etc/security/limits.conf
# /etc/security/limits.conf # #Each line describes a limit for a user in the form: # #<domain> <type> <item> <value> # #Where: #<domain> can be: # - an user name # - a group name, with @group syntax ... #* soft core 0 #root hard core 100000 #* hard rss 10000 #@student hard nproc 20 #@faculty soft nproc 20 #@faculty hard nproc 50 #ftp hard nproc 0 #ftp - chroot /ftp #@student - maxlogins 4 # End of file |
#cat /etc/security/
access.conf limits.conf namespace.init pam_env.conf time.conf group.conf namespace.conf opasswd sepermit.conf |
#cat /etc/security/limits.conf
# /etc/security/limits.conf # #Each line describes a limit for a user in the form: # #<domain> <type> <item> <value> # #Where: #<domain> can be: # - an user name # - a group name, with @group syntax ... #* soft core 0 #root hard core 100000 #* hard rss 10000 #@student hard nproc 20 #@faculty soft nproc 20 #@faculty hard nproc 50 #ftp hard nproc 0 #ftp - chroot /ftp #@student - maxlogins 4 # End of file |
#vi /etc/security/limits.conf
|
#vi /etc/security/limits.conf
--- /tmp/l3-saved-3433.834.25308 2009-05-28 16:59:10.000000000 +0300 +++ /etc/security/limits.conf 2009-05-28 16:59:18.000000000 +0300 @@ -53,5 +53,5 @@ #ftp - chroot /ftp #@student - maxlogins 4 -user - maxlogins 3 +user - maxlogins 7 # End of file |
#vi /etc/security/limits.conf
--- /tmp/l3-saved-3433.22277.30785 2009-05-28 17:05:53.000000000 +0300 +++ /etc/security/limits.conf 2009-05-28 17:06:03.000000000 +0300 @@ -53,5 +53,5 @@ #ftp - chroot /ftp #@student - maxlogins 4 -user - maxlogins 7 +#user - maxlogins 7 # End of file |
#dig www.mail.ru
; <<>> DiG 9.6.0-P1 <<>> www.mail.ru ;; global options: +cmd ;; connection timed out; no servers could be reached |
#dig www.mail.ru
; <<>> DiG 9.6.0-P1 <<>> www.mail.ru ;; global options: +cmd ;; connection timed out; no servers could be reached |
#dig www.пщщgoogle.com
; <<>> DiG 9.6.0-P1 <<>> www.google.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 49729 ;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 7, ADDITIONAL: 7 ;; QUESTION SECTION: ;www.google.com. IN A ;; ANSWER SECTION: www.google.com. 102151 IN CNAME www.l.google.com. www.l.google.com. 160 IN A 74.125.87.99 ... b.l.google.com. 106473 IN A 74.125.45.9 c.l.google.com. 126517 IN A 64.233.161.9 d.l.google.com. 85698 IN A 74.125.77.9 e.l.google.com. 20073 IN A 209.85.137.9 f.l.google.com. 27883 IN A 72.14.235.9 g.l.google.com. 85698 IN A 74.125.95.9 ;; Query time: 1 msec ;; SERVER: 10.0.35.1#53(10.0.35.1) ;; WHEN: Fri May 29 09:49:16 2009 ;; MSG SIZE rcvd: 340 |
#dig www.пщщgoogle.com
; <<>> DiG 9.6.0-P1 <<>> www.google.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 49729 ;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 7, ADDITIONAL: 7 ;; QUESTION SECTION: ;www.google.com. IN A ;; ANSWER SECTION: www.google.com. 102151 IN CNAME www.l.google.com. www.l.google.com. 160 IN A 74.125.87.99 ... b.l.google.com. 106473 IN A 74.125.45.9 c.l.google.com. 126517 IN A 64.233.161.9 d.l.google.com. 85698 IN A 74.125.77.9 e.l.google.com. 20073 IN A 209.85.137.9 f.l.google.com. 27883 IN A 72.14.235.9 g.l.google.com. 85698 IN A 74.125.95.9 ;; Query time: 1 msec ;; SERVER: 10.0.35.1#53(10.0.35.1) ;; WHEN: Fri May 29 09:49:16 2009 ;; MSG SIZE rcvd: 340 |
#ÑÑssh -l swd crimea-board.info
Password: Linux crimea-board.info 2.6.27 #1 SMP Fri Oct 10 12:30:02 EEST 2008 i686 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Thu May 28 15:01:39 2009 from chub.in swd@crimea-board:~$ dig www.mail.ru ; <<>> DiG 9.5.0-P2 <<>> www.mail.ru ... mail.ru. 3600 IN NS ns1.mail.ru. mail.ru. 3600 IN NS ns2.mail.ru. mail.ru. 3600 IN NS ns4.mail.ru. ;; Query time: 452 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Fri May 29 09:56:30 2009 ;; MSG SIZE rcvd: 200 swd@crimea-board:~$ exit logout Connection to crimea-board.info closed. |
#ÑÑssh -l swd crimea-board.info
Password: Linux crimea-board.info 2.6.27 #1 SMP Fri Oct 10 12:30:02 EEST 2008 i686 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Thu May 28 15:01:39 2009 from chub.in swd@crimea-board:~$ dig www.mail.ru ; <<>> DiG 9.5.0-P2 <<>> www.mail.ru ... mail.ru. 3600 IN NS ns1.mail.ru. mail.ru. 3600 IN NS ns2.mail.ru. mail.ru. 3600 IN NS ns4.mail.ru. ;; Query time: 452 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Fri May 29 09:56:30 2009 ;; MSG SIZE rcvd: 200 swd@crimea-board:~$ exit logout Connection to crimea-board.info closed. |
#екÑtraceroute 194.67.57.226
traceroute to 194.67.57.226 (194.67.57.226), 30 hops max, 60 byte packets 1 192.168.15.254 (192.168.15.254) 0.908 ms 1.050 ms 1.248 ms 2 10.0.35.1 (10.0.35.1) 0.213 ms 0.183 ms 0.172 ms 3 192.168.70.1 (192.168.70.1) 7.081 ms 54.165 ms 54.155 ms 4 ip.194.150.93.65.veer.net.ua (194.150.93.65) 54.068 ms 54.053 ms 54.075 ms 5 uplink.veer.net.ua (194.150.92.2) 54.035 ms 54.003 ms 53.965 ms 6 * * * 7 * * * 8 * * * 9 * * * ... 21 * * * 22 * * * 23 * * * 24 * * * 25 * * * 26 * * * 27 * * * 28 * * * 29 * * * 30 * * * |
#екÑtraceroute 194.67.57.226
traceroute to 194.67.57.226 (194.67.57.226), 30 hops max, 60 byte packets 1 192.168.15.254 (192.168.15.254) 0.908 ms 1.050 ms 1.248 ms 2 10.0.35.1 (10.0.35.1) 0.213 ms 0.183 ms 0.172 ms 3 192.168.70.1 (192.168.70.1) 7.081 ms 54.165 ms 54.155 ms 4 ip.194.150.93.65.veer.net.ua (194.150.93.65) 54.068 ms 54.053 ms 54.075 ms 5 uplink.veer.net.ua (194.150.92.2) 54.035 ms 54.003 ms 53.965 ms 6 * * * 7 * * * 8 * * * 9 * * * ... 21 * * * 22 * * * 23 * * * 24 * * * 25 * * * 26 * * * 27 * * * 28 * * * 29 * * * 30 * * * |
#apt-get install graphviz
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: update-inetd portmap Use 'apt-get autoremove' to remove them. The following extra packages will be installed: libgd2-noxpm libgraphviz4 libltdl7 ttf-liberation Suggested packages: graphviz-doc libgd-tools ... Unpacking ttf-liberation (from .../ttf-liberation_1.04.93-1_all.deb) ... Processing triggers for man-db ... Processing triggers for menu ... Setting up libgd2-noxpm (2.0.36~rc1~dfsg-3) ... Setting up libltdl7 (2.2.6a-4) ... Setting up libgraphviz4 (2.20.2-3+b2) ... Setting up graphviz (2.20.2-3+b2) ... Setting up ttf-liberation (1.04.93-1) ... Updating fontconfig cache for /usr/share/fonts/truetype/ttf-liberation Processing triggers for menu ... |
#apt-get install graphviz
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: update-inetd portmap Use 'apt-get autoremove' to remove them. The following extra packages will be installed: libgd2-noxpm libgraphviz4 libltdl7 ttf-liberation Suggested packages: graphviz-doc libgd-tools ... Unpacking ttf-liberation (from .../ttf-liberation_1.04.93-1_all.deb) ... Processing triggers for man-db ... Processing triggers for menu ... Setting up libgd2-noxpm (2.0.36~rc1~dfsg-3) ... Setting up libltdl7 (2.2.6a-4) ... Setting up libgraphviz4 (2.20.2-3+b2) ... Setting up graphviz (2.20.2-3+b2) ... Setting up ttf-liberation (1.04.93-1) ... Updating fontconfig cache for /usr/share/fonts/truetype/ttf-liberation Processing triggers for menu ... |
#apt-get install пймgqview
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: update-inetd portmap Use 'apt-get autoremove' to remove them. Suggested packages: gimp xpaint The following NEW packages will be installed: gqview ... Get:1 http://10.0.35.1 sid/main gqview 2.0.4-5 [868kB] Fetched 868kB in 0s (3808kB/s) Selecting previously deselected package gqview. (Reading database ... 44834 files and directories currently installed.) Unpacking gqview (from .../gqview_2.0.4-5_i386.deb) ... Processing triggers for menu ... Processing triggers for desktop-file-utils ... Processing triggers for man-db ... Setting up gqview (2.0.4-5) ... Processing triggers for menu ... |
#apt-get install пймgqview
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: update-inetd portmap Use 'apt-get autoremove' to remove them. Suggested packages: gimp xpaint The following NEW packages will be installed: gqview ... Get:1 http://10.0.35.1 sid/main gqview 2.0.4-5 [868kB] Fetched 868kB in 0s (3808kB/s) Selecting previously deselected package gqview. (Reading database ... 44834 files and directories currently installed.) Unpacking gqview (from .../gqview_2.0.4-5_i386.deb) ... Processing triggers for menu ... Processing triggers for desktop-file-utils ... Processing triggers for man-db ... Setting up gqview (2.0.4-5) ... Processing triggers for menu ... |
#gqview --help
GQview 2.0.4 Usage: gqview [options] [path] valid options are: +t, --with-tools force show of tools -t, --without-tools force hide of tools -f, --fullscreen start in full screen mode -s, --slideshow start in slideshow mode -l, --list open collection window for command line -r, --remote send following commands to open window -rh,--remote-help print remote command list --debug turn on debug output -v, --version print version info -h, --help show this message |
#gqview --help
GQview 2.0.4 Usage: gqview [options] [path] valid options are: +t, --with-tools force show of tools -t, --without-tools force hide of tools -f, --fullscreen start in full screen mode -s, --slideshow start in slideshow mode -l, --list open collection window for command line -r, --remote send following commands to open window -rh,--remote-help print remote command list --debug turn on debug output -v, --version print version info -h, --help show this message |
#ls -l
total 684 -rwxr-xr-x 1 root root 384 2009-05-28 14:13 create_users -rwxr-xr-x 1 root root 159 2009-05-28 14:24 del_users -rw-r--r-- 1 root root 193372 2009-05-29 10:12 kde.dot -rw-r--r-- 1 root root 11840 2009-05-29 10:05 samba.dot -rw-r--r-- 1 root root 470854 2009-05-29 10:06 samba.png -rw-rw-r-- 1 root root 0 2009-05-28 14:40 user_list |
#ls -l
total 684 -rwxr-xr-x 1 root root 384 2009-05-28 14:13 create_users -rwxr-xr-x 1 root root 159 2009-05-28 14:24 del_users -rw-r--r-- 1 root root 193372 2009-05-29 10:12 kde.dot -rw-r--r-- 1 root root 11840 2009-05-29 10:05 samba.dot -rw-r--r-- 1 root root 470854 2009-05-29 10:06 samba.png -rw-rw-r-- 1 root root 0 2009-05-28 14:40 user_list |
#apt-get autoremove
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: update-inetd portmap The following packages will be REMOVED: portmap update-inetd 0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded. After this operation, 283kB disk space will be freed. Do you want to continue [Y/n]? y (Reading database ... 44834 files and directories currently installed.) Removing portmap ... Stopping portmap daemon.... Removing update-inetd ... Processing triggers for man-db ... |
#apt-get autoremove
Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: update-inetd portmap The following packages will be REMOVED: portmap update-inetd 0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded. After this operation, 283kB disk space will be freed. Do you want to continue [Y/n]? y (Reading database ... 44834 files and directories currently installed.) Removing portmap ... Stopping portmap daemon.... Removing update-inetd ... Processing triggers for man-db ... |
#traceroute torrents.ru
torrents.ru: Temporary failure in name resolution Cannot handle "host" cmdline arg `torrents.ru' on position 1 (argc 1) |
#traceroute torrents.ru
torrents.ru: Temporary failure in name resolution Cannot handle "host" cmdline arg `torrents.ru' on position 1 (argc 1) |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | grep bin
/bin /bin/fuser /usr/bin /usr/bin/killall /usr/bin/pstree /usr/bin/pstree.x11 |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | grep bin
/bin /bin/fuser /usr/bin /usr/bin/killall /usr/bin/pstree /usr/bin/pstree.x11 |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f do file $f
> bash: syntax error: unexpected end of file |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f do file $f
> bash: syntax error: unexpected end of file |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f\
> do > file $f > done bash: syntax error near unexpected token `done' |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f\
> do > file $f > done bash: syntax error near unexpected token `done' |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f do; file $f; done
bash: syntax error near unexpected token `done' |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f do; file $f; done
bash: syntax error near unexpected token `done' |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f \
> do > echo $f > done bash: syntax error near unexpected token `done' |
#dpkg -S `which pstree` | awk 'BEGIN {FS=":"}{print $1}' | xargs dpkg -L | while read f \
> do > echo $f > done bash: syntax error near unexpected token `done' |
#apt-get install debsums
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: debsums 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 48.2kB of archives. After this operation, 270kB of additional disk space will be used. Get:1 http://10.0.35.1 sid/main debsums 2.0.44 [48.2kB] Fetched 48.2kB in 0s (2272kB/s) Preconfiguring packages ... Selecting previously deselected package debsums. (Reading database ... 44813 files and directories currently installed.) Unpacking debsums (from .../debsums_2.0.44_all.deb) ... Processing triggers for man-db ... Setting up debsums (2.0.44) ... |
#apt-get install debsums
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: debsums 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 48.2kB of archives. After this operation, 270kB of additional disk space will be used. Get:1 http://10.0.35.1 sid/main debsums 2.0.44 [48.2kB] Fetched 48.2kB in 0s (2272kB/s) Preconfiguring packages ... Selecting previously deselected package debsums. (Reading database ... 44813 files and directories currently installed.) Unpacking debsums (from .../debsums_2.0.44_all.deb) ... Processing triggers for man-db ... Setting up debsums (2.0.44) ... |
#debsums
/usr/share/locale/sl/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/sl/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/nn/LC_MESSAGES/apt.mo OK /usr/share/locale/nn/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/nn/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/mr/LC_MESSAGES/apt.mo OK /usr/share/locale/mr/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/mr/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/apt.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/libapt-pkg4.7.mo OK ... /usr/bin/apt-sortpkgs OK /usr/bin/apt-ftparchive OK /usr/bin/apt-extracttemplates OK /usr/share/locale/pt_BR/LC_MESSAGES/aptitude.mo OK /usr/share/locale/ja/LC_MESSAGES/aptitude.mo OK /usr/share/locale/pl/LC_MESSAGES/aptitude.mo OK /usr/share/locale/sk/LC_MESSAGES/aptitude.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/aptitude.mo OK /usr/share/locale/it/LC_MESSAGES/aptitude.mo OK /usr/share/locale/lt/LC_MESSAGES/aptitude.mo OK |
#debsums
/usr/share/locale/sl/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/sl/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/nn/LC_MESSAGES/apt.mo OK /usr/share/locale/nn/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/nn/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/mr/LC_MESSAGES/apt.mo OK /usr/share/locale/mr/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/mr/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/apt.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/libapt-pkg4.7.mo OK ... /usr/bin/apt-sortpkgs OK /usr/bin/apt-ftparchive OK /usr/bin/apt-extracttemplates OK /usr/share/locale/pt_BR/LC_MESSAGES/aptitude.mo OK /usr/share/locale/ja/LC_MESSAGES/aptitude.mo OK /usr/share/locale/pl/LC_MESSAGES/aptitude.mo OK /usr/share/locale/sk/LC_MESSAGES/aptitude.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/aptitude.mo OK /usr/share/locale/it/LC_MESSAGES/aptitude.mo OK /usr/share/locale/lt/LC_MESSAGES/aptitude.mo OK |
#debsums | grep -v OK
debsums: no md5sums for at debsums: no md5sums for binutils debsums: no md5sums for bzip2 debsums: no md5sums for console-cyrillic debsums: no md5sums for debian-archive-keyring debsums: no md5sums for ed debsums: no md5sums for initscripts debsums: no md5sums for libbz2-1.0 debsums: no md5sums for libdb4.5 debsums: no md5sums for libgdbm3 debsums: no md5sums for liblockfile1 debsums: no md5sums for lockfile-progs debsums: no md5sums for mawk debsums: no md5sums for miscfiles debsums: no md5sums for module-init-tools debsums: no md5sums for netbase debsums: no md5sums for sysv-rc debsums: no md5sums for sysvinit debsums: no md5sums for sysvinit-utils |
#debsums | grep -v OK
debsums: no md5sums for at debsums: no md5sums for binutils debsums: no md5sums for bzip2 debsums: no md5sums for console-cyrillic debsums: no md5sums for debian-archive-keyring debsums: no md5sums for ed debsums: no md5sums for initscripts debsums: no md5sums for libbz2-1.0 debsums: no md5sums for libdb4.5 debsums: no md5sums for libgdbm3 debsums: no md5sums for liblockfile1 debsums: no md5sums for lockfile-progs debsums: no md5sums for mawk debsums: no md5sums for miscfiles debsums: no md5sums for module-init-tools debsums: no md5sums for netbase debsums: no md5sums for sysv-rc debsums: no md5sums for sysvinit debsums: no md5sums for sysvinit-utils |
#debsums --generate=missing
/usr/share/locale/sl/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/sl/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/nn/LC_MESSAGES/apt.mo OK /usr/share/locale/nn/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/nn/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/mr/LC_MESSAGES/apt.mo OK /usr/share/locale/mr/LC_MESSAGES/libapt-pkg4.7.mo OK /usr/share/locale/mr/LC_MESSAGES/libapt-inst1.1.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/apt.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/libapt-pkg4.7.mo OK ... /usr/bin/apt-sortpkgs OK /usr/bin/apt-ftparchive OK /usr/bin/apt-extracttemplates OK /usr/share/locale/pt_BR/LC_MESSAGES/aptitude.mo OK /usr/share/locale/ja/LC_MESSAGES/aptitude.mo OK /usr/share/locale/pl/LC_MESSAGES/aptitude.mo OK /usr/share/locale/sk/LC_MESSAGES/aptitude.mo OK /usr/share/locale/zh_TW/LC_MESSAGES/aptitude.mo OK /usr/share/locale/it/LC_MESSAGES/aptitude.mo OK /usr/share/locale/lt/LC_MESSAGES/aptitude.mo OK |
# /etc/nsswitch.conf # # Example configuration of GNU Name Service Switch functionality. # If you have the `glibc-doc-reference' and `info' packages installed, try: # `info libc "Name Service Switch"' for information about this file. passwd: compat group: compat shadow: compat hosts: files dns networks: files protocols: db files services: db files ethers: db files rpc: db files netgroup: nis
access.conf limits.conf namespace.init pam_env.conf time.conf group.conf namespace.conf opasswd sepermit.conf
# /etc/security/limits.conf # #Each line describes a limit for a user in the form: # #<domain> <type> <item> <value> # #Where: #<domain> can be: # - an user name # - a group name, with @group syntax # - the wildcard *, for default entry # - the wildcard %, can be also used with %group syntax, # for maxlogin limit # - NOTE: group and wildcard limits are not applied to root. # To apply a limit to the root user, <domain> must be # the literal username root. # #<type> can have the two values: # - "soft" for enforcing the soft limits # - "hard" for enforcing hard limits # #<item> can be one of the following: # - core - limits the core file size (KB) # - data - max data size (KB) # - fsize - maximum filesize (KB) # - memlock - max locked-in-memory address space (KB) # - nofile - max number of open files # - rss - max resident set size (KB) # - stack - max stack size (KB) # - cpu - max CPU time (MIN) # - nproc - max number of processes # - as - address space limit (KB) # - maxlogins - max number of logins for this user # - maxsyslogins - max number of logins on the system # - priority - the priority to run user process with # - locks - max number of file locks the user can hold # - sigpending - max number of pending signals # - msgqueue - max memory used by POSIX message queues (bytes) # - nice - max nice priority allowed to raise to values: [-20, 19] # - rtprio - max realtime priority # - chroot - change root to directory (Debian-specific) # #<domain> <type> <item> <value> # #* soft core 0 #root hard core 100000 #* hard rss 10000 #@student hard nproc 20 #@faculty soft nproc 20 #@faculty hard nproc 50 #ftp hard nproc 0 #ftp - chroot /ftp #@student - maxlogins 4 # End of file
Время первой команды журнала | 16:13:31 2009- 5-28 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 10:53:55 2009- 5-29 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 101 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 25.74 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 1.98 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 2.02 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 0.84 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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