LINUX Technical Interview Questions For Freshers

What is Linux?  Linux is an operating system based on UNIX, and was first introduced by Linus Torvalds. It is based on the Linux Kernel, a...

What is Linux? 
Linux is an operating system based on UNIX, and was first introduced by Linus Torvalds. It is based on the Linux Kernel, and can run on different hardware platforms manufactured by Intel, MIPS, HP, IBM, SPARC and Motorola. Another popular element in Linux is its mascot, a penguin figure named Tux.

What is the difference between UNIX and LINUX? 
Unix originally began as a propriety operating system from Bell Laboratories, which later on spawned into different commercial versions. On the other hand, Linux is free, open source and intended as a non-propriety operating system for the masses.

What is BASH? 
BASH is short for Bourne Again SHell. It was written by Steve Bourne as a replacement to the original Bourne Shell (represented by /bin/sh). It combines all the features from the original version of Bourne Shell, plus additional functions to make it easier and more convenient to use. It has since been adapted as the default shell for most systems running Linux.

What is Linux Kernel? 
The Linux Kernel is a low-level systems software whose main role is to manage hardware resources for the user. It is also used to provide an interface for user-level interaction.

What is LILO?
 LILO is a boot loader for Linux. It is used mainly to load the Linux operating system into main memory so that it can begin its operations

 What the commond used for List the contents of your home directory , current directory and ALL subdirectories 
A word List formed a command LS that show contents of home directory like below
$ ls ~
To show everything in a vertical column used like below
$ ls -al
it will show like below
drwxr-xr-x 5 root root 3090 Jun 19 20:39 boot/
drwxr-xr-x 8 root root 4509 Jul 21 09:56 dev/
drwxr-xr-x 94 root root 4096 Jul 12 10:35 etc/
show directories in the current directory
$ ls -d */
show ALL subdirectories
$ ls *

How you will Create new folder / directories and how to remove file and folder in linux
mkdir
Create new folder or directory, if they do not already exist already
syntex like below
mkdir [Options] directories
OPTIONS
-m, --mode=MODE set permission mode (as in chmod), not rwxrwxrwx - umask
-p, --parents no error if existing, make parent folder as needed
mkdir creates the standard entries . (dot) for the current folder
and .. (dot dot) for its parent
cd used for Change Directory
rm To Remove files

rmdir To Remove folder(s)

What the command used for Search file or files for specific text? 
grep command used for files for specific text.

What is the difference between TCP and UDP? 
The basic difference is that TCP establishes a connection before sending data and this allows it to control the dataflow and guarantee that all packets get delivered. UDP simply chucks datagrams onto the wire and if some get lost or arrive in bad order there’s no way to request a resend. However UDP has low network overhead so some services such as DNS resolution, SNMP, DHCP, RIP and VOIP use UDP for its speed and any errors are usually dealt with on the application layer rather than network layer

 How does DNS resolution work? 
A client application requests an IP address from the name server usually by connecting to UDP port 53. The name server will attempt to resolve the FQDN based on its resolver library, which may contain authoritative information about the host requested or cached data about that name from an earlier query. If the name server does not already have the answer, it will turn to root name servers to determine the authoritative for the FQDN in question. Then, with that information, it will query the authoritative name servers for that name to determine the IP address.

What is an MX record? 
MX record numerically ranks the mail servers you would prefer to receive email for a domain. The MX record with the lowest number is preferred over the others, but you can set multiple email servers with the same value for simple load balancing

Describe Linux boot-up sequence 
BIOS reads the MBR where Boot Loader sits, Boot Loader reads Kernel into memory, Kernel starts Init process, Init reads inittab, executes rc.sysinit, the rc script than starts services to reach the default run level and once this is done the last thing that gets run is the rc.local script.

 What is an INODE? 
All files have its description stored in a structure called ‘inode’. The inode contains info about the file-size, access and modification time, permission and so on. In addition to descriptions about the file, the inode contains pointers to the data blocks of the file.

What does /etc/skell directory contains? 
The /etc/skel directory contains files and directories that are automatically copied over to a new user's home directory when such user is created by the useradd or adduser command.

What is a swap space? 
A swap space is a certain amount of space used by Linux to temporarily hold some programs that are running concurrently. This happens when RAM does not have enough memory to hold all programs that are executing.

What are the basic components of Linux? 
Just like any other typical operating system, Linux has all of these components: kernel, shells and GUIs, system utilities, and application program. What makes Linux advantageous over other operating system is that every aspect comes with additional features and all codes for these are downloadable for free.

What are The steps to remove the swap file? 
Firstly disable the swap file by “swapoff” command.
Remove Swap file entry from /etc/fstab file.
Now remove the swap file by “rm” command.

How we will check free space on drive /dev/sda with parted command? 
#parted /dev/sda
print

What are the process states in Unix? 
Running : The process is either running or it is ready to run .
Waiting : The process is waiting for an event or for a resource.
Stopped : The process has been stopped, usually by receiving a signal.
Zombie : The process is dead but have not been removed from the process table

What can you type at a command line to determine which shell you are using? 
echo $SHELL

What is CLI? 
CLI is short for Command Line Interface. This interface allows user to type declarative commands to instruct the computer to perform operations. CLI offers an advantage in that there is greater flexibility. However, other users who are already accustom with using GUI find it difficult to remember commands including attributes that come with it.

What is GUI? 
GUI, or Graphical User Interface, makes use of images and icons that users click and manipulate as a way of communicating with the computer. Instead of having to remember and type commands, the use of graphical elements makes it easier to interact with the system, as well as adding more attraction through images, icons and colors

What are filenames that are preceded by a dot? 
In general, filenames that are preceded by a dot are hidden files. These files can be configuration files that hold important data or setup info. Setting these files as hidden makes it less likely to be accidentally deleted. 

Explain virtual desktop.
This serves as an alternative to minimizing and maximizing different windows on the current desktop. Using virtual desktops, each desktop is a clean slate where you can open one or more programs. Rather than minimizing/restoring all those programs as needed, you can simply shuffle between virtual desktops with programs intact in each one.

What does a nameless (empty) directory represent?
This empty directory name serves as the nameless base of the Linux file system. This serves as an attachment for all other directories, files, drives and devices.

What is the pwd command? 
The pwd command is short for print working directory command. It’s counterpart in DOS is the cd command, and is used to display the current location in the directory tree.

What are the kinds of permissions under Linux?
Here are 3 kinds of permissions under Linux:
Read: users may read the files or list the directory
Write: users may write to the file of new files to the directory
Execute: users may run the file or lookup a specific file within a directory

What is redirection? 
Redirection is the process of directing data from one output to another. It can also be used to direct an output as an input to another process.

What are the contents in /usr/local? 
It contains locally installed files. This directory actually matters in environments where files are stored on the network. Specifically, locally-installed files go to /usr/local/bin, /usr/local/lib, etc.). Another application of this directory is that it is used for software packages installed from source, or software not officially shipped with the distribution.

How do you insert comments in the command line prompt?
 Comments are created by typing the # symbol before the actual comment text. This tells the shell to completely ignore what follows. For example: “# This is just a comment that the shell will ignore.”


Related

Interview Questions 603104335283444917

Post a Comment

Follow Us

Hot in week

Recent

Comments

Side Ads

item