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

Содержание

Журнал

Вторник (12/22/15)

/dev/pts/13
14:24:21
#ps ax | tr 0 x
  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     x:x2 init [2]
    2 ?        S      x:xx [kthreadd]
    3 ?        S      x:x1 [ksoftirqd/x]
    5 ?        S      x:xx [kworker/u:x]
    6 ?        S      x:xx [migration/x]
    7 ?        S      x:xx [watchdog/x]
    8 ?        S<     x:xx [cpuset]
    9 ?        S<     x:xx [khelper]
   1x ?        S      x:xx [kdevtmpfs]
...
 8147 ?        Ss     x:xx sshd: user [priv]
 8149 ?        S      x:xx sshd: user@pts/1x
 815x pts/1x   Ss+    x:xx -bash
 8196 ?        Ss     x:xx sshd: root@pts/13
 8198 pts/13   Ss     x:xx -bash
 8243 pts/13   S+     x:xx script -f -c l3script -q /root/.lilalo//299572x45125766281-145x785223.script
 8274 pts/13   S+     x:xx script -f -c l3script -q /root/.lilalo//299572x45125766281-145x785223.script
 8275 pts/14   Ss     x:xx l3script
 8657 pts/14   R+     x:xx ps ax
 8658 pts/14   S+     x:xx tr x x
14:27:45
#ps ax | tr -d 0
  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     :2 init [2]
    2 ?        S      : [kthreadd]
    3 ?        S      :1 [ksoftirqd/]
    5 ?        S      : [kworker/u:]
    6 ?        S      : [migration/]
    7 ?        S      : [watchdog/]
    8 ?        S<     : [cpuset]
    9 ?        S<     : [khelper]
   1 ?        S      : [kdevtmpfs]
...
 8147 ?        Ss     : sshd: user [priv]
 8149 ?        S      : sshd: user@pts/1
 815 pts/1   Ss+    : -bash
 8196 ?        Ss     : sshd: root@pts/13
 8198 pts/13   Ss     : -bash
 8243 pts/13   S+     : script -f -c l3script -q /root/.lilalo//29957245125766281-145785223.script
 8274 pts/13   S+     : script -f -c l3script -q /root/.lilalo//29957245125766281-145785223.script
 8275 pts/14   Ss     : l3script
 8666 pts/14   R+     : ps ax
 8667 pts/14   S+     : tr -d
14:28:08
#man
прошло 34 минуты
15:03:04
#man ls
15:09:45
#awk -F: '$3>=1000' /etc/passwd
nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
user:x:1000:1000:user,,,:/home/user:/bin/bash
ivan:x:1001:1001::/home/ivan:/bin/bash
petr:x:1002:1002::/home/petr:/bin/bash
15:09:58
#awk -F: '$3>=1000' && $3!=6534' /etc/passwd
> ^C
15:11:10
#mkdir scripts

15:16:20
#pwd
/root
15:16:24
#ls
d2  d3  d4  d5  file1  file2  file3  file4  file5  install  names  newfile  scripts  test  users
15:16:29
#vi chsh.sh
--- /dev/null	2015-12-21 11:32:59.551999997 +0200
+++ chsh.sh	2015-12-22 16:20:35.429633556 +0200
@@ -0,0 +1,2 @@
+#!/bin/bash
+
15:20:35
#history -w

15:21:02
#vi chsh.sh
/dev/pts/14
15:30:29
#cd scripts

/dev/pts/13
15:30:29
#cd scripts