Unix Commands Interview Questions
Questions Answers Views Company eMail

solaris Run level?

Wipro,

3 5596

boot process?

Atos Origin, Wipro,

2 7006

When i run a programm of orphan process. Instead of getting child's parent (ppid)=1 ..i get 1400 and it varies as per system. How can i findthe right soluion??? My pgm: #include # include int main() { int pid; pid=fork(); if(pid < 0) {exit(-1);} else if(pid==0) { printf("Child Process is Sleeping ..."); sleep(10); printf("Orphan Child's Parent ID : %u ",getppid()); } else { printf("Parent Process Completed ... %u ",getpid()); exit(0); } return 0; } Output:

1949

how to unzip the contents of the gzip file

Epsilon,

1 2804

how to sort the content of the file based on numeric values

Epsilon,

1496

How to find $ai_serual resolved path by using unix

1240

What does 'mkdir' command do in UNIX?

Syntel, Visa,

889

What is the functionality of a top command?

Amazon,

791

What are the commands in UNIX to list the files in a Directory?

CGI,

798

What is the use of touch command in there?

Accenture,

1 1757

What is ‘ps’ command for?

830

What is the significance of the 'tee' command?

805

What does the command ' $who | sort –logfile > newfile' do?

1006

What does the command '$ls | wc –l > file1' do?

885

How is the command '$cat file2 ' different from '$cat >file2 and >> redirection operators ?

960


Post New Unix Commands Questions

Un-Answered Questions { Unix Commands }

How can we use grep command in unix?

819


What are awk commands?

787


How do you grep recursively?

759


What do chmod command do?

801


What does the metacharacter mean?

793






How do I use grep to search for a file?

777


How do I clear my terminal history?

788


When i run a programm of orphan process. Instead of getting child's parent (ppid)=1 ..i get 1400 and it varies as per system. How can i findthe right soluion??? My pgm: #include # include int main() { int pid; pid=fork(); if(pid < 0) {exit(-1);} else if(pid==0) { printf("Child Process is Sleeping ..."); sleep(10); printf("Orphan Child's Parent ID : %u ",getppid()); } else { printf("Parent Process Completed ... %u ",getpid()); exit(0); } return 0; } Output:

1949


Which command is used to delete all files in the current directory and all its sub-directories?

925


What do chown command do?

771


How do I run a bash script?

797


Is it inbetween or in between?

783


What is the use of find command in unix?

748


Is there a way to erase all files in the current directory, including all its sub-directories, using only one command?

1006


What is the command to find maximum memory taking process on the server?

872