You are on page 1of 3

How will you find which operating system your system is running on in UNIX?

"uname" -a
How do you find which process is taking how much CPU?
"top" command.
How do you check how much space left in current drive ?
"df" command
For example "df -h ." will list how full your current drive is.
How do you check if a particular process is listening on a particular port on re
mote host?
"telnet" command .
Example telnet hostname port, if it able to successfully connect then some process
is listening on that port. To read more about telnet read networking command in
UNIX
How do you find whether your system is 32 bit or 64 bit ?
Either by using "uname -a" command or by using "arch" command.
How do you find for how many days your Server is up?
"uptime" command
What are the diffrent flavours avilable in Unix?
Linux .. Red Hat Linux ... Solaris ... HPUX...IBM and AIX
How do you find which remote hosts are connecting to your host on a particular p
ort say 10123?
"netstat" command
execute netstat -a | grep "port" and it will list the entire host which is conne
cted to this host on port 10123.
How to find the port is used or free ?
netstat -an | grep :687
How do you see command line history in UNIX?
Very useful indeed, use history command along with grep command in unix to find
any relevant command you have already executed. Purpose of this Unix Command Int
erview Questions is probably to check how familiar candidate is from available t
ools in UNIX operation system.
How do you know if a remote host is alive or not?
You can check these by using either ping or telnet command in UNIX. This questio
n is most asked in various Unix command Interview because its most basic network
ing test anybody wants to do it.
what is the command used to run the process in backgroud ?
&
to log the out of that process
nohup ./anyservice.sh
what is the useof zip command?
this is used to 'zip' the directories or folder for thisinput file is 'tarfile'.
syntax: gzip director.tar ex: gzip abc.tar 19
How do you schedule a jobs ?
'crontab' command
is a scheduler which is used to schedule any job at any time around the year.syn
tax: crontab -l (listing the scheduler)ex:crontab -e (to edit and modify any cha
nges in the scheduer
If i want to change the permission . what is the command i need to use?
Chmod a+rwx filename
If i want to copy a file what is the command i need to use?
cp fie1 file2
If i want to search a file from a folder what is the command i need to use?
ls dirname/filename
If i want to read last 200 line from a file what is the command i need to use?
tail -200f filename
If i want to edit a file How can you do it ?
vi <<filename>>
How do you check an Application name "mobilepayment" is up and running ?
ps -ef | grep "mobilepayment"
How do you stop the running process ?
first you need to get the PID by using ps -ef | grep "mobilepayment" then us
e
kill PID
kill -9 PID
How do you check the virtual memory statistics of your CPU ?
vmstat reports information about processes, memory, paging, block IO, traps, and
cpu activity.

You might also like