3.Advance Linux Commands
Component of Operating Systems
What is an Operating System? (OS)
The Hierarchical File system
telnet 172.16.22.5 or putty 172.16.22.5 in Labs.
3. mv - Rename a file. (change the name of an existing file)
5. mkdir: make (create) a new directory (folder).
7. cp: copies file(s) from source to target
8,9. rm and rmdir: rm removes file(s). rmdir removes a directory, only iff the directory is empty. Before using rmdir command check if the directory which you want to remove is empty.
10. cal: prints the calender
A very Good Beginner’s Book for reading and practice.
Files: contain information (program, data, text, document)
Vi is a display-oriented, screen editor. It has two modes of operation.
Commands to add new text:
Commands for Exiting the vi editor
:se nu <enter> : display line numbers
Moving within a LINE
SEARCHING: syntax: /string
MAKING MINOR CORRECTIONS
Making Corrections: How to delete a word / line / a range of lines.
SUBSTITUTION (REPLACE) of one string with another string
COPY and PASTE for text: For this we use single letter commands Y and P or p. i.e. YANK and PUT.
Reading and copying the contents of another existing file into the current file
/* sample.c */
$ vi sample.c
Occasionally, you may get message: file is read only. You are unable to edit file or compile a program, since the file may be corrupted). Now, You can use Recovery mode in editor.
and then verify if all lines are present in the new file.
There are 3 categories of users.
You can set access permissions for your files and directories for the different types of users.
wc: Word count program. Counts the number of words, lines and characters in a file.
bc: Arbitrary Precison Arithmatic Language
sleep: introduce delay for finite time (in seconds)
split: split a file into pieces