Advertisement
K_Wall_24

Linux Notes

Apr 13th, 2013
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.52 KB | None | 0 0
  1. Basic
  2. cd - change directory
  3. chmod - change access permission- r=4 w=2 x=1. U G O. 777 means Users, groups and others have all permissions.
  4. clear - clears terminal screen
  5. comm - compare two sorted files line by line
  6. cp - copy one or more files to another location ie. cp file1 dir2
  7. cal - display calendar
  8. dir - briefly list directory contents
  9. date - display or change the date & time
  10. ftp - change to binary mode (bin) and hash (hash) to see download bar. Then navigate to directory using cd, then get file using GET command (or mget to get multiple)
  11. ifconfig - configure a network interface
  12. man - help manual
  13. mkdir - create folder
  14. mv - move or rename files
  15. passwd - modify a user password
  16. rm - remove files
  17. rmdir - removes a directory, rmdir –r removes a directory with files in
  18. touch - change file timestamps/also creates a file and timestamps it
  19. tar - tape archiver
  20.  
  21. COMMANDS:
  22. # Week 1 #
  23. ps –ef | wc –l
  24. rpm –qa | wc –l
  25. pwd
  26. ls –ail
  27. ls –i
  28. # Week 2 #
  29. man who
  30. > - redirect STDOUT to file
  31. >> - redirect STDOUT, and append data to EOF
  32. < - redirect STDIN from file
  33. echo $PATH
  34. mount -t iso9660 -r /dev/cdrom /mnt/cdrom
  35. umount /mnt/cdrom
  36. chmod [value] [filename]
  37. chown
  38. chgrp
  39. # Week 6 #
  40. ftp [site]
  41. bin
  42. hash
  43. get/mget
  44.  
  45. ## Vi Commands ##
  46. dd - delete entire line
  47. 4dd - delete 4 lines
  48. yy - copy lines into buffer
  49. 4yy - copy 4 lines
  50. p - paste buffer below current line
  51. P - paste buffer above current line
  52. x - delete character at cursor
  53. 5x - delete 5 characters at cursor
  54. ZZ - save file and quit from command mode
  55. b3yy - copy 3 lines to buffer "b"
  56. bp - paste the "b" buffer
  57. q! - quit without saving
  58. / - search
  59. /abcd - search for the first occurence of abcd
  60. set - show vi environment variables.
  61. Text Mode
  62. i - insert @ cursor
  63. a - append to right of cursor
  64. A - append to end of line
  65. o - open new line before cursor
  66. O - open new line after cursor
  67. R - replace characters at cursor
  68.  
  69. # Week 7 #
  70. head [-num of lines] - show first 10 lines of file
  71. tail [-num of lines] - show last 10 lines
  72.  
  73. # Week 8 #
  74. GREP
  75. UNIQ - removes dupe lines from a sorted file
  76. COMM - compares two sorted files line by line
  77. DIFF - find the difference between two files
  78. SED - Stream editor, basic text transformations
  79.  
  80. # Week 11 #
  81. bash
  82. sh
  83. csh
  84. telinit q
  85. startx
  86. mail [user]
  87.  
  88. # Week 13 #
  89. umask [xXx]
  90. rpm -qa - query all
  91. rpm -qi - query information
  92. ntsysv
  93. netstat -a
  94. who -iH
  95. tar -cvf [name] [files/dirs inside] - create verbose file
  96. tar -tf [name] - display contents of tar file
  97. tar -xvf [name of tar file] - extract tar
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement