Linux System Administrator Interview Questions and Answers -Linux System Administrator interview questions and answers in basic level and experienced. More likely all questions are related to Linux system administration.

L inux is most used free open source operating system (OS). As an operating system, Linux is software that sits underneath all of the other software on a computer, receiving requests from those programs and relaying these requests to the computer’s hardware.
We use the term “Linux” to refer to the Linux kernel, but also the set of programs, tools, and services that are typically bundled together with the Linux kernel to provide all of the necessary components of a fully functional operating system. Some people, particularly members of the Free Software Foundation, refer to this collection as GNU/Linux, because many of the tools included are GNU components. However, not all Linux installations use GNU components as a part of their operating system. Android, for example, uses a Linux kernel but relies very little on GNU tools. Some of the most popular and mainstream Linux distributions are Arch Linux, CentOS, Debian, Fedora, Gentoo Linux, Linux Mint, Mageia, openSUSE and Ubuntu, together with commercial distributions such as Red Hat Enterprise Linux and SUSE Linux Enterprise Server. Linux was originally developed for personal computers based on the Intel x86 architecture, but has since been ported to more platforms than any other operating system. Because of the dominance of the Linux kernel-based Android OS on smartphones, Linux has the largest installed base of all general-purpose operating systems. Linux is also the leading operating system on servers and other big iron systems such as mainframe computers, and the only OS used on TOP500 supercomputers (since November 2017, having before gradually eliminated all competitors).
First Linux is released on September 17, 1991, by Linus Torvalds, a then-student at the University of Helsinki. Torvalds built Linux as a free and open source alternative to Minix, another UNIX clone that was predominantly used in academic settings. He originally intended to name it “Freax,” but the administrator of the server Torvalds used to distribute the original code named his directory “Linux” after a combination of Torvalds’ first name and the word UNIX, and the name stuck.

Linux System Administrator responsibilities:
  • The Linux system administrators are responsible for installing, configuring and maintaining the Linux servers and workstations. They are responsible for maintaining the network environment as well as the health of the network and servers.
  • The Linux system administrators need to participate in various cross training activities, so as to achieve a comfort level that supports the database. They may also be involved in training the subordinate team members in system administration and software deployment responsibilities.
  • Installing and configuring server and Creating and maintaining user accounts
  • Evaluate all documents according to system requirements and evaluate all design and perform tests on all development activities and administer all complex methodologies.
  • Develop an infrastructure to provide support to all business requirements and perform regular troubleshoot on system to resolve all issues.
  • Monitor everyday systems and evaluate availability of all server resources and perform all activities for Linux servers.
  • Configuring a secure system; it is a duty of administrator to involve tasks and decisions to run secure Linux system and maintaining data integrity. Resolve all issues across various technologies and design require enterprise servers and provide back up support. It perform tests on all new software and maintain patches for management services
  • Administrator all performance for various resources and ensure optimization for same and provide support to all applications and ensure optimal level of customer services.
  • It perform troubleshoot on all tools and maintain multiple servers and provide back up for all files and script management servers.
What is Linux system Administrator?
In IT field, Linux is a main role in computing technology, powering everything from mobile phones and personal computers/systems to supercomputers and servers. The main job of a systems administrator is to manage the operations of a computer systems. In Linux System Administrator is a person who has ‘root’ access that is ‘superuser’. It means he has privilege to access everything which includes all user accounts, all system configurations, home directories with all files therein, all files in system.

What is kernel?
A kernel is the part of the operating system that manages system resources. Kernel is responsible for controlling access to CPU, memory, disk I/O, and networking.

 What is Shell?
Shell provides user interface to the UNIX system. It take input from user and process it and send show result to user.

What is the Minix?
Minix (Mini-Unix) is the UNIX clone written by Andrew Tanenbaum at VU University, in Amsterdam when universities were no longer allowed access to the UNIX source code. MINIX also inspired the creation of the Linux kernel.

What is POSIX?
POSIX (Portable Operating System Interface) is a set of standard operating system interfaces based on the UNIX operating system. It is the standard for ensuring compatibility between UNIX versions.

What is name of first process in Linux?
‘init’ is the first process in Linux which is started by kernel and whose pid is 1.

Who initiated the GNU Project?
GNU project was initiated by Richard Stallman on 27 September 1983 at MIT. Main motive of this project was to give freedom and control in use of software's. GNU software guarantees these freedom-rights legally via its license. Users are free to run the software, share it, copy it, distribute it, study it and modify it.

What is the use of sysctl command?
 In this command the /sbin/sysctl command is used to view, set, and automate kernel settings in the /proc/sys/ directory.

Explain the procedure for re-installing Grub in Linux?
  • Download Ubuntu Installation / Live cd
  • Boot from Ubuntu Installation / Live cd - usb, burned cd etc.
  • During boot select "Try Ubuntu”, don’t select install!
  • Mount your Linux root partition
  • sudo mount /dev/sda6 /mnt (Assuming /dev/sda6 is the Linux root partition)
  • Install / reinstall grub
  • sudo grub-install --root-directory=/mnt/ /dev/sda ( where /dev/sda is your primary disk)
  • Installation finished. No error reported.
  • Reboot your system, remove bootable CD and we should have the boot menu ready when the system starts.
What is the use of DAS, NAS and SAN?
DAS: Direct Attached Storage is a block device from a disk which is physically attached to the host machine (such as /dev/sda or /dev/sda1). You must place a filesystem upon it before it can be used. There are limitations like the number of servers that can access it. Storage device, or say DAS storage has to be near to the server storage and the resources are dedicated but generally, you are not able to dedicate the hard disks to multiple computers. DAS solution is inexpensive and simple to configure. Technologies to do this include IDE, SCSI, SATA, SAS etc.
NAS: Network-attached storage is a type of dedicated file storage device that provides local-area network local area network (LAN) nodes with file-based shared storage through a standard Ethernet connection.  NAS authenticates clients and provides shared to other computers and users over a network so it requires a dedicated ip address to be accessible. NAS devices generally run an embedded operating system on simplified hardware and lack peripherals like a monitor or keyboard. Network file systems can be considered safe enough to be used in a concurrent way, the protocol implementation will take care of problems due to concurrent access to the same resource (file), normally by locking the file to a single user/requester. You can set up automatic or manual backups and file copies between the NAS and all other connected devices by using a software program. It is an easy way to provide RAID redundancy to mass amount of users, it allows users permissions, folder privileges, restricted access to documents, etc.
SAN: Storage Area Network is the storage area network which is useful for long distance storage. SAN has the particularity to be a block level storage solution that NAS doesn’t provide. It is optimized for high volume of block level data transfer. SAN is performed best when used with fiber channel medium (optical fibers, and a fiber channel switch). It provides synchronous replication and it is an architecture to attach remote storage to make it appear as though it is locally attached. There are highly scalable, both from a capacity and performance perspective. If offers a centralized storage management. It is a solution for terabytes of storage and multiple simultaneous access to files e.g. streaming audio/video and it allows virtual environments, cloud computing, etc.

What is SAS?
SAS: Serial Attacched SCSI This allows to create entire SANs as SAS supports routing and addressing.

What is Initrd?
Initrd means initial ram disk, which contains the temporary root filesystem and necessary modules which helps in mounting the real root filesystem in read mode only.

What is Bootloader?
Bootloader is a program that boots the operating system and decides from which kernel OS will boot.

What is a Zombie?
Zombies are the premature process, whose mature parent process died without retrieving its children. These processes cannot be killed by normal “kill” command.

What is swap space or swap file?
Swap space in Linux is used when the amount of physical memory (RAM) is full. If the system needs more memory resources and the RAM is full, inactive pages in memory are moved to the swap space. While swap space can help machines with a small amount of RAM, it should not be considered a replacement for more RAM. Swap space is located on hard drives, which have a slower access time than physical memory.

What is MX Record?
MX Record numerically ranks the mail server, when you would like to receive email for a domain. The preference of the email depends on the lowest MX record, but you are allowed to specify multiple email servers with the same value for simple load balancing.

What is CUPS?
CUPS (Common UNIX Printing System) is an open source printing system developed by Apple Inc. CUPS uses the Internet Printing Protocol (IPP) to allow local printing and print sharing.

What is Soft Link?
Soft link is a method to create short cuts in Linux. It is similar to windows short cut feature.

What is LVM?
LVM (Logical Volume Manager) is a storage management solution that allows administrators to divide hard drive space into physical volumes (PV), which can then be combined into logical volume groups (VG), which are then divided into logical volumes (LV) on which the filesystem and mount point are created.

What is RAID?
RAID (Redundant Array of Inexpensive Disks) is a technology that is used to increase the performance and/or reliability of data storage. RAID is a method by which same data or information is spread across several disks, using techniques such as disk striping (RAID Level 0), disk mirroring (RAID Level 1), and disk striping with parity (RAID Level 5) to achieve redundancy, lower latency, increased bandwidth, and maximized ability to recover from hard disk crashes. RAID 0: Blocks striping, No mirror, No Parity
  • RAID 1: Blocks mirroring, No striping, No Parity
  • RAID 5: Blocks striping with parity or distributed parity
  • RAID 6:  Blocks striping with double parity
  • RAID 10: combining mirroring and striping
What are run levels in Linux?
Run levels define what processes or services to run automatically while the system boots up. This is defined in /etc/inittab file.
Run levels on Debian systems default to this kind of setup:
  • 0 = halted (shutdown)
  • 1 = single user (maintenance mode)
  • 2 = multi-user mode without NFS
  • 3= Full multi user mode (text based) with networking
  • 4= not used
  • 5= Multi user mode with Graphical User Interface
  • 6 = reboot
What are inodes in Linux? How to find the inode associated with a file?
An inode is a data structure on a filesystem on Linux and other Unix-like operating systems that stores all the information about a file except its name and its actual data. When a file is created, it is assigned both a name and an inode number, which is an integer that is unique within the filesystem. Both the file names and their corresponding inode numbers are stored as entries in the directory that appears to the user to contain the files. The concept of inodes is particularly important to the recovery of damaged filesystems. When parts of the inode are lost, they appear in the lost found directory within the partition in which they once existed.

What neat command will do?
 In Linux, neat command provides Graphical interface to change network settings for network devices.

What is the functionality of a Puppet Server?
Puppet is an open-source and enterprise application for configuration management toll in UNIX like operating system. Puppet is an IT automation software used to push the configuration to its clients (puppet agents) using code. Puppet code can do a variety of tasks from installing new software, to check file permissions, or updating user accounts and lots of other tasks.

How to create simple shell scripts in Linux?
Make sure that the file begins with "#!/bin/bash" before any command lines. Make it executable: chmod +x <filename>. Executed by running "sh <filename.sh>" OR <./filename.sh>".

What is SeLinux?
SELinux is an acronym for Security-enhanced Linux. It is an access control implementation and security feature for the Linux kernel. It is designed to protect the server against misconfigurations and/or compromised daemons. It put limits and instructs server daemons or programs what files they can access and what actions they can take by defining a security policy.

Explain the terms of SUID, SGID and sticky bit?
In addition to the basic file permissions in Linux, there are few special permissions that are available for executable files and directories.
SUID (Set owner User ID up on execution): If setuid bit is set, when the file is executed by a user, the process will have the same rights as the owner of the file being executed. Normally in Linux/Unix when a program runs, it inherits access permissions from the logged in user. SUID is defined as giving temporary permissions to a user to run a program/file with the permissions of the file owner rather that the user who runs it. In simple words users will get file owners permissions as well as owner UID and GID when executing a file/program/command.
SGID (Set-group identification): Same as above, but inherits group privileges of the file on execution, not user privileges. Similar way when you create a file within the directory, it will inherit the group ownership of the directories. SGID permission is similar to the SUID permission, only difference is – when the script or command with SGID on is run, it runs as if it were a member of the same group in which the file is a member.
Sticky bit: The sticky bit is primarily used on shared directories. Sticky bit was used on executables in Linux so that they would remain in the memory more time after the initial execution, hoping they would be needed in the near future. But mainly it is on folders, to imply that a file or folder created inside a stickybit enabled folder could only be deleted by the owner. A very good implementation of sticky bit is /tmp , where every user has write permission but only users who own a file can delete them.

How to disable user login via terminals?
Add "/sbin/nologin" field instead of "/bin/bash" in "/etc/passwd" file.

What is the role of /etc/resolv.conf file?
In this file we sets the DNS servers (using their IP addresses) and the search domain. The values of the DNS servers are often added when the network is activated because the data can be provided by DHCP or a similar service.

The option "Open in Terminal" is missing when user right clicks on terminal in GUI. How to fix this?
This is basically because of missing package "nautilus-open-terminal". Once this is installed, the right click option would show up.

How do you disable the "NetworkManager" service on runlevel 5? 
[root@redhat Desktop]# chkconfig --level 5 NetworkManager off
[root@redhat Desktop]# chkconfig --list NetworkManager
NetworkManager 0: off 1: off 2: on 3: on 4: on 5: off 6: off

What is Drop cache in Linux?
Drop cache in Linux memory is the information stored the kernel for later use, as the memory is faster than the disk.

How do you find out all the packages installed on a RHEL system (server)?
/root/install.log > this would only lists packages installed during deployment of the system. Packages installed later would not be listed here. Otherwise, run the command #rpm -qa > this would query rpm database and prints out names respectively. In RHEL5.x we can check the file: /var/log/rpmpkgs to find out all packages on the system. However, this file is deprecated in RHEL6.

How to check the default gateway?
Using ‘route -n’ command we can determine the default gateway in Linux.

What is the minimum number of partitions you need to install Linux?
Minimum 2 partitions are needed for installing Linux. The one is / or root which contains all the files and the other is swap. Linux file system is function specific which means that files and folders are organized according to their functionality. For example, all executables are in one folder, all devices in another, and all libraries in another and so on. / Or ‘root’ is the base of this file system. All the other folders are under this one. / can be consider as C: .Swap is a partition that will be used as virtual memory. If there is no more available RAM a Linux computer will use an area of the hard disk, called swap, to temporarily store data. In other words it is a way of expanding your computers RAM.

What are the process states in Linux?
Running: Process is either running or ready to run
Interruptible: a Blocked state of a process and waiting for an event or signal from another process
Uninterpretable: a blocked state. Process waits for a hardware condition and cannot handle any signal
Stopped: Process is stopped or halted and can be restarted by some other process
Zombie: process terminated, but information is still there in the process table.

What are different backup techniques?
TAR, CPIO, MKSYSB AND UFSDUMP

What is YUM?
YUM (Yellow Dog Updater, Modified) is based on YUP, the Yellow dog Updater. Where does the name Yellow dog come from? Yellow Dog is a version of Linux for the Power Architecture hardware and is RPM-based, just like Red Hat Enterprise Linux and Fedora. YUP, and later YUM, were written by the Linux community as a way to maintain an RPM-based system.

What happens when you run the rm command?
The rm command removes a filename from a directory list, decrements the link count of the corresponding i-node by 1, and, if the link count thereby falls to 0, deallocates the i-node and the data blocks to which it refers.

Which Linux service is used as a database server?
MySQL and PostgreSQL is used in Linux service.

Which Linux service is used to turn a Linux system in proxy server?
Squid service can be used to turn any Linux system into an in proxy server.

How to check the ip address of LAN card?
Using ‘ifconfig’ & ‘ip address’ command we can determine the ip address of LAN Card.

What is the difference between umask and ulimit?
Umask (User file creation mask): which determines the settings of a mask that controls which file permissions are set for files and directories when they are created.
Ulimit: Ulimit is a Linux built in command which provides control over the resources available to the shell and/or to processes started by it. You can limit user to specific range by editing /etc/security/limits.conf at the same time system wide settings can be updated in /etc/sysctl.conf.
Request to Download PDF
Axact

Axact

Vestibulum bibendum felis sit amet dolor auctor molestie. In dignissim eget nibh id dapibus. Fusce et suscipit orci. Aliquam sit amet urna lorem. Duis eu imperdiet nunc, non imperdiet libero.

Post A Comment:

0 comments: