Introduction to UNIX and Electronic Mail

 

 

 

G. P. S. Raghava

 

Bioinformatics Centre

Institute of Microbial Technology

Sector 39A, Chandigarh

 

 

 

 

 

 

 

UNIX is a powerful operating system. Its not user-friendly like DOS or Windows, but it is a true multi-user, multitasking operating system. There are number of reasons which suggest that learning of UNIX is very important. Few of the reasons are as follow i) UNIX carries 20 years of development and maturity; ii) UNIX was designed with communication protocol TCP/IP (Internet); iii) UNIX is very popular for Internet servers (>80%); iv) powerful versions of UNIX and UNIX software are available for free . Thus its important to learn the UNIX.

 

History of UNIX

In 1969, Ken Thompson from UC Berkeley and Dennis Ritchie from Harvard start work on operating system called Multics (Multiplexed Information and Computing Service) at Bell Telephone Laboratories (BTL). Later, this operating system was rewritten for smaller machine (a DEC). This operating system was renamed to UNIX. UNIX was developed in Basic Combined Programming Language (BCPL) which is a tool for compiler writing and systems programming. BTL was the first UNIX user who load it on computer PDP-11 for a text preparation.

 

In 1971, Thompson and Ritchie published first manual called "UNIX PROGRAMMER'S MANUAL" This manual includes over 60 commands like: cat (concatenate files); chdir (change working directory); chmod (change access mode); chown (change owner); cp (copy file); ls (list directory contents); mv (move or rename file); roff (run off text); wc (get word count); who (who is one the system). The main thing missing was pipes.

 

in 1972, Ritchie write a powerful computer language called C. At the same time, Thompson developed the pipe which is a mechanism for connecting the output of one program to the input of another. This lay the groundwork for the UNIX "toolbox" philosophy: "Write programs that do one thing and do it well. Write programs to work together. Write programs that handle text streams, because that is a universal interface."

 

in 1973, UNIX had been installed on 16 sites (all within AT&T/Western Electric); is was publicly unveiled at a conference in October--within six months the number of installations had trebled, and after a version was published in Communications of the ACM in July 1974, there was a flood of requests. Fall 1974--Thompson went to UC Berkeley to teach for a year; Bill Joy arrived there as a new graduate student. Frustrated with ed, Joy developed a more featured editor em. Something was created at BTL. It was distributed in source form. A user in the UK created something from it. Another user in California improved on both the original and the UK version. It was distributed to the community at cost. The improved version was incorporated into the next BTL release.

 

There was no way that [BTL] Patent and Licensing could control this and the system got better and more widely used all the time. The number of peoples contribute to UNIX. The users developed programs in UNIX to solve their applications. These applications which were needed commonly be peoples were included in newer versions of UNIX operating systems. Later on various vendors release their own UNIX to fit for their computer hardware . Few UNIX product are given below

 

· Sun Microsystems Solaris 2.x

· Linux (Runs on Intel, Alpha, Sparc & Mips)

· Digital Equipment DEC UNIX (formerly OSF/1)

· Digital Equipment Ultrix

· NetBSD, 386BSD & FreeBSD

· Sun Microsystems SunOS

· IBM AIX

· Silicon Graphics IRIX

· Hewllet Packard HP-UX

· SCO UNIX

 

 

 

 

Basic UNIX Commands

Here few basic command are described by learning these command user can learn more about UNIX self. UNIX is multi-user operating system, every user have an account in system in order to use the system. Before, you start to work on UNIX you need to have account on system which is created by system administrator. System administrator will create the account and give your user name and initial password (which you can change). First step to work on UNIX is to login in the system. In order to logic you should type your user name and password at prompt 'logic' and 'password:' respectively. One you logic you can use the following basic commands.

ls (List files in a directory.)

passwd (To change your password)

pine (for reading Email )

cp a1 a2 (Copy file a1 to a2).

mv a1 a2 (Move file a1 to a2)

rm a1 (Remove, or delete file a1)

cat a1 (Display/type content of file a1)

lpr a1 (Print file a1)

mkdir temp (Create a directory temp)

cd temp (Change directory. to temp)

cd .. (Change to previous dir)

cd $HOME (Goto home dir)

pwd (Show the present dir)

chmod u=rwx a1 (Change the permissions of a file a1)

man cat (Manual/help page on command cat)

man -k print (Search command for keword print)

pico a1 (Userfriendly editor pico for editing a1)

vi,ed, emacs, xemacs, joe (Few editors on UNIX )

 

Commands are shown in bold, and arguments are shown by italics. The arguments will very according to user requirement. To learn more about any command use man command.

 

 

Similarity in DOS and UNIX commands

 

It has been observed that most of the users first learn the DOS/Windows than they start to learn UNIX. Here, few similarity in command is given below which will help the DOS users in understanding UNIX. However DOS and UNIX system commands that have similar purposes in both operating environments-not identical behavior, to be sure, but close enough for the commands to be considered almost equivalent. Fundamental differences between the design philosophies and capabilities of the two operating systems

preclude precise functional equivalence

 

The DOS and UNIX directory-related commands are very similar. The primary difference is that the DOS MKDIR and RMDIR commands can deal with only a single directory

name for each invocation. While UNIX can handle multiple directories. CD command serves the purposes of changing directory in both DOS and UNIX. Several other DOS commands have identical names and purposes as their UNIX namesakes, but not quite the same operation.

 

The following examples describe the differences you should be aware of. The DOS DATE command allows you to set and read the system date value. A separate TIME command deals with system time values. The UNIX date command combines both the system date and time functions into one program. Issuing a date command without any arguments produces a fixed-length string that contains date and time information in an abbreviated form. The DOS SORT command is a simplistic version of the UNIX sort command. Both help you order text in one or more files, but the DOS version is limited in its ability to isolate text strings in portions of a line in a file and in its ability to handle patterns rather than fixed strings.

 

Other commands have different names in the two operating environments but do approximately the same job. For example FIND command of DOS, which is similar to the UNIX grep command. These commands help you find text in a file or in a group of files.

 

 

More about UNIX

Shell: it provide the interface between user and operating system. It listens to user and give you all the answers. few important features of the UNIX shell are i) it is programmable ii) have many internal commands iii) and runs for you all external commands iv) There are many shells like: sh, csh, bash, tcsh, ksh, jsh v) it have pipes & I/O redirection

 

Kernel & Daemons: It serve as the traffic cop - controls all system resources such as CPU time, memory, disk space. You are never alone on the system, daemons is always with you. It allow to run many processes concurrently. It provide protection from other users. It also allow to run jobs in background.

 

File System: The UNIX file system is case sensitive. Filenames can be long, with spaces and optional extensions. Basically it is the regular tree structure we know from DOS and Mac UNIX keeps track of files through Inodes. The file system maintains access permissions for each file

 

X-windows System: This system provide much more then a graphical user interface to UNIX like i) communication system between different systems ii) neutral of vendor and architecture iii) framework for multi-tasking environment

 

UNIX Networking: As a multi-user system, UNIX provide both communication between users on the system and communication with users on other machines. it is the first system to generalize communication tools and protocols for all uses.

 

 

Electronic mail on UNIX

 

In simple words electronic mail (Email) is an ability to send the messages to another person using a compute. One can see the Email as combination of answering and fax machine. There are number of reasons Email have superiority over other means of communications like i) allow to exchange software/files; ii) allow to edit document received iii) can be used from any where any time if your computer is on network or you have computer, mode and phone line.

UNIX is a multi-user operating system which allow user to communicate to each other either by using talk command (live discussion) or by mail command. Mail command allow user to send the message to other users on same system. One of the popular package which allow to exchange mail/files between computers is UUCP (UNIX to UNIX copy program). UUCP is a powerful and cost effective package for electronic mail. If your computer is on Internet than Simple Mail Transfer Protocol (SMTP) can be used to exchange the mail.

 

There are number of internal and external software package which allow user to send Email. Operating system UNIX and VMS have mail utility to read and send the Email. On Windows netscape, Pegasus, Outlook can be used for Email. PonyExpresso and Hotmail are web-based/Java programs to read and send the Email. There are menu driven programs like pine, eudora, elm etc., which can loaded on various computers.