Home / Posts / Linux Operating System

Linux Operating System

Linux is an operating system like windows. An operating system is software that manages all of the hardware resources associated with your desktop or laptop. Operating system communicates between hardware and software of your PC/Laptop. Linux is a clone of UNIX.

Linux is an idea of Linus Torvalds, he worked on unix and has an idea need to improve on unix. But his idea was rejected by the unix team. But he continuously work on it and have a thought to launch os with changes.  So Linus devised a Kernel named Linux in 1991.  Later he collaborated with other programmers of MIT and started Linux applications to appear. So around 1991, a working Linux operating system with some applications was officially launched and this was the start of one of the most loved and open-source OS options available today.

  1. The main advantage of Linux was that programmers were able to use the Linux Kernel in order to design their own custom operating systems.
  2. Now, Linux is one of most popular and widely used Kernel, and it is the backbone of popular operating systems like Debian, Knoppix, Ubuntu, and Fedora.

UNIX is called the mother of operating systems which laid out the foundation to Linux. Unix is designed mainly for mainframes and is in enterprises and universities .While Linux is fast becoming a household name for computer users , developers and server environment. You may have to pay for a Unix kernel while in Linux it is free

Unix and linux commands are similar. So learning Linux is same as Unix.

The Linux operating system contains :

  1. Boot Loader: The software that manages the boot process of your computer. For most users, this will simply be a splash screen that pops up and eventually goes away to boot into the operating system.
  2. Kernel : This is the one piece of the whole that is actually called “Linux”. The kernel is the core of the system and manages the CPU, memory, and peripheral devices. The kernel is the “lowest” level of the OS.
  3. Daemons : These are back ground services like printing, sound, scheduling, etc hat either start up during boot, or after you log into the desktop.
  4. Shell : This is a command line for linux. A shell is command process that allows you to control the computer via commands typed into a text interface.
  5. Graphical Server: This is sub system, that displays the graphics on your monitor. It is commonly referred to as the X server or just “X”.
  6. Desktop Environment : This is the piece of the puzzle that the users actually interact with. There are many desktop environments to choose from (Unity, GNOME, Cinnamon, Enlightenment, KDE, XFCE, etc). Each desktop environment includes built-in applications (such as file managers, configuration tools, web browsers, games, etc).
  7. Applications: Desktop environments do not offer the full array of apps. Just like Windows and Mac, Linux offers thousands upon thousands of high-quality software titles that can be easily found and installed.

Installation of Linux: Linux offers one of the easiest installations of all operating systems. Linux offer what is called a Live distribution – which means you run the operating system from either a CD/DVD or USB flash drive without making any changes to your hard drive. You get the full functionality without having to commit to the installation. Once you’ve tried it out, and decided you wanted to use it, you simply double-click the “Install” icon and walk through the simple installation wizard.

 

Basic Linux Commands for Beginner:

The Linux can be classified as :

  1. File Handling
  2. Text Processing
  3. Process management
  4. System management
  5. Network
  6. File systems
  7. Advanced commands
  8. Archival

By using man command in Linux we can learn.

Man <command name> – it gives the use of the given command.

Command – help -> also gives the usage of the command.

 

File handling Commands in Linux:

File handling Commands

Sno   Command name                Description

  1.    ls                                     It display directory list

 

  1.    ls -al                                Formatted listing with hidden files

 

  1.    ls  -lt                               Sorting the Formatted listing by time modification

 

  1.    cd <dir name>              Change directory to dir

 

  1.    cd                                  Change to home directory

 

  1.    pwd                               Show current working directory

 

  1.    mkdir dir                        Creating a directory dir

 

  1.    cat >file                               Places the standard input into the file

 

  1.    more file                         Output the contents of the file

 

  1.   head file                         Output the first 10 lines of the file

 

  1.  tail file                            Output the last 10 lines of the file

 

  1.  tail -f file                          Output the contents of file as it grows,starting with the last 10 lines

 

  1.   touch file                        Create or update file

 

  1.  rm  file                              Deleting the file

 

  1.  rm  -r dir                           Deleting the directory

 

  1.  rm  -f file                         Force to remove the file

 

  1.  rm  -rf dir                         Force to remove the directory dir

 

  1.   cp file1 file2                   Copy the contents of file1 to file2

 

  1.  cp -r dir1 dir2                     Copy dir1 to dir2;create dir2 if not present

 

  1.  ln -s file link                    Create a link for file with symbol.

 

  1.  mv  file1 file2                   Rename or move file1 to file2,if file2 is an existing directory

 

Linux is a clone of UNIX, the multi-user operating system which can be accessed by many users simultaneously. Linux can also be used in mainframes and servers without any modifications.

Linux divides authorization into 2 levels

  • Ownership
  • Permission

So linux is very powerful and secure.

Ownership: Owner ship can be divided into three types group, other and user.

Group Ownership: A group has multiple users to handle files. All users belonging to a group will have the same access permissions to the file. Instead of manually assigning permissions to each user, you could add all users to a group, and assign group permission to file such that only this group members and no one else can read or modify the files.

User ownership:  A man/woman who is created a file is the user/owner of the file. A user is the owner of the file.  

Others: Other user means the person who is not belongs to group or user. Owner has set permissions for the others.

 

Permission in Linux :

Permissions are three types read, write and execute.

r = read permission
w = write permission
x = execute permission
 = no permission

 

Number Permission Symbol
0 No Permission
1 Execute –x
2 Write -w-
3 Execute + Write -wx
4 Read r–
5 Read + Execute r-x
6 Read +Write rw-
7 Read + Write +Execute rwx

File permission commands in Linux:

10 bit format from ‘ls ­l’ command

 

1 2 3 4 5 6 7 8 9 10
File type Owner Group Others

See the below example:

drwxrw­r­­    means owner has all three permissions

                      group has read and write

                      others have only read permission

read permission – 4

write – 2

execute ­1

read, write, and execute permission are 7 (4+2+1).

  1. rwxrw­r­­  = 764

     673    =   rw­rwx­wx

Process management Linux commands:

  1.    ps                                  To display the currently working processes
  2.    top                                  Display all running process
  3.    kill pid                             Kill the process with given pid
  4.    killall proc                       Kill all the process named proc
  5.     pkill pattern                   Will kill all processes matching the pattern
  6.    bg                                   Make fore ground process into back ground
  7.    fg                                    Brings the most recent job to foreground
  8.    fg n                                 Brings job n to the foreground here n is the job id

 

About Santosh Kumar Gadagamma

I'm Santosh Gadagamma, an Experienced Software Engineer passionate about sharing knowledge in technologies like Java, C/C++, DBMS/RDBMS, Bootstrap, Big Data, Javascript, Android, Spring, Hibernate, Struts, and all levels of software design, development, deployment, and maintenance. I believe computers are essential for the world's functioning, and I'm committed to helping others learn the skills they need to succeed in tech. My website is a valuable learning tool to help you reach greater heights in your education and career, and I believe that education has no end points.

Check Also

Google Keyword Planner

How to Use Google Key Word Planner

Google Keyword Planner is a free tool provided by Google Ads to help businesses and …