0% found this document useful (0 votes)
1K views16 pages

Communication Oriented Commands

The document discusses various Linux commands for communication and general purposes. Some key communication commands covered are write for online messaging, mail for offline messaging, and wall to broadcast messages to all users. General purpose commands covered include date to view the system time and date, who to see logged-on users, man for viewing command manuals, and cal to view a calendar. The document also discusses commands for printing, file redirection, arithmetic, and clearing the screen.

Uploaded by

Vijetha bhat
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1K views16 pages

Communication Oriented Commands

The document discusses various Linux commands for communication and general purposes. Some key communication commands covered are write for online messaging, mail for offline messaging, and wall to broadcast messages to all users. General purpose commands covered include date to view the system time and date, who to see logged-on users, man for viewing command manuals, and cal to view a calendar. The document also discusses commands for printing, file redirection, arithmetic, and clearing the screen.

Uploaded by

Vijetha bhat
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 16

LINUX COMMANDS:PART4

COMMUNICATION ORIENTED COMMANDS


GENERAL PURPOSE COMMANDS

04/01/2020 Bhat_ vijetha


 Linux provides the communication facility from which a user
communicate with the other users.
 The communication can be online or offline.
 In online communication , the user to whom the message was sent
must be logged on to the system.
 In offline communication ,the recipient need not be logged on the
system.
 Some of the communication oriented commands are:
Write
This online communication command lets you to write messages on
another user’s terminal.

04/01/2020 Bhatvijetha
 General format is
Write <RecipientLoginName>
<message>
^d

Mail
 This command offers offline communication.
General format is,
Mail <username>
<message>
^d

04/01/2020 Bhatvijetha
Wall
Usually this wall command (write all) command is used by the super user
to send a message to all the users who were logged on the system.
General format is,
Wall
<message>
<press [ctrl+d] at the end]
Example
$wall
Meeting at 14.00hrs
^d
The specified message “meeting 14.00hrs” will be displayed on
everyone’s terminal with a beep sound like write message .

04/01/2020 Bhatvijetha
General purpose commands

 Date
This command displays the system’s date and time.
General format is,
Date +<format>
Where <format> can be,
%H hour 00 to23
%I hour 00 to 12
%M minute 00 to 59
%S second 00 to 59
%D Date MM/DD/YY
%T Time HH:MM:SS
%w day of the week
%r time in AM/PM
%y last two digits of the year
04/01/2020 Bhatvijetha
 Who
Linux is a multi user operating system where several user can work on
the system.
This command is used to display the users who are logged on the
system currently.
General format is,

Who

The first column of the user represents the user names.


The second column represents the corresponding terminal names and
the remaining columns represents the time at which the users are
logged on.

04/01/2020 Bhatvijetha
Who am I
 This command tells you who you are.
(working on the current terminal)

General format is,


Who am I

04/01/2020 Bhatvijetha
Man
 This man command displays the syntax and details usage of
the linux command which is supplied as an argument.

 General format is,

Man <linuxcommand>

04/01/2020 Bhatvijetha
 Cal
This command will display calendar for the specified month
and year.

general format is,


Cal [<month>] <year>
Where ,month can be ranged from 1 to 12.

04/01/2020 Bhatvijetha
 Lpr
This command is used to print one or more files on the printer.
General format is,
Lpr [options] <filename> <filename2>..<filenameN>
Where options can be,
r removes files from one directory after printing.
m Mail inform you when printing is over

04/01/2020 Bhatvijetha
 Tee
This command does the operation of pipe and redirection.
It will send the output of a command into standard output as
well to specified file.

General format is,


Command |tee <filename>

The option –a can be used with the tee command which


appends the output of the specific file .
Other wise the file content will be overwritten.

04/01/2020 Bhatvijetha
 Script
This command stores login session into a specific file.
All the operations that you have done are stored on that file.
Start the login session by issuing the following command.
$script
Then do you operations and finally use the exit command to
end script.then all the operation in between script and exit
will be stored on a file named type script.

The next script command will overwrite the typescript file.

04/01/2020 Bhatvijetha
 Tput
This command with clear option can be used to clear thee
screen content.

General format is,

Tput clear
You can also use clear command for this purpose.

04/01/2020 Bhatvijetha
 Expr
This command is used to perform arithematic operations on
integers.
A white space must be used on either side of an operator.
$ x=5
$y=2
Then,
$ expr $X + $y
$ expr $x - $y

04/01/2020 Bhatvijetha
 Bc
This command is used to perform arithematic operations on
integers as well as on floats.
Type the arithematic expression in a line and press key.
Then the answer will be displayed on the next line.
After you have finished work,press control d to end up.
Example:
Add 10 and 20
$bc
10 + 20
30
Ctrl+d(to end)

04/01/2020 Bhatvijetha
Continued in part5..

04/01/2020 Bhatvijetha

You might also like