Basic Commands for Unix
Hello friends, Here I am going to explain you all the basic command for the Unix. So you can handle system or access the data through the terminal.
Commands :
>>Basic Commands
1) cal :
The cal command is used to to display the calender.
For example to check calendar you need to type cal command as follows:
2) passwd
The passwd command is used to change the password of the unix system. Every unix system will require a password for the security.
3) whoami, who, user
The who am i command is used to know the name of the user by which you are currently logged in.
The who command is used to know the name of the user who are online on connected system.
The user will display the name of the users.
>> File Management Commands<<
4) ls command
The ls command is used to list the directories and files of the current running directory with the
-l option.
As shown below example d stands for the directory and - is for the executable file like text file, image or any other format.
5) cat
The cat command is used to read the file. We can also create the file with the cat command by using > sign with it. as seen below example :
6) wc (word count) command
The wc command is used to count the number of characters, words and lines of any file.
In wc command -c for character, -w for word count and -l for line count
Syntax $wc <filename>
7) cp command
To make a copy of a file use the cp command. The basic syntax of the command is:
Syntax :
$ cp source_file destination_file
8) mv Command
The mv command is used to rename the filename
Syntax :
$ mv old_file new_file
9) rm Command
The rm command is used to remove the particular file.
It is recommended to use -i option along with rm command.
Syntax :
rm <filename>
0 comments:
Post a Comment