UNIXFILE
UNIXFILE
INTRODUCTION:-
UNIX is a powerful Operating System initially developed by Ken Thompson, Dennis Ritchie at
AT&T Bell laboratories in 1970. It is prevalent among scientific, engineering, and academic
institutions due to its most appreciative features like multitasking, flexibility, and many more. In
UNIX, the file system is a hierarchical structure of files and directories where users can store and
retrieve information using the files.
➢UNIX is an operating system that is a software that acts as an interface between the user and
computer h/w.
➢ Here resources mean hardware resources like the processor, the main memory, the hard disk,
i/o devices and other peripherals.
➢ In addition to being a multi-user operating system UNIX gives its users, the feeling of
working an independent computer system. UNIX also provides communication facility with
other users who are connected to the system either directly or indirectly via certain sort of
networking.
• Multitasking
• Multi-user
• Portability
• File Security and Protection
• Command Structure
• Communication
• Open Source
• Accounting
• UNIX Tools and Utilities
Layer-1: Hardware -
This layer of UNIX consists of all hardware-related information in the UNIX environment.
Layer-2: Kernel -
The core of the operating system that's liable for maintaining the full functionality is named the
kernel. The kernel of UNIX runs on the particular machine hardware and interacts with the
hardware effectively.
The Shell is an interpreter that interprets the command submitted by the user at the terminal, and
calls the program you simply want.
It is the outermost layer that executes the given external applications. UNIX distributions
typically come with several useful applications programs as standard. For Example: emacs
editor, StarOffice, xv image viewer, g++ compiler etc.
1. External commands
2. Internal commands
1. External commands:
A command with an independent existence in the form of a separate file is called an external
command.
Ex: cat and ls . these are independently existed in a directory called the / bin directory . When
external commands and given the shell reaches these command files with the help of ‘PATH’
variable.
2. Internal commands:
A command that does not have an independent existence is called an internal command.
Ex. Echo,mkdir,cd,etc; The routines for internal commands will be a part of another program (or)
routine. Ex. Echo command is internal command will be a part of another program(or) routine is
the part of shell’s routine “sh”.
3. cd - Change Directory
Purpose: Changes the current working directory to the specified directory.
Command: cd target_directory
Command: vi file_name.txt
Save the File: Save and exit the editor (in nano, press CTRL + X, then press Y to
confirm, and Enter to save).
Make the Script Executable: Run the following command to make the script
executable:
chmod +x date.sh