Home > OS >  The first and second ZhangYun wiki homework this order
The first and second ZhangYun wiki homework this order

Time:10-06


1: touch the file # # to set up a file

2: mkdir test # # to create a directory

Mkdir -p test1/test2 # # - p based recursive directory

3. The rm file # # file delete

The rm -f file

Directory # # 4. The rm - r - r recursive delete,
The rm -r -f dir

5. Gedit file # # must have a graphical

Vim file # # write files, : wq to exit the save

6: the cat file # # to check the contents of the file

7: tail file # # to check the file after ten lines

8: the head file # # to check the file before ten lines

9: less file # # page to browse

10: mv file file2 # # the contents of a file file are covered, equivalent to rename

11: mv file dir # # to move the file files to dir directory
The mv dir/. # # the dir move so file to the desktop in the

12: cp file file1 # # copies the file file content to file1 file

13: cp file file1 dir # # file, file1 file is copied to the dir directory

14: cp -r dir dir1-name # # copies dir source article directory to the dir1-name purpose directory

15: wc file # # statistical file size

-l file # # statistical file lines

Statistics - c file # # file bytes

- w file # # statistical file word count

-m file # # file statistics characters


[root @ localhost Desktop] # touch WESTOS_class _linux {1, 2} {1.. 6} redhat_version {1.. 8}
[root @ localhost Desktop] # mkdir study/TMP/VERSION SINGLE/DOUBLE CLASS1 CLASS2 confdir

[root @ localhost Desktop] # mv WESTOS_class _linux {1, 2} {1.. 6} study

[root @ localhost Desktop] # mv redhat_version {1.. 8}/TMP/VERSION

[root @ localhost Desktop] # cp/TMP/VERSIONredhat_version hc-positie {1} SINGLE

[root @ localhost Desktop] # cp/TMP/VERSIONredhat_version,4,6,8 {2}/DOUBLE

[root @ localhost Desktop] # study mv/WESTOS_class [1] _linux {1.. 6} CLASS1

[root @ localhost Desktop] # study mv/WESTOS_class [2] _linux {1.. 6} CLASS2

[root @ localhost Desktop] # cp/etc/* [[: alpha:] [: digit:]] *. Conf confdir
  • Related