Thursday, December 6, 2012

Linux Interview Questions for Senior Linux Admin

Linux Interview Questions for Senior Linux Admin

Guys below mentioned are the few questions which are common in interview pattern for CMMi level companies. Hope this helps you when you go rounds on with reputed companies like HP, ACCENTURE, MPHASIS, PATNI, YAHOO, IBM.

Q. What is the difference between NFS v3 and NFS v4 ? Configuration steps ?

Q. What are INODES? If I delete and recreate same file again will the inode number change or will remain same. Please explain why ?

Q. IF we type the command      # mkfs *  What will happen ?

Q. How to disable node in HPOV Java Console ?

Q. What is SOA in DNS ? IF deleted will DNS Work ?

Q. Suppose if you give proper commands to detect LUN and still LUN is not visible then how will you troubleshoot the problem ? 
   
Q. What are the daemons running in a Conga Cluster ? Name them with Port number used ?

Q. Steps to halt and start the Conga Cluster ? Services  stop and start order ?

Q. How to check which kernel you had boot from using TOP command ?

Q. How to upgrade ILO ?

Q. How to upgrade an Firmware ?

Q. Where do you make kernel related entries ?

Q. What are the commands in linux to disable a Firewall ?

Q. What does the 3 values of load average indicates ?

Q. Define a daemon ?

Q. Explain Boot process in linux ( Brief and my favorite )  ?

Q. How to create a daemon with shell scripting ?

Q. Can we use crontab to run a script every second ? if not why ? if yes ? How ?

Q. How to create a swap if you do not have free partition ?

Q. What is the default block size ( Chunk Size ) for a PV ?

Q. Difference between LVM 1 and LVM 2 ? 

Q. How do you configure a JBOSS Clustering ?  STEPS

Q. How does a conga cluster communicate ? Detailed explanation ?

Q. How do you stop all process except shell window ?  ( Q asked in Yahoo ) ?

Will submit the answers soon. .. Hope this helps many people....

Wednesday, December 5, 2012

Linux Port Number for Linux Administrator

Important Linux Port Number for Linux System Administrator

Hello Friends,

Here we will try to understand the role of port in a life of Linux system administrator. I will describe and mention most important ports which every system admin must remember ( useful in day to day life as well as to clear interview )

Q What is a Port ?
A port is nothing but a piece of software which is used by system to communicate with other system in space or network.

Q What is a Socket ? 
 Socket is a combination of software port + IP address.

Q. What is the range of ports or how many ports are there?
Port numbers can vary from 0 to 65535, so total we can get 65536 ports

Q. Why port numbers are just 65536?
This is because limitation in TCP/IP stack where the port number field is just 16bit size. So we get only 2^16 ports which are equal to 65536 available ports

Q.What are the well-known ports or assigned ports or default ports?
Well known ports are from 0 to 1023(total 2^10=1024 ports)

Q. What do you mean by default port?
Default port is a designated port for particular well-known server.

Q. Can we change default port for a service(example Apache, squid)?
Yes, we can change. In most apache and DNS we can change this using listen configuration entry in httpd.conf and . Squid have port entry in its squid.conf file to mention port number.

Q. What are the protocol numbers for TCP and UDP?
Do not confuse this one with port numbers. TCP and UDP have their own numbers in TCP/IP stack.
TCP protocol number:6
UDP protocol number:17

Q. Is there any way I can see all the port information in Linux?
Yes, you can get that from /etc/services files.

Q. How can I see open ports in Linux?
Use nmap command.

Well known ports

20 – FTP Data (For transferring FTP data)
21 – FTP Control (For starting FTP connection)
22 – SSH (For secure remote administration which uses SSL to encrypt the transmission)
23 – Telnet (For insecure remote administration
25 – SMTP(Mail Transfer Agent for e-mail server such as SEND mail)
53 – DNS(Special service which uses both TCP and UDP)

68 – DHCP
69 – TFTP(Trivial file transfer protocol uses udp protocol for connection less transmission of data)
80 – HTTP/WWW(apache)
88 – Kerberos
110 – POP3(Mail delivery Agent)
123 – NTP(Network time protocol used for time syncing uses UDP protocol)
137 – NetBIOS(nmbd)
139 – SMB-Samba(smbd)
143 – IMAP
161 – SNMP(For network monitoring)
389 – LDAP(For centralized administration)
443 – HTTPS(HTTP+SSL for secure web access)
514 – Syslogd(udp port)
636 – ldaps(both tcp and udp)
873 – rsync
989 – FTPS-data
990 – FTPS
993 – IMAPS
995 – POP3s
2049 – NFS(nfsd, rpc.nfsd, rpc, portmap)

3306 – MySql


Monitoring Tools port for zabbix and nagios

5666 -- Nagios Server 
5667 -- Nagios Client 

10051 -- Zabbix Client
10050 -- Zabbix Server

 Ports used in Clustering ( Conga Cluster )

5404, 5405  -- cman  (udp)
11111           -- ricci    (tcp)
14567          -- gnbd   (tcp)
16851          -- Conga Model     (tcp)
21064          -- DLM ( distributed lock manager )   (tcp)
50006,50008,50009  -- ccsd (tcp)
50007           -- ccsd (udp)
4196,4197,4198,4199   -- rgmanager (tcp)