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

Содержание

Журнал

Четверг (10/18/18)

/dev/pts/2
15:37:42
$last
user     pts/2        192.168.15.120   Thu Oct 18 16:34   still logged in
user     pts/2        192.168.15.120   Thu Oct 18 16:32 - 16:33  (00:01)
user     pts/2        192.168.15.120   Thu Oct 18 16:30 - 16:31  (00:00)
user     pts/2        192.168.15.120   Thu Oct 18 16:29 - 16:30  (00:01)
ivan     pts/5        192.168.15.120   Thu Oct 18 15:28   still logged in
user     pts/2        192.168.15.120   Thu Oct 18 08:56 - 16:29  (07:33)
root     pts/0        192.168.15.120   Thu Oct 18 08:55   still logged in
root     pts/0        192.168.15.120   Wed Oct 17 10:04 - 17:08  (07:03)
user     pts/3        192.168.15.120   Wed Oct 17 10:01 - 17:08  (07:07)
ivan     pts/1        192.168.15.120   Wed Oct 17 09:53 - 16:56  (07:02)
...
user     pts/3        192.168.15.120   Wed Oct 17 08:59 - 10:01  (01:01)
petr     pts/2        192.168.15.120   Wed Oct 17 08:58 - 16:56  (07:57)
ivan     pts/1        192.168.15.120   Wed Oct 17 08:58 - 09:46  (00:47)
root     pts/0        192.168.15.120   Wed Oct 17 08:57 - 09:43  (00:45)
user     pts/4        192.168.15.120   Tue Oct 16 10:49 - 16:54  (06:05)
petr     pts/3        192.168.15.120   Tue Oct 16 10:44 - 16:54  (06:10)
ivan     pts/2        192.168.15.120   Tue Oct 16 10:39 - 16:54  (06:15)
ivan     pts/2        192.168.15.120   Tue Oct 16 10:23 - 10:30  (00:06)
root     pts/0        192.168.15.120   Tue Oct 16 09:50 - 16:54  (07:04)
wtmp begins Tue Oct 16 09:50:26 2018
15:38:00
$last -10
user     pts/2        192.168.15.120   Thu Oct 18 16:34   still logged in
user     pts/2        192.168.15.120   Thu Oct 18 16:32 - 16:33  (00:01)
user     pts/2        192.168.15.120   Thu Oct 18 16:30 - 16:31  (00:00)
user     pts/2        192.168.15.120   Thu Oct 18 16:29 - 16:30  (00:01)
ivan     pts/5        192.168.15.120   Thu Oct 18 15:28   still logged in
user     pts/2        192.168.15.120   Thu Oct 18 08:56 - 16:29  (07:33)
root     pts/0        192.168.15.120   Thu Oct 18 08:55   still logged in
root     pts/0        192.168.15.120   Wed Oct 17 10:04 - 17:08  (07:03)
user     pts/3        192.168.15.120   Wed Oct 17 10:01 - 17:08  (07:07)
ivan     pts/1        192.168.15.120   Wed Oct 17 09:53 - 16:56  (07:02)
wtmp begins Tue Oct 16 09:50:26 2018

Пятница (10/19/18)

/dev/pts/7
11:18:13
$ls
10                                     no_file_with_this_name
5                                      ogo.jpg
backup                                 pamyatka.pdf
bigfile                                press_any_key_to_continue.jpg
bin                                    proj
errlog                                 sh
file                                   soft
freebsd.jpg                            sorted
granata.jpg                            sorted_passwd
Light_Alloy_4.4.784_RC2_by_FAFNIR.exe  source
lpi 1                                  text
lpi 2                                  touchlist
man_smb_conf                           < touchlist
matrix.jpg                             unsorted
names                                  y
newfile
11:18:20
$mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,relatime,size=10240k,nr_inodes=61932,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=50740k,mode=755)
/dev/disk/by-uuid/92b79496-a6c3-450d-a438-766caa8504d8 on / type ext4 (rw,relatime,errors=remount-ro,user_xattr,barrier=1,data=ordered)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /run/shm type tmpfs (rw,nosuid,nodev,noexec,relatime,size=101460k)
/dev/xvdb1 on /mnt/data type ext4 (rw,relatime,user_xattr,barrier=1,data=ordered)
11:18:34
$uptime
 15:48:11 up 4 days, 18:22,  4 users,  load average: 0.15, 0.06, 0.06
прошло >3 часов
/dev/pts/1
14:43:14
$ps
  PID TTY          TIME CMD
16651 pts/2    00:00:00 l3script
16712 pts/2    00:00:00 ps
14:43:20
$ps -x
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
  PID TTY      STAT   TIME COMMAND
 3474 ?        Ss     5:26 l3-agent
15571 ?        S      0:00 sshd: user@pts/7
15572 pts/7    Ss+    0:00 -bash
15617 pts/7    S+     0:00 script -f -c l3script -q /home/user/.lilalo//49632710
15688 pts/7    S+     0:00 script -f -c l3script -q /home/user/.lilalo//49632710
15689 pts/8    Ss+    0:00 l3script
16533 ?        S      0:00 sshd: user@pts/1
16534 pts/1    Ss+    0:00 -bash
16579 pts/1    S+     0:00 script -f -c l3script -q /home/user/.lilalo//29701131
16650 pts/1    S+     0:00 script -f -c l3script -q /home/user/.lilalo//29701131
16651 pts/2    Ss     0:00 l3script
16720 pts/2    R+     0:00 ps -x
14:43:23
$ps U user
  PID TTY      STAT   TIME COMMAND
 3474 ?        Ss     5:26 l3-agent
15571 ?        S      0:00 sshd: user@pts/7
15572 pts/7    Ss+    0:00 -bash
15617 pts/7    S+     0:00 script -f -c l3script -q /home/user/.lilalo//49632710
15688 pts/7    S+     0:00 script -f -c l3script -q /home/user/.lilalo//49632710
15689 pts/8    Ss+    0:00 l3script
16533 ?        S      0:00 sshd: user@pts/1
16534 pts/1    Ss+    0:00 -bash
16579 pts/1    S+     0:00 script -f -c l3script -q /home/user/.lilalo//29701131
16650 pts/1    S+     0:00 script -f -c l3script -q /home/user/.lilalo//29701131
16651 pts/2    Ss     0:00 l3script
16728 pts/2    R+     0:00 ps U user
14:43:28
$ps -t tty1
  PID TTY          TIME CMD
 2297 tty1     00:00:00 getty
14:43:33
$ps U ivan
  PID TTY      STAT   TIME COMMAND
15849 ?        S      0:00 sshd: ivan@pts/0
15850 pts/0    Ss+    0:00 -bash
14:43:48
$ps U root
  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     0:07 init [2]
    2 ?        S      0:00 [kthreadd]
    3 ?        S      0:01 [ksoftirqd/0]
    5 ?        S      0:00 [kworker/u:0]
    6 ?        S      0:00 [migration/0]
    7 ?        S      0:03 [watchdog/0]
    8 ?        S<     0:00 [cpuset]
    9 ?        S<     0:00 [khelper]
   10 ?        S      0:00 [kdevtmpfs]
...
15224 pts/5    Ss+    0:00 -bash
15269 pts/5    S+     0:00 script -f -c l3script -q /root/.lilalo//2284925916204
15300 pts/5    S+     0:00 script -f -c l3script -q /root/.lilalo//2284925916204
15301 pts/6    Ss+    0:00 l3script
15546 ?        S      0:00 [jbd2/xvdb1-8]
15547 ?        S<     0:00 [ext4-dio-unwrit]
15569 ?        Ss     0:00 sshd: user [priv]
15847 ?        Ss     0:00 sshd: ivan [priv]
16414 ?        Ss     0:00 /usr/sbin/sshd
16531 ?        Ss     0:00 sshd: user [priv]
14:43:53
$ps -ax
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     0:07 init [2]
    2 ?        S      0:00 [kthreadd]
    3 ?        S      0:01 [ksoftirqd/0]
    5 ?        S      0:00 [kworker/u:0]
    6 ?        S      0:00 [migration/0]
    7 ?        S      0:03 [watchdog/0]
    8 ?        S<     0:00 [cpuset]
...
15849 ?        S      0:00 sshd: ivan@pts/0
15850 pts/0    Ss+    0:00 -bash
16414 ?        Ss     0:00 /usr/sbin/sshd
16531 ?        Ss     0:00 sshd: user [priv]
16533 ?        S      0:00 sshd: user@pts/1
16534 pts/1    Ss+    0:00 -bash
16579 pts/1    S+     0:00 script -f -c l3script -q /home/user/.lilalo//29701131
16650 pts/1    S+     0:00 script -f -c l3script -q /home/user/.lilalo//29701131
16651 pts/2    Ss     0:00 l3script
16760 pts/2    R+     0:00 ps -ax
14:44:06
$ps -aux
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root         1  0.0  0.1  10648   836 ?        Ss   Oct14   0:07 init [2]
root         2  0.0  0.0      0     0 ?        S    Oct14   0:00 [kthreadd]
root         3  0.0  0.0      0     0 ?        S    Oct14   0:01 [ksoftirqd/0]
root         5  0.0  0.0      0     0 ?        S    Oct14   0:00 [kworker/u:0]
root         6  0.0  0.0      0     0 ?        S    Oct14   0:00 [migration/0]
root         7  0.0  0.0      0     0 ?        S    Oct14   0:03 [watchdog/0]
root         8  0.0  0.0      0     0 ?        S<   Oct14   0:00 [cpuset]
...
ivan     15849  0.0  0.3  71288  1876 ?        S    14:10   0:00 sshd: ivan@pts/
ivan     15850  0.0  0.6  22584  3368 pts/0    Ss+  14:10   0:00 -bash
root     16414  0.0  0.2  49932  1208 ?        Ss   15:07   0:00 /usr/sbin/sshd
root     16531  0.0  0.7  71288  3600 ?        Ss   15:43   0:00 sshd: user [pri
user     16533  0.0  0.3  71288  1748 ?        S    15:43   0:00 sshd: user@pts/
user     16534  0.0  0.5  21992  2588 pts/1    Ss+  15:43   0:00 -bash
user     16579  0.0  0.1  18164   840 pts/1    S+   15:43   0:00 script -f -c l3
user     16650  0.0  0.0  18168   468 pts/1    S+   15:43   0:00 script -f -c l3
user     16651  0.1  0.5  22176  2856 pts/2    Ss   15:43   0:00 l3script
user     16768  0.0  0.2  18948  1272 pts/2    R+   15:44   0:00 ps -aux
14:44:11
$ps -avx
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
  PID TTY      STAT   TIME  MAJFL   TRS   DRS   RSS %MEM COMMAND
    1 ?        Ss     0:07     17     0 10648   836  0.1 init [2]
    2 ?        S      0:00      0     0     0     0  0.0 [kthreadd]
    3 ?        S      0:01      0     0     0     0  0.0 [ksoftirqd/0]
    5 ?        S      0:00      0     0     0     0  0.0 [kworker/u:0]
    6 ?        S      0:00      0     0     0     0  0.0 [migration/0]
    7 ?        S      0:03      0     0     0     0  0.0 [watchdog/0]
    8 ?        S<     0:00      0     0     0     0  0.0 [cpuset]
...
15849 ?        S      0:00      0     0 71288  1876  0.3 sshd: ivan@pts/0
15850 pts/0    Ss+    0:00      0     0 22584  3368  0.6 -bash
16414 ?        Ss     0:00      0     0 49932  1208  0.2 /usr/sbin/sshd
16531 ?        Ss     0:00      0     0 71288  3600  0.7 sshd: user [priv]
16533 ?        S      0:00      0     0 71288  1748  0.3 sshd: user@pts/1
16534 pts/1    Ss+    0:00      0   914 21077  2588  0.5 -bash
16579 pts/1    S+     0:00      0    10 18153   840  0.1 script -f -c l3script -
16650 pts/1    S+     0:00      0    10 18157   468  0.0 script -f -c l3script -
16651 pts/2    Ss     0:00      0   914 21261  2856  0.5 l3script
16776 pts/2    R+     0:00      0    84 10451   840  0.1 ps -avx
14:44:14
$ps -aux | grep -v USER.*PID.*%CPU | sort -n +3
sort: open failed: +3: No such file or directory
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
14:44:43
$ps -aux | grep -v USER.*PID.*%CPU | sort -n -3
sort: invalid option -- '3'
Try `sort --help' for more information.
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
14:45:00
$ps -aux | grep -v USER.*PID.*%CPU | sort -n
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
ivan     15849  0.0  0.3  71288  1876 ?        S    14:10   0:00 sshd: ivan@pts/0
ivan     15850  0.0  0.6  22584  3368 pts/0    Ss+  14:10   0:00 -bash
root        10  0.0  0.0      0     0 ?        S    Oct14   0:00 [kdevtmpfs]
root         1  0.0  0.1  10648   836 ?        Ss   Oct14   0:07 init [2]
root        11  0.0  0.0      0     0 ?        S<   Oct14   0:00 [netns]
root        12  0.0  0.0      0     0 ?        S    Oct14   0:00 [xenwatch]
root       130  0.0  0.0      0     0 ?        D    Oct14   0:05 [jbd2/xvda1-8]
root        13  0.0  0.0      0     0 ?        S    Oct14   0:00 [xenbus]
...
user     15689  0.0  0.6  22276  3048 pts/8    Ss+  12:18   0:00 l3script
user     16533  0.0  0.3  71288  1748 ?        S    15:43   0:00 sshd: user@pts/1
user     16534  0.0  0.5  21992  2588 pts/1    Ss+  15:43   0:00 -bash
user     16579  0.0  0.1  18164   840 pts/1    S+   15:43   0:00 script -f -c l3script -q /home/user/.lilalo//2970113187745430882-1539952994.script
user     16650  0.0  0.0  18168   468 pts/1    S+   15:43   0:00 script -f -c l3script -q /home/user/.lilalo//2970113187745430882-1539952994.script
user     16651  0.1  0.5  22180  2864 pts/2    Ss   15:43   0:00 l3script
user     16804  0.0  0.2  18948  1272 pts/2    R+   15:45   0:00 ps -aux
user     16806  0.0  0.1  16220   796 pts/2    S+   15:45   0:00 sort -n
user      3474  0.1  2.5  50300 12876 ?        Ss   Oct16   5:29 l3-agent
101       2270  0.0  0.2  46808  1036 ?        Ss   Oct14   0:00 /usr/sbin/exim4 -bd -q30m
14:45:02
$pstree
init─┬─acpid
     ├─cron
     ├─exim4
     ├─6*[getty]
     ├─2*[l3-agent]
     ├─rsyslogd───3*[{rsyslogd}]
     ├─sshd───bash───script───script───l3script
     ├─sshd───sshd───bash───script───script───l3script
     ├─sshd───sshd───bash
     ├─sshd───sshd───sshd───bash───script───script───l3script───pstree
     └─udevd───2*[udevd]
14:45: