Professional Documents
Culture Documents
? echo /dev/null > file_name ( this will overwrite the file with null records)
3 How will you know who are the users logged in to the system before 15 minutes? There is no exact command to find it. Use "last -10" and check the timestam
7 What is the protocol for PING command? ICMP ( you can see it in "ping <hostname>" command
8 Which is the command used to find out currently executing Process in UNIX? ps -ef
9 What is the output of : $ ps-e $ ps-a commands ps -e for extended format, ps -a for all users
How to check whether some services are running in another server or not? Suppose i am
currently in a server named A.I want to check whether some services are running in check the port number of that service using telnet command ( for eg. If you
10 server B without logging into the server B. know the default port of ftp (21) . The use this command to see if that servic
11 By using which command we can find the CPU utilization time? ps -aux or top
12 How to find the files that are accessed before 10 days? find . -mtime +10
13
14 A file has 1000 lines and i want to display only 1st line how to do it? pls ..tel me head -1 <file-name>
15 How can i know my Filesystem and its current usage in my prod UNIX system? df -h .
what is the cmd to remove the comment lines from a file and to display the original text
16 without comments? grep ^# <file-name>
17 what is the cmd to display the last exit status in UNIX? echo $?
19 What is the different between UNIX command and UNIX shell script? shell script is a group of commands with variables, control structures
I have directories within the directory. Now i want to copy the directory along with all
20 directories included in it to one location by using copy command? what is the command cp -r <source-dir> <destination-directory>