• About WordPress
    • WordPress.org
    • Documentation
    • Support
    • Feedback
  • Log In
  • Register
  • Home
  • Courses
  • Past Paper
  • FYP
  • Interview Questions
  • University Events
  • Contact
  • Quiz & Assignment
Cuitutorial
  • Home
  • Courses
  • Past Paper
  • FYP
  • Interview Questions
  • University Events
  • Contact
  • Quiz & Assignment

Operating System

Home » Blog » Linux Commands

Linux Commands

  • Posted by saqib
  • Categories Operating System
  • Date November 1, 2022
  • Comments 8 comments

Command Line Interface

The Command Line Interface (CLI), is a non-graphical, text-based interface to the computer system, where the user types in a command and the computer then successfully executes it. The Terminal is the platform or the IDE that provides the command line interface (CLI) environment to the user. The CLI terminal accepts the commands that the user types and passes to a shell. The shell then receives and interprets what the user has typed into the instructions that can be executed by the OS (Operating System). If the output is produced by the specific command, then this text is displayed in the terminal. If any of the problems with the commands are found, then some error message is displayed.

We can open the terminal by typing Ctrl + Alt + T short-key or by right-clicking the mouse and selecting the Open New Terminal option. The terminal window looks like given below

 

Basic syntax of Linux Commands

A command is an instruction given by a user telling a computer to do something, such a run a single program or a group of linked programs. Commands are generally issued by typing them in at the command line (i.e., the all-text display mode) and then pressing the ENTER key, which passes them to the shell.

A shell is a program that reads commands that are typed on a keyboard and then executes (i.e., runs) them. Shells are the most basic method for a user to interact with the system.

 

Options and Arguments

This brings us to a very important point about how most commands work. Commands are often followed by one or more options that modify their behavior, and further, by one or more arguments, the items upon which the command acts. So most commands look kind of like this:

Most commands use options consisting of a single character preceded by a dash, for example, “-l”, but many commands, including those from the GNU Project, also support long options, consisting of a word preceded by two dashes. Also, many commands allow multiple short options to be strung together.

 

Command History

Most Linux distributions remember the last 500 commands by default. Press the down-arrow key and the previous command disappears.

Some Basic Linux Commands

 

Date Command:

This command is used to display the current data and time.

Syntax:

$date

$date +%ch

Options:

a = Abbreviated weekday.

A = Full weekday.

b = Abbreviated month.

B = Full month.

c = Current day and time.

C = Display the century as a decimal number.

d = Day of the month.

D = Day in “mm/dd/yy” format

h = Abbreviated month day.

H = Display the hour.

L = Day of the year.

m = Month of the year.

M = Minute.

P = Display AM or PM

S = Seconds

T = HH:MM:SS format

u = Week of the year.

y = Display the year in 2 digit.

Y = Display the full year.

Z = Time zone

To change the format:

Syntax:

$date “+%H-%M-%S”

 

 

Calendar Command: This command is used to display the calendar of the year or the particular month of calendar

Syntax :

$cal

 

To see the current amount of free space on your disk drives, enter df:

 

Likewise, to display the amount of free memory, enter the free

 

We can end a terminal session by either closing the terminal emulator window, or by entering the exit command at the shell prompt

 

’who’ Command: It is used to display who are the users connected to our computer

Syntax:

$who – options

Options : –

H–Display the output with headers

b–Display the last booting date or time or when the system was lastly rebooted

’who am i’ Command: Display the details of the current working

Syntax:

$who am i

 

CLEAR’ Command: It is used to clear the screen.

Syntax:

$clear

 

MAN Command: It help us to know about the particular command and its options & It

is like “help” command in windows .

Syntax:

$man <command name>

Activities:

  1. In GUI open the Libre Office writer tool create a document that contains information about your favorite place. Try the following short- keys while formatting the document

 

Related Links  to Operating System topics

Operating system Course content

  • Operating System-Functions and History
  • Generations of Operating System
  • Functions of an Operating System
  • Components of Operating System
  • Types of Operating System
  • Services of Operating System
  • Properties of Operating System
  • Processes in Operating System
  • Process Scheduling in Operating System

Lab Practice Task

  • Introduction to Linux Ubunto
  • Installation with virtual Box
  • Writing Linux Commands
  • Navigation in File System and Directory Management in Ubunto using CLI
  • File Handling and I/O Redirection In Ubunto
  • File Access Permission in Linux
  • Text Processing Tools and Basic System Configuration Tools in Linux
  • Package Management in Linux
  • How to manage processes in Linux
  • Compiling and Executing C++ programs in Linux
  • System Calls
  • Introduction To Shell Programming 

 

#Operating System complete course #Operating System past paper #Operating System-project #Computer Science all courses  #operating system Problem with source code#University Past Paper #Programming language #Question paper #old paper #Operating System-Functions and History #Generations of Operating System #Functions of an Operating System #Components of Operating System #Types of Operating System #Services of Operating System #Properties of Operating System #Processes in Operating System #Process Scheduling in Operating System #Introduction to Linux Ubunto #Installation with virtual Box #Writing Linux Commands #Navigation in File System and Directory Management in Ubunto using CLI #File Handling and I/O Redirection In Ubunto #File Access Permission in Linux #Text Processing Tools and Basic System Configuration Tools in Linux #Package Management in Linux #How to manage processes in Linux #Compiling and Executing C++ programs in Linux #System Calls #Introduction To Shell Programming

  • Share:
author avatar
saqib

Previous post

How to install Ubunto on VMWare Workstation 15 in Window 10
November 1, 2022

Next post

File System and Directory Management in Ubunto using CLI
November 1, 2022

You may also like

Aging in operating system
6 January, 2023

Aging in operating system In Operating systems, Aging is a scheduling technique used to avoid Starvation. Fixed priority scheduling is a scheduling discipline in which tasks queued for utilizing a system resource is assigned each priority. A task with a …

Starvation in operating system
6 January, 2023

Starvation in operating system It is a problem when the low-priority process gets jammed for a long duration of time because of high-priority requests being executed. A stream of high-priority requests stops the low-priority process from obtaining the processor or …

Dead Lock in operating system
3 January, 2023

Dead Lock in operating system A Deadlock is a situation where each of the computer process waits for a resource which is being assigned to some another process. In this situation, none of the process gets executed since the resource …

    8 Comments

Leave A Reply Cancel reply

You must be logged in to post a comment.

admin@cuitutorial.com
Facebook-f Twitter Youtube Linkedin Instagram Stack-overflow Pinterest Github Quora Whatsapp
Courses
  • All Courses
  • Past Paper
  • Final year projects
  • Interview Questions
  • Contact
Important Pages
  • Privacy Policy
  • Terms of Service
  • Cookie Policy
Links
  • University Events
  • Team
Education & learning platform for All Computer science subjects
Final year projects
Past Paper
Interview questions
Programming, C/C++, Asp.net/MVC. Android, MySql, Jquery, Ajax, javascript, Php, Html5, Bootstrap4.
NTS, GAT, PPSC, FPSC

Copyright © 2021 | Cuitutorial