Command used in Linux. part -1

# adduser or useradd --- To add new user

# cd.. --- To go back one state

# cd / --- To go under the root

# cd --- To change directory

# cd ~ --- To go home directory

# cd ~ <user_name> --- go to user home directory

# cd - ___ go to previous working directory

# cp --- Copy a file from one location to another

# cal --- Show the calendar of the month

# cat --- To show a specific file on the screen.

# chkconfig --- Updates and queries run level information for system services

# clear --- To delete all the previous content of the shell. Same command is CTRL –l

# crontab –l --- List schedule jobs for current user

# crontab -e --- create a new crontab

# crontab -r --- Remove a cron table and cancel all schedule jobs

# cp -p --- To copy file from source to destination preserving same mood

# cp –i --- To be prompted before overwrite it

# date --- To show the current date and time

# df –h --- To show the partition status

# df –hT --- To show the partition status details

# echo --- Display text on the screen. Mostly used when writing shell command.

# exit --- Logout from the current session.

# free --- To shows free, total and swap memory information in bytes

# free –t --- To shows total memory used and available to use in bytes

# find --- To search files, strings and directories

# ftp --- To connect remote ftp host

# fdisk --- To know the partition of the current directory

# fdisk –l --- To show the details of partition of the current directory

# groups --- Show groups you are in

# grep <search_string> ---- Can find a specific string by this command

# grep –w ---- Shows all the lines that do not matched the searched string

# grep –c ---- Display only the count of matching lines

# grep –m --- Show the matching line and its number

# grep –i --- Match both (upper and lower case)

# grep –l --- Shows just the name of the file with the string

# head --- Display the first few lines of the text file.

# history --- To show all previous command


Post a Comment