Tuesday 10 July 2012



Unix/Linux System Admin Interview Questions And Answers 7


Q: - Which options are required to upgrade a RPM?

Upgrading a package is similar to installing one. Type the following command at a shell prompt:
rpm -Uvh test-2.0-1.i386.rpm

Q: - In which directory RPM database stored?

/var/lib/rpm
Q: - Explain the command "rpm -qa"?

It will queries all currently installed packages.
Q: - Explain the command "rpm -qf "?
it queries the RPM database for which package owns <filename>. When specifying a file, specify the absolute path of the file.
Q: - How to verify all installed packages?

rpm -Va
Q: - How to verify the signature of an rpm?

rpm -K test-1.0-1.i386.rpm
Q: - How to list PCI Devices on your server or System?

use "lspci" command.
Q: - What is the role of "Kudzu"?

Kudzu is used to Detect new Hardware
Q: - What happens when you add a new device after installation?

The Kudzu program runs each time the system boots and performs a hardware probe. If new hardware is found, Kudzu attempts to map it to a kernel module. If successful, the information is saved, and the device is configured.
Q: - How to Enable ACLs for /home partition?
Add following entry in /etc/fstab
LABEL=/home    /home       ext3        acl      1  2
Now remount /home partition with acl option.
mount -t ext3 -o acl /dev/sda3  /home
Q: - How to View ACLs for a file(test_file)?

getfacl test_file
Q: - How to remove an ACL?

setfacl --remove-all <file-name>
Q: - What is the difference between pop3 and imap protocols ?
POP3 (Post Office Protocol) is the most commonly used internet mail protocol.It works on 110 port. It is easy to configure and use. With a POP account you download the mail to your local computer and keep it there. Most of the time it gets deleted off of the mail server after being downloaded. One disadvantage of POP is that once you download it to your computer you won't be able to check your mail from a different computer since it will already be downloaded onto your own computer. It tends to be slower than IMAP as well.
IMAP (Internet Message Access Protocol) uses a method where all the mailboxes and messages are maintained on the server. Therefore you can access your e-mail from any location with an internet connection. IMAP is faster than POP because the mail client reads all of the message headers without having to download the entire message. IMAP is also supported in a variety of clients just like POP. One thing to keep in mind is the amount of disk space allocated to your mail on the server may not be enough to hold all of your mail.IMAP supports the folder synchronization option e.g if you create any folder  on the client m/c in outlook(mail client) then that folder will automatically created on the mailserver for the account 
POP works best when you are using only a single computer, since you don’t have to worry about checking your e-mail from multiple locations. Plus it is faster as well.
IMAP would suit you better if you need to check your e-mail from multiple locations if you travel a lot. To use IMAP your ISP/mail provider must offer that type of account.
Q: - How to Disable a User Account in Linux ?

#   passwd <username> -l
   This might be useful in the situation where you don’t want to permanently remove the user, but you just want it disabled and no longer able to use the system. The user will still receive emails for example, but he will not be able to login and check them out.
To re-enable the account ,just use below command
# passwd <username> -u

No comments:

Post a Comment