LINUX Technical Interview Questions

What is Linux?

Linux is a type of operating software. It is a UNIX-like operating software, which means that it has developed from UNIX and follows the "Unix philosophy". This includes concepts such as the use of plain text for storing data, as well as a hierarchical file system and the use of a large number of software tools. It also treats devices and certain types of inter-process communication (IPC) as files.

Linux is open source, which means that it is free to use and modify depending upon the preference of the user. Linux was first released by Linus Torvalds on September 17, 1991, and is in fact named after him.

What is the difference between UNIX and LINUX?

UNIX is an operating system that was designed in the 1970s at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and others, thus making it older than LINUX, which was developed by Linus Torvalds in 1991. Another major difference between the two is that UNIX is a proprietary software developed, maintained and updated by AT&T, whereas LINUX is an open source software that is free to use, develop and modify.

UNIX

LINUX

Developed in the 1970s

Developed in 1991

Developed by Ken Thompson, Dennis Ritchie, and others at Bell Labs

Originally developed by Linus Torvalds

Developed, maintained and updated by AT&T developers

Open source, hence Developed, maintained and updated by the community, and overseen by Linus Torvalds

Proprietary software

Open source, i.e. free to use

Source code not available

Source code freely available

Commonly used in internet servers, workstations and PCs by Solaris, Intel, HP, etc.

Widely used for computer hardware and software, game development, tablet PCS, mainframes, etc.

Works primarily on Command Line Interface

Works on both Command Line Interface and Graphical User Interface (GUI)

Not as flexible as Linux

Quite Flexible

Less compatible with different types of hardware

More compatible with different types of hardware

Supports fewer File systems

Supports more File systems

Installation requires strict and well-defined hardware machinery and works only on specific CPU machines.

Is fluid and agile, hence can be installed and executed on almost anything that has a processor.

Not portable

Is portable and can be executed in different Hard Drives.

Different Versions of Unix are: AIS, HP-UX, BSD, Iris, etc.

Different Versions of Linux are: Ubuntu, Debian, OpenSuse, Redhat, Solaris, etc.

The Filesystems supported by Unix are as follows: zfs, js, hfx, gps, xfs, gps, xfs, vxfs.

The Filesystems supported by Linux are as follows: xfs, ramfs, nfs, vfat, cramfsm ext3, ext4, ext2, ext1, ufs, autofs, devpts, ntfs

What is BASH?

BASH is short for Bourne Again Shell. It is a shell that was designed for Linux. It is designed after the Bourne shell, a shell for UNIX. BASH has also often been called a superset of the Bourne shell. Hence, BASH is actually compatible with the Bourne shell, that is, the commands that work in sh, also work in bash.

What is Linux Kernel?

A kernel is the central module of an operating system (OS). Each and every OS has a kernel. The Linux is a type of kernel, around which the operating system has been created.

As a kernel, it loads first and simultaneously remains in main memory. It is responsible for providing all the essential services that are required by other parts of the operating system and applications.

The Linux Kernel is designed based on the UNIX kernel. It is highly versatile and can be deployed on both traditional computer systems such as personal computers and servers, as well as on devices such as routers, wireless access points, PBXes, set-top boxes, FTA receivers, smart TVs, PVRs and NAS appliances. In fact, the Android operating system is based on the Linux Kernel.

Compare Linux and Windows

Linux and Windows are two different types of Operating Systems. Each one has its own set of advantages and disadvantages.

Linux

Windows

Developed

Developed by Microsoft Inc.

Open Source Software

Proprietary Software

Offers high level of customization

Offers minimal to none level of customization

Higher security features

Lower security features that cannot be modified

Supports the standard POSIX systemcall interface

Only provides for POSIX using an emulation layer

The Linux ABI supports the ELF file format

The Windows kernel supports the PE file format

Supports Ext2, Ext3, Ext4, Jfs, ReiserFS, Xfs, Btrfs, FAT, FAT32, NTFS

Supports FAT, FAT32, NTFS, exFAT

Default user interface is Gnome or KDE

Default user interface is Graphical (Windows Aero)

BASH (Bourne Again SHell) is the Linux default shell. It can support multiple command interpreters.

Windows uses a command shell and each version of Windows has a single command interpreter with dos-like commands, recently there is the addition of the optional PowerShell that uses more Unix-like commands.

Part of the GNU OS family

Part of the DOS family

Programmed in C

Programmed in Assembly, C, C++

What is LILO?

LILO stands for Linux Loader. It acts as a boot loader for Linux, which basically means that it loads Linux into the memory and then starts the Operating System. It also manages dual boot.

When a computer starts up, the BIOS first checks things and then hands over control to the Master Boot Record (MBR). This is where LILO is stored. When installed in the MBR, LILO allows for fast boot up of Linux. LILO is also customizable thus allowing the user to modify the default configuration as required.

However, LILO may be hampered by the fact that most computers do not allow for the modification of MBR thus rendering LILO as useless. There are alternative approaches to this, however, they usually take longer.

Some other boot loaders that can act as an alternative to LILO are LOADLIN (LOAD LINux) and GRUB (GRand Unified Bootloader).

What is a swap space?

It often happens that the computer runs out of RAM. Basically, this means that there is not enough memory in the RAM to hold all the programs that are running at the time. This would normally lead to the slowing down of the computer, and/or cause some programs to crash and stop working.

However, Linux has a word around for that. It is Swap Space. Swap space is a space on a hard disk used can be used to store memory that would normally be held in the RAM. This space actually works as the virtual memory extension of a computer's real memory (RAM).

The benefit of swap space is that it allows the computer to have more RAM than it actually does.

What are the basic components of Linux?

List most other operating systems, Linux includes the following basic components:

  • Kernel – Maintains all the vital abstractions of the operating system, as well as the virtual memory and processes.
  • System libraries – a typical set of functions through which applications can interrelate through the kernel.
  • Shells and GUIs – Interface to the kernel. Takes commands from the user and executes kernel's functions.
  • System utilities – System programs that execute individual, particular and specialized managing tasks
  • Application program – Various applications that can be used for various different tasks by the user
Does it help for a Linux system to have multiple desktop environments installed?

Having only one or multiple desktop environments installed is primarily a personal choice of the user. It does not really matter other than to the user’s personal preference. Some users may prefer to have only one environment installed, such as KDE or Gnome. Whereas, others might prefer to load more than one in order to take advantage of the fact that the system allows switching from one environment to another. However, it should be noted that some programs may work on one environment and may not work on the other.

Add new comment

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.