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

Содержание

Журнал

Вторник (03/27/12)

/dev/ttyp0
18:10:26
#ls /etc/
X11                     lilalo                  printcap
aliases                 localtime               profile
amd.map                 locate.rc               protocols
apmd.conf               login.access            pwd.db
auth.conf               login.conf              rc
bluetooth               login.conf.db           rc.bsdextended
crontab                 mac.conf                rc.conf
csh.cshrc               mail                    rc.d
csh.login               mail.rc                 rc.firewall
csh.logout              make.conf               rc.firewall6
...
gss                     opieaccess              snmpd.config
host.conf               opiekeys                spwd.db
hostid                  pam.d                   ssh
hosts                   passwd                  ssl
hosts.allow             pccard_ether            sysctl.conf
hosts.equiv             periodic                syslog.conf
hosts.lpd               pf.os                   termcap
inetd.conf              phones                  ttys
isdn                    portsnap.conf           zfs
libalias.conf           ppp
18:10:50
#ls /usr/
-p      bin     games   include libdata local   ports   share   test
.snap   compat  home    lib     libexec obj     sbin    src
18:12:08
#ls ~/
.bash_history   .bashrc~        .k5login        .profile        laba
.bash_profile   .cache          .l3rc           .viminfo        q
.bash_profile~  .cshrc          .lilalo         .vimrc          test
.bashrc         .history        .login          exrc            test2
18:12:35
#vim .bashrc
18:15:25
#~
bash: :q: command not found
18:21:02
#cd ~/laba

18:21:53
#pwd
/root/laba
18:21:55
#ls
.man_xorg_conf                          man_smb_conf
.putty.exe                              matrix.jpg
.video                                  names
Light_Alloy_4.4.784_RC2_by_FAFNIR.exe   ogo.jpg
backup                                  pamyatka.pdf
bigfile                                 press_any_key_to_continue.jpg
bin                                     proj
freebsd.jpg                             text
granata.jpg                             touchlist
lpi 1                                   x-hardlink
lpi 2                                   x-symlink
18:21:58
#ls a*
ls: a*: No such file or directory
18:22:04
#cd names

18:22:20
#pwd
/root/laba/names
18:22:22
#ls -l
total 116
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 -file1
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 -hello
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 .._bash
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 ._bash
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 .bash
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 .j_bash
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 .passwd
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 1cdesktop
-rwxr-xr-x  1 root  wheel   7123 Mar 26 19:13 Regexp.H
...
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 bjen
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 bjon
-rwxr-xr-x  1 root  wheel   8624 Mar 26 19:13 core.c
-rwxr-xr-x  1 root  wheel   6989 Mar 26 19:13 fcntl.h
-rwxr-xr-x  1 root  wheel    689 Mar 26 19:13 group
-rwxr-xr-x  1 root  wheel  25937 Mar 26 19:13 isdn_ttyfax.c
-rwxr-xr-x  1 root  wheel    277 Mar 26 19:13 modules
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 passwd
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 s_tol_
-rwxr-xr-x  1 root  wheel  40290 Mar 26 19:13 term.h
18:22:25
#ls a*
alloca.H
acpi:
events                          powerbtn-acpi-support.sh
18:22:31
#ls -d
acpi            alloca.H
18:22:42
#ls *.[cChH]
Regexp.H        core.c          isdn_ttyfax.c
alloca.H        fcntl.h         term.h
18:23:20
#ls *BSD*
ls: *BSD*: No such file or directory
18:23:42
#ls j?n
ls: j?n: No such file or directory
18:24:10
#ls *?n
bjan    bjen    bjon
18:24:21
#ls --*
ls: illegal option -- -
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:24:43
#ls -- -*
-file1  -hello
18:24:49
#ls ./
./-file1        ./-hello
18:24:57
#ls ./*
./-file1        ./_1_2_3        ./alloca.H      ./core.c        ./modules
./-hello        ./__asterisk    ./bjan          ./fcntl.h       ./passwd
./1cdesktop     ./_hrypun       ./bjen          ./group         ./s_tol_
./Regexp.H      ./_kik_my       ./bjon          ./isdn_ttyfax.c ./term.h
./acpi:
events                          powerbtn-acpi-support.sh
18:25:31
#ls -- *
-file1          _1_2_3          alloca.H        core.c          modules
-hello          __asterisk      bjan            fcntl.h         passwd
1cdesktop       _hrypun         bjen            group           s_tol_
Regexp.H        _kik_my         bjon            isdn_ttyfax.c   term.h
acpi:
events                          powerbtn-acpi-support.sh
18:25:45
#ls \-*
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:25:57
#ls \--*
ls: illegal option -- -
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:26:11
#ls \-- *
-file1          _1_2_3          alloca.H        core.c          modules
-hello          __asterisk      bjan            fcntl.h         passwd
1cdesktop       _hrypun         bjen            group           s_tol_
Regexp.H        _kik_my         bjon            isdn_ttyfax.c   term.h
acpi:
events                          powerbtn-acpi-support.sh
18:26:13
#ls \- *
ls: -: No such file or directory
-file1          _1_2_3          alloca.H        core.c          modules
-hello          __asterisk      bjan            fcntl.h         passwd
1cdesktop       _hrypun         bjen            group           s_tol_
Regexp.H        _kik_my         bjon            isdn_ttyfax.c   term.h
acpi:
events                          powerbtn-acpi-support.sh
18:26:21
#ls \-*
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:26:23
#ls \---*
ls: illegal option -- -
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:26:26
#ls '-'*
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:26:42
#ls `-`*
bash: -: command not found
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:26:49
#ls `-*`
bash: -file1: command not found
-file1          .passwd         _kik_my         core.c          s_tol_
-hello          1cdesktop       acpi            fcntl.h         term.h
.._bash         Regexp.H        alloca.H        group
._bash          _1_2_3          bjan            isdn_ttyfax.c
.bash           __asterisk      bjen            modules
.j_bash         _hrypun         bjon            passwd
18:26:58
#ls '*'
ls: illegal option -- *
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:27:18
#ls "-*"
ls: illegal option -- *
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:27:25
#ls *\**\?*
ls: ***?*: No such file or directory
18:30:04
#ls *
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:30:19
#ls \*
ls: *: No such file or directory
18:30:24
#ls *
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:30:29
#ls -l *
ls: illegal option -- e
usage: ls [-ABCFGHILPRSTUWZabcdfghiklmnopqrstuwx1] [file ...]
18:30:44
#pwd
/root/laba/names
18:31:35
#ls *'*'*'?'*
ls: ***?*: No such file or directory
18:32:07
#ls *[*]*[?]*
ls: *[*]*[?]*: No such file or directory
18:32:32
#ls -l
total 116
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 -file1
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 -hello
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 .._bash
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 ._bash
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 .bash
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 .j_bash
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 .passwd
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 1cdesktop
-rwxr-xr-x  1 root  wheel   7123 Mar 26 19:13 Regexp.H
...
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 bjen
-rwxr-xr-x  1 root  wheel      0 Mar 26 19:13 bjon
-rwxr-xr-x  1 root  wheel   8624 Mar 26 19:13 core.c
-rwxr-xr-x  1 root  wheel   6989 Mar 26 19:13 fcntl.h
-rwxr-xr-x  1 root  wheel    689 Mar 26 19:13 group
-rwxr-xr-x  1 root  wheel  25937 Mar 26 19:13 isdn_ttyfax.c
-rwxr-xr-x  1 root  wheel    277 Mar 26 19:13 modules
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 passwd
-rwxr-xr-x  1 root  wheel      1 Mar 26 19:13 s_tol_
-rwxr-xr-x  1 root  wheel  40290 Mar 26 19:13 term.h
18:33:11
#ls -d
.
18:33:13
#ls
-file1          .passwd         _kik_my         core.c          s_tol_
-hello          1cdesktop       acpi            fcntl.h         term.h
.._bash         Regexp.H        alloca.H        group
._bash          _1_2_3          bjan            isdn_ttyfax.c
.bash           __asterisk      bjen            modules
.j_bash         _hrypun         bjon            passwd
18:33:17
#cd ..

18:34:12
#ls -l
total 3482
-rwxr-xr-x  1 root  wheel    32810 Mar 26 19:13 .man_xorg_conf
-rwxr-xr-x  1 root  wheel   454656 Mar 26 19:13 .putty.exe
drwxr-xr-x  2 root  wheel      512 Mar 26 19:13 .video
-rwxr-xr-x  1 root  wheel  1751860 Mar 26 19:13 Light_Alloy_4.4.784_RC2_by_FAFNIR.exe
drwxr-xr-x  3 root  wheel      512 Mar 26 19:51 backup
-rwxr-xr-x  1 root  wheel     7994 Mar 26 19:13 bigfile
drwxr-xr-x  2 root  wheel      512 Mar 26 19:45 bin
-rwxr-xr-x  1 root  wheel   232966 Mar 26 19:13 freebsd.jpg
-rwxr-xr-x  1 root  wheel    52884 Mar 26 19:13 granata.jpg
...
-rwxr-xr-x  1 root  wheel   755680 Mar 26 19:13 matrix.jpg
drwxr-xr-x  3 root  wheel      512 Mar 26 19:13 names
-rwxr-xr-x  1 root  wheel    17622 Mar 26 19:13 ogo.jpg
-rwxr-xr-x  1 root  wheel    84663 Mar 26 19:13 pamyatka.pdf
-rwxr-xr-x  1 root  wheel    23048 Mar 26 19:13 press_any_key_to_continue.jpg
drwxr-xr-x  3 root  wheel      512 Mar 26 19:51 proj
drwxr-xr-x  2 root  wheel      512 Mar 27 16:54 text
-rwxr-xr-x  1 root  wheel       75 Mar 26 19:13 touchlist
-rwxr-xr-x  1 root  wheel        0 Mar 26 19:13 x-hardlink
lrwxr-xr-x  1 root  wheel       27 Mar 26 20:09 x-symlink -> /root/laba/proj/x-project/x
18:34:15
#pwd
/root/laba
18:34:30
#cd names/

18:34:47
#ls -la
total 120
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 -file1
-rwxr-xr-x   1 root  wheel      1 Mar 26 19:13 -hello
drwxr-xr-x   3 root  wheel    512 Mar 26 19:13 .
drwxr-xr-x  10 root  wheel    512 Mar 26 20:09 ..
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 .._bash
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 ._bash
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 .bash
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 .j_bash
-rwxr-xr-x   1 root  wheel      1 Mar 26 19:13 .passwd
...
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 bjen
-rwxr-xr-x   1 root  wheel      0 Mar 26 19:13 bjon
-rwxr-xr-x   1 root  wheel   8624 Mar 26 19:13 core.c
-rwxr-xr-x   1 root  wheel   6989 Mar 26 19:13 fcntl.h
-rwxr-xr-x   1 root  wheel    689 Mar 26 19:13 group
-rwxr-xr-x   1 root  wheel  25937 Mar 26 19:13 isdn_ttyfax.c
-rwxr-xr-x   1 root  wheel    277 Mar 26 19:13 modules
-rwxr-xr-x   1 root  wheel      1 Mar 26 19:13 passwd
-rwxr-xr-x   1 root  wheel      1 Mar 26 19:13 s_tol_
-rwxr-xr-x   1 root  wheel  40290 Mar 26 19:13 term.h
18:34:53
#ls *\[cde]*
ls: *[cde]*: No such file or directory
18:35:13
#ls *'[']*
ls: *[cde]*: No such file or directory
18:35:27
#cd ..

18:35:38
#ls *'['cde]*
ls: *[cde]*: No such file or directory
18:35:40
#ls *[[]cde]*
ls: *[[]cde]*: No such file or directory
18:36:54
#ls
.man_xorg_conf                          man_smb_conf
.putty.exe                              matrix.jpg
.video                                  names
Light_Alloy_4.4.784_RC2_by_FAFNIR.exe   ogo.jpg
backup                                  pamyatka.pdf
bigfile                                 press_any_key_to_continue.jpg
bin                                     proj
freebsd.jpg                             text
granata.jpg                             touchlist
lpi 1                                   x-hardlink
lpi 2                                   x-symlink
18:37:32
#cd names/

18:37:37
#ls
-file1          .passwd         _kik_my         core.c          s_tol_
-hello          1cdesktop       acpi            fcntl.h         term.h
.._bash         Regexp.H        alloca.H        group
._bash          _1_2_3          bjan            isdn_ttyfax.c
.bash           __asterisk      bjen            modules
.j_bash         _hrypun         bjon            passwd
18:37:39
#ls *[[]cde]*
ls: *[[]cde]*: No such file or directory
18:37:42
#ls *'['cde]*
ls: *[cde]*: No such file or directory
18:37:45
#ls *\[cde]*
ls: *[cde]*: No such file or directory
18:37:57
#ls .[^.]*
._bash  .bash   .j_bash .passwd
18:38:41
#ls -d .]*
._bash  .bash   .j_bash .passwd
18:39:25
#ls ..?*
.._bash
18:39:40
#ls ..*
.._bash
..:
.man_xorg_conf                          man_smb_conf
.putty.exe                              matrix.jpg
.video                                  names
Light_Alloy_4.4.784_RC2_by_FAFNIR.exe   ogo.jpg
backup                                  pamyatka.pdf
bigfile                                 press_any_key_to_continue.jpg
bin                                     proj
freebsd.jpg                             text
granata.jpg                             touchlist
lpi 1                                   x-hardlink
lpi 2                                   x-symlink
18:39:44
#pwd
/root/laba/names
18:39:53
#ls ..?*
.._bash
18:40:12
#echo zz*
zz*
18:40:58
#ls zz*
ls: zz*: No such file or directory
18:41:06
#echo a*
acpi alloca.H
18:41:31
#touch "file with space