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

Содержание

Журнал

Понедельник (11/02/20)

/dev/pts/0
11:52:55
#find . -type d -maxdepth 1
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.
./.aptitude
./.lilalo
./d4
./d2
./d1
./.vim
/dev/pts/1
11:52:55
#find . -type d -maxdepth 1
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.
./.aptitude
./.lilalo
./d4
./d2
./d1
./.vim
/dev/pts/0
11:53:01
#find . -maxdepth 1 -type d
.
./.aptitude
./.lilalo
./d4
./d2
./d1
./.vim
/dev/pts/1
11:53:01
#find . -maxdepth 1 -type d
.
./.aptitude
./.lilalo
./d4
./d2
./d1
./.vim
11:53:24
#find --help
Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]
default path is the current directory; default expression is -print
expression may consist of: operators, options, tests, and actions:
operators (decreasing precedence; -and is implicit where no others are given):
      ( EXPR )   ! EXPR   -not EXPR   EXPR1 -a EXPR2   EXPR1 -and EXPR2
      EXPR1 -o EXPR2   EXPR1 -or EXPR2   EXPR1 , EXPR2
positional options (always true): -daystart -follow -regextype
normal options (always true, specified before other expressions):
      -depth --help -maxdepth LEVELS -mindepth LEVELS -mount -noleaf
      --version -xdev -ignore_readdir_race -noignore_readdir_race
...
      -readable -writable -executable
      -wholename PATTERN -size N[bcwkMG] -true -type [bcdpflsD] -uid N
      -used N -user NAME -xtype [bcdpfls]
actions: -delete -print0 -printf FORMAT -fprintf FILE FORMAT -print
      -fprint0 FILE -fprint FILE -ls -fls FILE -prune -quit
      -exec COMMAND ; -exec COMMAND {} + -ok COMMAND ;
      -execdir COMMAND ; -execdir COMMAND {} + -okdir COMMAND ;
Report (and track progress on fixing) bugs via the findutils bug-reporting
page at http://savannah.gnu.org/ or, if you have no web access, by sending
email to <bug-findutils@gnu.org>.
/dev/pts/0
11:53:24
#find --help
Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]
default path is the current directory; default expression is -print
expression may consist of: operators, options, tests, and actions:
operators (decreasing precedence; -and is implicit where no others are given):
      ( EXPR )   ! EXPR   -not EXPR   EXPR1 -a EXPR2   EXPR1 -and EXPR2
      EXPR1 -o EXPR2   EXPR1 -or EXPR2   EXPR1 , EXPR2
positional options (always true): -daystart -follow -regextype
normal options (always true, specified before other expressions):
      -depth --help -maxdepth LEVELS -mindepth LEVELS -mount -noleaf
      --version -xdev -ignore_readdir_race -noignore_readdir_race
...
      -readable -writable -executable
      -wholename PATTERN -size N[bcwkMG] -true -type [bcdpflsD] -uid N
      -used N -user NAME -xtype [bcdpfls]
actions: -delete -print0 -printf FORMAT -fprintf FILE FORMAT -print
      -fprint0 FILE -fprint FILE -ls -fls FILE -prune -quit
      -exec COMMAND ; -exec COMMAND {} + -ok COMMAND ;
      -execdir COMMAND ; -execdir COMMAND {} + -okdir COMMAND ;
Report (and track progress on fixing) bugs via the findutils bug-reporting
page at http://savannah.gnu.org/ or, if you have no web access, by sending
email to <bug-findutils@gnu.org>.
11:53:40
#find -d tree
find: warning: the -d option is deprecated; please use -depth instead, because the latter is a POSIX-compliant feature.
find: paths must precede expression: tree
Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]
/dev/pts/1
11:53:40
#find -d tree
find: warning: the -d option is deprecated; please use -depth instead, because the latter is a POSIX-compliant feature.
find: paths must precede expression: tree
Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]
/dev/pts/0
11:54:10
#find . -type d -maxdepth 1 | xargs ls -l
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.:
total 24
drwxr-xr-x 2 root root 4096 Nov  2 11:53 d1
drwxr-xr-x 3 root root 4096 Nov  2 12:49 d2
drwxr-xr-x 3 root root 4096 Nov  2 11:56 d4
-rw-r--r-- 1 root root    0 Nov  2 12:48 f1
-rw-r--r-- 1 root root 5268 Oct 13  2014 install
-rw-r--r-- 1 root root  165 Nov  2 11:46 who.txt
./.aptitude:
...
total 0
./d1:
total 0
./d2:
total 4
drwxr-xr-x 2 root root 4096 Nov  2 11:54 d3
-rw-r--r-- 1 root root    0 Nov  2 12:49 f2
./d4:
total 4
drwxr-xr-x 2 root root 4096 Nov  2 11:56 d5
/dev/pts/1
11:54:10
#find . -type d -maxdepth 1 | xargs ls -l
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.:
total 24
drwxr-xr-x 2 root root 4096 Nov  2 11:53 d1
drwxr-xr-x 3 root root 4096 Nov  2 12:49 d2
drwxr-xr-x 3 root root 4096 Nov  2 11:56 d4
-rw-r--r-- 1 root root    0 Nov  2 12:48 f1
-rw-r--r-- 1 root root 5268 Oct 13  2014 install
-rw-r--r-- 1 root root  165 Nov  2 11:46 who.txt
./.aptitude:
...
total 0
./d1:
total 0
./d2:
total 4
drwxr-xr-x 2 root root 4096 Nov  2 11:54 d3
-rw-r--r-- 1 root root    0 Nov  2 12:49 f2
./d4:
total 4
drwxr-xr-x 2 root root 4096 Nov  2 11:56 d5
/dev/pts/0
11:56:32
#find . -type d -maxdepth 1 | xargs ls
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.:
d1  d2  d4  f1  install  who.txt
./.aptitude:
config
./.lilalo:
133518653134476610-1413379473.info
133518653134476610-1413379473.script
143184190977814884-1413212456.info
143184190977814884-1413212456.script
...
2525264871024819419-1403867138.script
l3-agent.pid
l3bashrc
l3prompt
./.vim:
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/1
11:56:32
#find . -type d -maxdepth 1 | xargs ls
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.:
d1  d2  d4  f1  install  who.txt
./.aptitude:
config
./.lilalo:
133518653134476610-1413379473.info
133518653134476610-1413379473.script
143184190977814884-1413212456.info
143184190977814884-1413212456.script
...
2525264871024819419-1403867138.script
l3-agent.pid
l3bashrc
l3prompt
./.vim:
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/0
11:56:38
#find . -type d -maxdepth 1 | xargs ls
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.:
d1  d2  d4  f1  install  who.txt
./.aptitude:
config
./.lilalo:
133518653134476610-1413379473.info
133518653134476610-1413379473.script
143184190977814884-1413212456.info
143184190977814884-1413212456.script
...
2525264871024819419-1403867138.script
l3-agent.pid
l3bashrc
l3prompt
./.vim:
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/1
11:56:38
#find . -type d -maxdepth 1 | xargs ls
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
.:
d1  d2  d4  f1  install  who.txt
./.aptitude:
config
./.lilalo:
133518653134476610-1413379473.info
133518653134476610-1413379473.script
143184190977814884-1413212456.info
143184190977814884-1413212456.script
...
2525264871024819419-1403867138.script
l3-agent.pid
l3bashrc
l3prompt
./.vim:
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/0
11:56:40
#find . -type d -a -name "d*" -maxdepth 1 | xargs ls
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/1
11:56:40
#find . -type d -a -name "d*" -maxdepth 1 | xargs ls
find: warning: you have specified the -maxdepth option after a non-option argument -type, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/0
11:57:21
#find . -maxdepth 1 -type d -a -name "d*" | xargs ls
./d1:
./d2:
d3  f2
./d4:
d5
/dev/pts/1
11:57:21
#find . -maxdepth 1 -type d -a -name "d*" | xargs ls
./d1:
./d2:
d3  f2
./d4:
d5
Text
Text
/dev/pts/0
12:01:06
#cp --help
Usage: cp [OPTION]... [-T] SOURCE DEST
  or:  cp [OPTION]... SOURCE... DIRECTORY
  or:  cp [OPTION]... -t DIRECTORY SOURCE...
Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.
Mandatory arguments to long options are mandatory for short options too.
  -a, --archive                same as -dR --preserve=all
      --attributes-only        don't copy the file data, just the attributes
      --backup[=CONTROL]       make a backup of each existing destination file
  -b                           like --backup but does not accept an argument
      --copy-contents          copy contents of special files when recursive
...
  existing, nil   numbered if numbered backups exist, simple otherwise
  simple, never   always make simple backups
As a special case, cp makes a backup of SOURCE when the force and backup
options are given and SOURCE and DEST are the same name for an existing,
regular file.
Report cp bugs to bug-coreutils@gnu.org
GNU coreutils home page: <http://www.gnu.org/software/coreutils/>
General help using GNU software: <http://www.gnu.org/gethelp/>
Report cp translation bugs to <http://translationproject.org/team/>
For complete documentation, run: info coreutils 'cp invocation'
/dev/pts/1
12:01:06
#cp --help
Usage: cp [OPTION]... [-T] SOURCE DEST
  or:  cp [OPTION]... SOURCE... DIRECTORY
  or:  cp [OPTION]... -t DIRECTORY SOURCE...
Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.
Mandatory arguments to long options are mandatory for short options too.
  -a, --archive                same as -dR --preserve=all
      --attributes-only        don't copy the file data, just the attributes
      --backup[=CONTROL]       make a backup of each existing destination file
  -b                           like --backup but does not accept an argument
      --copy-contents          copy contents of special files when recursive
...
  existing, nil   numbered if numbered backups exist, simple otherwise
  simple, never   always make simple backups
As a special case, cp makes a backup of SOURCE when the force and backup
options are given and SOURCE and DEST are the same name for an existing,
regular file.
Report cp bugs to bug-coreutils@gnu.org
GNU coreutils home page: <http://www.gnu.org/software/coreutils/>
General help using GNU software: <http://www.gnu.org/gethelp/>
Report cp translation bugs to <http://translationproject.org/team/>
For complete documentation, run: info coreutils 'cp invocation'
прошло 13 минут
/dev/pts/0
12:14:21
#cp -v d2/f2 d4
`d2/f2' -> `d4/f2'
/dev/pts/1
12:14:21
#cp -v d2/f2 d4
`d2/f2' -> `d4/f2'
/dev/pts/0
12:15:20
#cp -rv d2 d1
`d2' -> `d1/d2'
`d2/f2' -> `d1/d2/f2'
`d2/d3' -> `d1/d2/d3'
/dev/pts/1
12:15:20
#cp -rv d2 d1
`d2' -> `d1/d2'
`d2/f2' -> `d1/d2/f2'
`d2/d3' -> `d1/d2/d3'
/dev/pts/0
12:16:09
#find . -maxdepth 2 -type d -a -name "d*" | xargs ls
./d1:
d2
./d1/d2:
d3  f2
./d2:
d3  f2
./d2/d3:
./d4:
d5  f2
./d4/d5:
/dev/pts/1
12:16:09
#find . -maxdepth 2 -type d -a -name "d*" | xargs ls
./d1:
d2
./d1/d2:
d3  f2
./d2:
d3  f2
./d2/d3:
./d4:
d5  f2
./d4/d5:
/dev/pts/0
12:17:35
#rm d4
rm: cannot remove `d4': Is a directory
/dev/pts/1
12:17:35
#rm d4
rm: cannot remove `d4': Is a directory
/dev/pts/0
12:18:58
#rm -r d4

/dev/pts/1
12:18:58
#rm -r d4

/dev/pts/0
12:19:02
#find . -maxdepth 1 -type d -a -name "d*" | xargs ls
./d1:
d2
./d2:
d3  f2
/dev/pts/1
12:19:02
#find . -maxdepth 1 -type d -a -name "d*" | xargs ls
./d1:
d2
./d2:
d3  f2
/dev/pts/0
12:19:11
#echo d2/*
d2/d3 d2/f2
/dev/pts/1
12:19:11
#echo d2/*
d2/d3 d2/f2
/dev/pts/0
12:20:39
#cat who.txt
root     pts/0        2020-11-02 09:10 (192.168.15.11)
petr     pts/3        2020-11-02 09:51 (192.168.15.11)
ivan     pts/4        2020-11-02 09:51 (192.168.15.11)
/dev/pts/1
12:20:39
#cat who.txt
root     pts/0        2020-11-02 09:10 (192.168.15.11)
petr     pts/3        2020-11-02 09:51 (192.168.15.11)
ivan     pts/4        2020-11-02 09:51 (192.168.15.11)
/dev/pts/0
12:22:31
#shred who.txt

/dev/pts/1
12:22:31
#shred who.txt

/dev/pts/0
12:22:40
#cat who.txt
bŸØYUÞâ`€Óß̪wdÀ–­¨¯zNõ
þí{Îñ+‹¢c&W댠aÉ¹¥Nb~g`x<ÚµÊzƒs@õäþ?Œh²‰<<
                                           ;òafŒÆ—Íø‚­ïCúžäw+ô¨XhŒ‡Ã³²ç‡¥½ÿÿÓÁ•ØzìMææ-…‘N
QÛÒÑ>Aè'è[Bôöñפë¬Ûɘóå|;€¯­Lý_á«IKëÆJԂŸ÷”q³¦Ñúpnó@þl)ª.Œó²½4ŽXìÈÕ¼ÒÒÊØÅÁ!‰5FŸ8*«¸E~ʼnJNEO‘?º%oíäŠ6øF’ÒŽÔÄt¶æèp¿ÇAº~ãñG«B$wþ™òhFSêÔJiô¦
                                                                                                                                           a%Ó©„iŒéí±=.E .疕ëß,4dyh[–Qö—ÂhÖ&ÃeÜFÐt™£¿l»³J÷&:ýãK#•–¶g«Î4£½±<îcyÕoWžÖ´ñMKνÁþú”¦°ð¦ÉéqÛ
                                                                                                                                                                                                                                       ƒãÇÞb»5X®'«*ËىL¬L˜Á­ÒȗZ       zLؤWþ
                                                                                                                                                                                                                                                                              ñ‡·B¸:êBœ}aAOe³&/Fï»âE
                                                                                                                                                                                                                                                                                                                                                                      Bí?°V
                                                                                                                                                                                                                                                                                                    ‰z°c[Áìsö¥Çj÷¬hgB¯ŽôHxŒ×ñ>mXƨ4Yç7{£L ±·Y.B‡Poäºz¥éì½-nÀ„Ê[úÃ¾ä¸      Zí.\EšGeÈêô/mЁ|Éq|¥µj¦5Dt¡z¹…¾^¾‹—•
                                                                                                                                                                                                                                                                                                                                                                                                              |u
...
                                                               Máë0-ZJ=¬+þ& Ì£8_Æ-à+£!ü!À”g´(މvç¦M—ƒ
                                                                                                     w:囹váÓúª»«       û=p¼±ñÞ^æ3Xô ¤Š6™Á”°mó‹ùÁûç>Ž
d& Åý”ÇtѶÚxŠÓ‰³HŽB'
„)WëŒ}D        4©óœ¸”V;§]uùV‘ÀÉLûšýºœ4‘¼5ÃYc¬;3^¼7O”Óï2žr¡†
÷XšÚƒ`©7ꝸŠÏjåÌ@˜§Õ´Ø‚][¤¹ÒD÷OÒR      o
ÇÒªK£ÐنrÿȲ¾jýC
TF°ò‘œùÍޅxæˆ<V,Ôþ­îÄG£\P’»ìü*¸~0C±°¨E‰¶|„'s…O  vG*.¶ñ 0Àñá
                                                           ˆ’çù¶Ã#FÄøÃ+ýíµa_âÒXyÇÍp_K
©ïi€Ñ•áuÒùEAGëýÏVfáˆÓûÖæhòP»Ók¯.±VzaX0î¢ÆŠ®=_í=w_Aæiôú”€ãß
E©      pÏrÚ{»5"Ë4šÔa  /Z¼%݊¶f`gWÀ¡«úÿVVØ4¶>‘…¸h ºiËmökóIç ª¶Ï/ŠÔ¤³¦àŸ;Ô¿
/dev/pts/1
12:22:40
#cat who.txt
bŸØYUÞâ`€Óß̪wdÀ–­¨¯zNõ
þí{Îñ+‹¢c&W댠aÉ¹¥Nb~g`x<ÚµÊzƒs@õäþ?Œh²‰<<
                                           ;òafŒÆ—Íø‚­ïCúžäw+ô¨XhŒ‡Ã³²ç‡¥½ÿÿÓÁ•ØzìMææ-…‘N
QÛÒÑ>Aè'è[Bôöñפë¬Ûɘóå|;€¯­Lý_á«IKëÆJԂŸ÷”q³¦Ñúpnó@þl)ª.Œó²½4ŽXìÈÕ¼ÒÒÊØÅÁ!‰5FŸ8*«¸E~ʼnJNEO‘?º%oíäŠ6øF’ÒŽÔÄt¶æèp¿ÇAº~ãñG«B$wþ™òhFSêÔJiô¦
                                                                                                                                           a%Ó©„iŒéí±=.E .疕ëß,4dyh[–Qö—ÂhÖ&ÃeÜFÐt™£¿l»³J÷&:ýãK#•–¶g«Î4£½±<îcyÕoWžÖ´ñMKνÁþú”¦°ð¦ÉéqÛ
                                                                                                                                                                                                                                       ƒãÇÞb»5X®'«*ËىL¬L˜Á­ÒȗZ       zLؤWþ
                                                                                                                                                                                                                                                                              ñ‡·B¸:êBœ}aAOe³&/Fï»âE
                                                                                                                                                                                                                                                                                                                                                                      Bí?°V
                                                                                                                                                                                                                                                                                                    ‰z°c[Áìsö¥Çj÷¬hgB¯ŽôHxŒ×ñ>mXƨ4Yç7{£L ±·Y.B‡Poäºz¥éì½-nÀ„Ê[úÃ¾ä¸      Zí.\EšGeÈêô/mЁ|Éq|¥µj¦5Dt¡z¹…¾^¾‹—•
                                                                                                                                                                                                                                                                                                                                                                                                              |u
...
                                                               Máë0-ZJ=¬+þ& Ì£8_Æ-à+£!ü!À”g´(މvç¦M—ƒ
                                                                                                     w:囹váÓúª»«       û=p¼±ñÞ^æ3Xô ¤Š6™Á”°mó‹ùÁûç>Ž
d& Åý”ÇtѶÚxŠÓ‰³HŽB'
„)WëŒ}D        4©óœ¸”V;§]uùV‘ÀÉLûšýºœ4‘¼5ÃYc¬;3^¼7O”Óï2žr¡†
÷XšÚƒ`©7ꝸŠÏjåÌ@˜§Õ´Ø‚][¤¹ÒD÷OÒR      o
ÇÒªK£ÐنrÿȲ¾jýC
TF°ò‘œùÍޅxæˆ<V,Ôþ­îÄG£\P’»ìü*¸~0C±°¨E‰¶|„'s…O  vG*.¶ñ 0Àñá
                                                           ˆ’çù¶Ã#FÄøÃ+ýíµa_âÒXyÇÍp_K
©ïi€Ñ•áuÒùEAGëýÏVfáˆÓûÖæhòP»Ók¯.±VzaX0î¢ÆŠ®=_í=w_Aæiôú”€ãß
E©      pÏrÚ{»5"Ë4šÔa  /Z¼%݊¶f`gWÀ¡«úÿVVØ4¶>‘…¸h ºiËmökóIç ª¶Ï/ŠÔ¤³¦àŸ;Ô¿
/dev/pts/0
12:23:01
#ls -l
total 20
drwxr-xr-x 3 root root 4096 Nov  2 13:16 d1
drwxr-xr-x 3 root root 4096 Nov  2 12:49 d2
-rw-r--r-- 1 root root    0 Nov  2 12:48 f1
-rw-r--r-- 1 root root 5268 Oct 13  2014 install
-rw-r--r-- 1 root root 4096 Nov  2 13:22 who.txt
/dev/pts/1
12:23:01
#ls -l
total 20
drwxr-xr-x 3 root root 4096 Nov  2 13:16 d1
drwxr-xr-x 3 root root 4096 Nov  2 12:49 d2
-rw-r--r-- 1 root root    0 Nov  2 12:48 f1
-rw-r--r-- 1 root root 5268 Oct 13  2014 install
-rw-r--r-- 1 root root 4096 Nov  2 13:22 who.txt
/dev/pts/0
12:23:22
#shred -u who.txt

/dev/pts/1
12:23:22
#shred -u who.txt

/dev/pts/0
12:26:25
#ls -l
total 16
drwxr-xr-x 3 root root 4096 Nov  2 13:16 d1
drwxr-xr-x 3 root root 4096 Nov  2 12:49 d2
-rw-r--r-- 1 root root    0 Nov  2 12:48 f1
-rw-r--r-- 1 root root 5268 Oct 13  2014 install
/dev/pts/1
12:26:25
#ls -l
total 16
drwxr-xr-x 3 root root 4096 Nov  2 13:16 d1
drwxr-xr-x 3 root root 4096 Nov  2 12:49 d2
-rw-r--r-- 1 root root    0 Nov  2 12:48 f1
-rw-r--r-- 1 root root 5268 Oct 13  2014 install
/dev/pts/0
12:26:30
#which vi
/usr/bin/vi
/dev/pts/1
12:26:30
#which vi
/usr/bin/vi
прошло 75 минут
/dev/pts/0
13:42:00
#ls /usr/bin/vi
/usr/bin/vi
/dev/pts/1
13:42:00
#ls /usr/bin/vi
/usr/bin/vi
/dev/pts/0
13:42:10
#ls
d1  d2  f1  install
/dev/pts/1
13:42:10
#ls
d1  d2  f1  install
/dev/pts/0
13:42:13
#lsR /usr/bin/vi
l3script: lsR: command not found
/dev/pts/1
13:42:13
#lsR /usr/bin/vi
l3script: lsR: command not found
/dev/pts/0
13:42:30
#ls /usr/bin/vi -li
137306 lrwxrwxrwx 1 root root 20 Jun 27  2014 /usr/bin/vi -> /etc/alternatives/vi
/dev/pts/1
13:42:30
#ls /usr/bin/vi -li
137306 lrwxrwxrwx 1 root root 20 Jun 27  2014 /usr/bin/vi -> /etc/alternatives/vi
/dev/pts/0
13:42:39
#cd /etc/alternatives/vi
l3script: cd: /etc/alternatives/vi: Not a directory
/dev/pts/1
13:42:39
#cd /etc/alternatives/vi
l3script: cd: /etc/alternatives/vi: Not a directory
/dev/pts/0
13:43:10
#cd /etc/alternatives/

/dev/pts/1
13:43:10
#cd /etc/alternatives/

/dev/pts/0
13:43:13
#ls vi </