RHCE Interview Questions with Answers

About to attend a job interview based RHCE certification, here is the collection of interview questions with detailed answer which you may expect to face in RHCE interview. This collection gives you an idea of questions which may be asked in interview.


What command do you use to format a partition with a file system?

You could use mkfs command to format partition with file system.

Which command will assign IP address and subnet mask to eth0 network interface?

ifconfig command can be used to assign IP address. Following command will do the given task

ifconfig eth0 netmask

Which option in fdisk will display the partition table?

In fidisk utility, the "p" command will print the partition table.

To create a recurring scheduled task, which Linux scheduling tool should you use?

The cron command allows you to create recurring tasks

What command can you use to enable an Ethernet network interface that has already been configured?

To enable already configured interface use

ifconfig [interface] up

command. For example to up eth0 interface use following command

#ifconfig eth0 up


How will you decompress the demo.tar.gz file?

To decompress use following command

#tar -zxvf demo.tar.gz

A core dump file contains this message, “Program terminated with signal 11, segmentation fault.” What does this message indicate?

The core file will tell you what exactly caused the program to crash. So this message indicate that the program crashed because of a segmentation fault in memory.

What command runs fdisk on the first ATA/IDE hard drive?

The first ATA/IDE hard drive is hda, so the command would be

# fdisk /dev/hda

An application is creating several, very large core dump files. What should the administrator do if he has no intention of debugging these files?

If administrator have no intention of keeping these files for debugging purposes, they should be deleted because they are wasting valuable disk space, and may cause system to run out of space.

When checking the partition information on your hard drive with fdisk, you notice that one of the partitions is formatted as "Linux Swap" and is approximately 512MB in size. What is the purpose of this partition?

The Linux swap file is used for virtual memory to store additional information that cannot fit into current memory. This swap file allows information to be cached on disk, and can be retrieved very quickly. Heavy use of the swap file indicates a low memory condition.


What sort of kernel error can cause a Linux system to crash and write a memory core dump?

Kernel panic error can cause a Linux system to crash. A kernel panic indicates that a kernel process has crashed. This is a very serious error that causes the entire Linux system to crash. These core dumps should be analyzed carefully to find the root cause of the problem.

RHCE Interview Questions with Answers

An administrator wants to assign an IP address of, a subnet mask of, and a broadcast address of to eth1. What command will accomplish this task?

Following command will do this task

ifconfig eth1 netmask broadcast

What command should you use to set up a job to run at 11:15 a.m. today?

When you are only running the job once at the specified time, you should always use the at command. In this case following command will do the task

#at 11:15

You are tasked to set up a schedule to perform automatic checks of available disk space at the end of the day. How can you accomplish this task?

To accomplish this task set up cron to run a script that will check the disk space daily at 7:00 p.m. The output will be e-mailed to the root account. You can compare the results from day to day to analyze disk space usage.

Your cron file should look similar to the following:

* 19 * * * df -kl

As a administrator you need to terminate the sendmail process. How will you do that?

First you need to determine the PID of sendmail so it can be killed.

#ps -ef |grep sendmail

Now you can use kill command to terminate the process associated with sendmail.

You noticed a kernel error message during the boot process, but it scrolled before you could read this? What log file could you check to find out that message?

The log file that contains kernel boot messages is /var/log/dmesg.

You execute a command that is going to take a long time. How can you get back to your shell prompt to perform other task?

You can use bg command to send a running process to the background.

You need to kill all instances of Web Server? What command will you execute to do this?

You can use killall httpd command to kill all httpd process. httpd process run web server.

How can you list all running process?

Use ps -ef command to list all running process.

#ps -ef

As a Linux admin you want to know what processes are being run by user sumit. What command can you use ?

You can use #ps -au command to list all the process owned by user. Following command will do the assigned task

#ps -au sumit

Which log file keeps track of all user logins and logouts?

/var/log/wtmp log file keeps track of all user logins and logouts.

What is the first process that is run when a Linux system starts, and is responsible for starting all other system processes and services?

The init process is the first process to be run. It is the parent process of all other Linux system processes, services, and daemons that are needed to run the system.

Which command will you use to bring a process in foreground, which is running in the background?

The fg command immediately moves the program to the foreground.

An administrator has accidentally killed a core process. What is the result of this action?

Killing a core process can potentially crash your system because many critical services rely on these core processes

As a administrator you need to monitor the /var/log/messages file in real time to resolve the issue? How would you do that?

You can use tail command with -f option. Following command will do the assigned task

#tail -f /var/log/messages

From the output of ps command how will you determine the ID number of the parent process of a particular program?

PPID refers to the parent process identification number.

While scanning the /var/log/messages file, you notices an error stating an authentication failure for root. What could this mean?

Any failed login attempts for root are logged into the /var/log/messages file. It indicate that some has tried to login as root.

As an administrator you noticed from top command that an unidentified process is using up all CPU and memory. You suspects that is a user's process that has run away. How should you fix this ?

The process should be immediately killed before it consumes so many resources that the server cannot run properly, and therefore crash.

What command can an administrator use to track real-time information on processes and the resources that they are using?

The top command is used to monitor processes and resources in real-time.

A developer with username sanjay has told you that one or his processes seem to be locked up and he cannot it. He reported that it a bug in his code and may quickly use up all CPU and RAM resources on the server. How will you tack the process and terminate it?

Your first step is to identify the process, use ps command

#ps -au sanjay

Now run top command to compare the process running, and verify which one is using the most resources. After you have identified the problem process, you can use the kill command to terminate it. Because the user was unable to stop the process, you should probably force a kill signal to make sure that the process stops:

#kill -9 [PID of process]

Now, to verify that it has stopped, run the ps command again on the user:

ps -au sanjay

What is Kerberos used for?

Kerberos is used for secure network logon.

Which partition store system configuration files in Linux system?

/etc partition stores system configuration files in Linux.

What is the purpose of the MD5 option on passwords?

MD5 is an encryption method that encrypts the password before saving.

A better method of password security is to create difficult-to-break passwords that are easy for the users to remember.

What is the alternative method to a GUI installation in Linux ?

Linux provides text base installation as the alternative method of GUI installation.

What is the purpose of the swapon command ?

swapon command is used to activate a already created swap partition. It cannot be used to create a new swap partition.

What is gzip?

gzip is a compression utility created by the GNU project.

Name any four general password rules for user account.

  • Include at least eight total characters
  • Use the string in an unrepeated way
  • Avoid use words that can be found in the dictionary
  • Avoid use dates of significance, such as a birthday or anniversary
What is tar?

tar is an archive utility that is used to create tape backups.

Which is the standard command used to uncompress gzip files?

The standard command used to uncompress gzip files is gunzip.

What is the RPM switch for only installing packages?

The command line switch for installing an RPM is -i.

What is the command used to install an RPM package named demofilename2.2-2.i386.rpm?

The most common command used to install an RPM package is rpm -ivh. Following command will install the given package

#rpm -ivh demofilename2.2-2.i386.rpm

What is the command used to remove an RPM package named demofilename2.2-2.i386.rpm?

The most common command used to remove an RPM package is rpm -evh. Following command will remove the given package

#rpm -evh demofilename2.2-2.i386.rpm

What is the command used to update an RPM package named demofilename2.2-2.i386.rpm?

The most common command used to update an RPM package is rpm -Uvh. Following command will update the given package and remove the old.

#rpm -Uvh demofilename2.2-2.i386.rpm

Which command is used to see which RPM version of gzip was installed on the system?

#rpm -q gzip

Where are the automatically mounted file systems listed?

The automatically mounted file systems are listed in the file /etc/fstab.

While installing the new RPM what common steps should take ?

You should follow these common steps

  • Use RPM tools should be used to query or verify the installed packages to
  • confirm the installation of any previous packages.
  • Check the signature of new package
  • RPM should be installed or upgraded by first using the test mode to verify that it works, and then it should be installed
  • At the end query the RPM and verify the installation of RPM

Which organization controls the official releases and updates of the X Window System?

The X Consortium at www.x.org controls the official release and updating of the X Window System

PPP is most often used to create?

PPP is most often used to create serial point-to-point connections.

When attempting to connect to www.example.com you got unknown host message. Which service is most likely not functioning properly?


Samba is used to provide support for which protocol?

Samba is used to support the Microsoft SMB/CIFS systems.

What command is used to load a module into the kernel?

The insmod command is used to load a module into the kernel

Name one of the most secure method of remote access.

SSH is the most secure method of remote access

With respect to a Linux system’s RAM, how large should the swap file be?

Generally the size of the swap file should be twice the size of installed RAM.

How would you create a backup of the fstab file to the /backup folder?

Use cp command to create the backup.

#cp /etc/fstab /backup

What command is used to exit the edit mode of VI editor?

The [esc] key is used to exit from the edit mode of VI editor.

What key combination will exit from VI editor and not save the changes made?

Esc + q +! Key combination will exit VI without saving the changes.

What command would you use to create a file system on a new hard drive?

The mkfs command is used to create file systems.

What fstab file do?

The fstab file is used to automatically mount file systems.

What inittab file do?

The /etc/inittab file is used to perform the default state and terminal connections for a Linux system.

What command can you use to verify the current active shell?

The env command will display the current active shell.

Where is the file . bashrc located?

The . bashrc file is usually located in the /home/username directory.

What function does the .bash_profile file perform?

The function of the .bash_profile file is to provide login initialization commands.

What function does the .bash_logout file perform?

The function of the .bash_logout is to provide logout functions

What function does the .bashrc file perform?

The function of the .bashrc file is to provide shell configuration commands.

Which version of RHEL officially supports LUKS encryption?

From version 6 or higher LUKS encryption is officially supported by RHEL.

What is the default virtualization technology for RHEL6 ?

Default virtualization technology is KVM.

Can you configure KVM Virtual machine on 32 bit system ?

No, KVM virtualization requires at least 64 bit system.

Which remote management service is allowed through the default firewall and by default installed in RHEL?

By default SSH is always installed in RHEL. SSH uses port 22 which is allowed through the default firewall rules.

Which standard directory is used by vsFTP server for file sharing ?

Default Standard directory for ftp is /var/ftp/pub.

What is default mode of SELinux during the installation of RHEL ?
  • In RHEL5 you have to choose the mode which you want.
  • From RHEL6 default mode is Enforcing during the installation.

However you can change the mode of SELinux after installation, only difference between RHEL5 and RHEL6 is that in RHEL5 asks you to choose the mode while RHEL6 does not let you to choose the mode during the installation.

Which standard directory is used by Apache web server for HTML files ?

standard directory for HTML files is /var/www/html

What is the default partition layout during the installation ?

Default partition Layout is the LVM.

Which necessary partition cannot be a part of logical volume group ?

boot partition cannot be a part of logical volume group. You must have create it as a regular partition.

Which partitions are recommended for custom layout of partition ?
  • /
  • /boot
  • /home
  • swap
What step during the installation could you take to prevent a program from creating temporary files that fill up the entire space ?

You can create a separate /tmp partition prevents a program from creating temporary files that fill up the entire filesystem.

What is the kickstart ?

kickstart is a installation method used in RHEL. A kickstart installation is started from a kickstart file, which contains the answers to all the questions in the installation program.

Name any of two third party distribution based on RHEL6 source code.

CentOS and Scientific Linux

Which Log file contains all installation message?

install.log.syslog file contains all messages that were generated during the installation.

What is the difference between | and && command redirection operators?

The | takes output from the command specified in left and redirect that as input in command specified in right.

The && executes the command specified in right, once the command specified in left is executed.

Which file stores user database in Linux?

The user database is stored in file /etc/passwd.

Which file stores user’s passwords in Linux?

The user’s passwords are stored in file /etc/shadow.

ComputerNetworkingNotes Networking Interviews RHCE Interview Questions with Answers